@Override
 public void showFunction(SearchPathFunctionDefinition functionDef) {
   currentFunctionNamespace_ = functionDef.getNamespace();
   docDisplay_.setCode(functionDef.getCode(), false);
   // don't send focus to the display for debugging; we want it to stay in
   // the console
   if (!functionDef.isActiveDebugCode()) {
     docDisplay_.focus();
   }
   contextWidget_.setCurrentFunction(functionDef);
 }
    @Override
    public void onResponseReceived(SearchPathFunctionDefinition def) {
      // dismiss progress
      progress_.dismiss();

      // if we got a hit
      if (def != null && def.getName() != null) {
        // try to search for the function locally
        SourcePosition position =
            searchLocally_ ? docDisplay_.findFunctionPositionFromCursor(def.getName()) : null;

        if (position != null) {
          docDisplay_.navigateToPosition(position, true);
        } else if (def.getNamespace() != null) {
          docDisplay_.recordCurrentNavigationPosition();
          eventBus_.fireEvent(new CodeBrowserNavigationEvent(def));
        }
      }
    }