@Handler public void onShowDiagnosticsProject() { final ProgressIndicator indicator = globalDisplay_.getProgressIndicator("Lint"); indicator.onProgress("Analyzing project sources..."); projServer_.analyzeProject( new ServerRequestCallback<Void>() { @Override public void onResponseReceived(Void response) { indicator.onCompleted(); } @Override public void onError(ServerError error) { Debug.logError(error); indicator.onCompleted(); } }); }
private void showProjectOptions(final int initialPane) { final ProgressIndicator indicator = globalDisplay_.getProgressIndicator("Error Reading Options"); indicator.onProgress("Reading options..."); projServer_.readProjectOptions( new SimpleRequestCallback<RProjectOptions>() { @Override public void onResponseReceived(RProjectOptions options) { indicator.onCompleted(); ProjectPreferencesDialog dlg = pPrefDialog_.get(); dlg.initialize(options); dlg.activatePane(initialPane); dlg.showModal(); } }); }
private void showOptions(final boolean activateSourceControl) { final ProgressIndicator indicator = globalDisplay_.getProgressIndicator("Error Reading Options"); indicator.onProgress("Reading options..."); server_.getRPrefs( new SimpleRequestCallback<RPrefs>() { @Override public void onResponseReceived(RPrefs rPrefs) { indicator.onCompleted(); PreferencesDialog prefDialog = pPrefDialog_.get(); prefDialog.initialize(rPrefs); if (activateSourceControl) prefDialog.activateSourceControl(); prefDialog.showModal(); } @Override public void onError(ServerError error) { indicator.onError(error.getUserMessage()); } }); }