/** * Shows the given message as error on the status line. * * @param editor the editor part * @param message message to be displayed */ private static void showErrorInStatusLine(IEditorPart editor, final String message) { final Display display= editor.getSite().getShell().getDisplay(); display.beep(); final IEditorStatusLine statusLine= (IEditorStatusLine)editor.getAdapter(IEditorStatusLine.class); if (statusLine != null) { display.asyncExec(new Runnable() { /* * @see java.lang.Runnable#run() */ public void run() { statusLine.setMessage(true, message, null); } }); } }
void reportToStatusLine(final IWorkbenchPart part, final String message) { getStandardDisplay().asyncExec(new Runnable() { public void run() { IEditorStatusLine statusLine = (IEditorStatusLine) part.getAdapter(IEditorStatusLine.class); if (statusLine != null) { if (message != null) { statusLine.setMessage(true, message, null); } else { statusLine.setMessage(true, null, null); } } } }); }
/** * Sets the error message in the status line. * * @since 3.7 */ private void setStatusLineMessage() { IEditorStatusLine statusLine= (IEditorStatusLine) fEditor.getAdapter(IEditorStatusLine.class); if (statusLine != null) statusLine.setMessage(true, ActionMessages.OpenAction_error_messageBadSelection, null); getShell().getDisplay().beep(); return; }
private void showErrorInStatusLine(final String message) { fShell.getDisplay().beep(); final IEditorStatusLine statusLine= (IEditorStatusLine)fEditor.getAdapter(IEditorStatusLine.class); if (statusLine != null) { fShell.getDisplay().asyncExec(new Runnable() { /* * @see java.lang.Runnable#run() */ public void run() { statusLine.setMessage(true, message, null); } }); } }
private void showErrorInStatusLine(final String message, ITextEditor textEditor) { Display display= textEditor.getEditorSite().getShell().getDisplay(); display.beep(); final IEditorStatusLine statusLine= (IEditorStatusLine)textEditor.getAdapter(IEditorStatusLine.class); if (statusLine != null) { display.asyncExec(new Runnable() { /* * @see java.lang.Runnable#run() */ public void run() { statusLine.setMessage(true, message, null); } }); } }
/** * Displays information in the status line why a line move is not possible */ private void showStatus() { IEditorStatusLine status= (IEditorStatusLine) fSharedState.fEditor.getAdapter(IEditorStatusLine.class); if (status == null) return; status.setMessage(false, JavaEditorMessages.Editor_MoveLines_IllegalMove_status, null); }
/** * Displays information in the status line why a line move is not possible */ private void showStatus() { ITextEditor textEditor = getTextEditor(); IEditorStatusLine status = textEditor.getAdapter(IEditorStatusLine.class); if (status == null) { return; } status.setMessage(false, "Move not possible - Uncheck \"Show Source of Selected Element Only\" to see the entire document", null); }
public void updateForceTabsMessage() { boolean forceTabs = getIndentPrefs().getForceTabs(); ImageCache imageCache = PydevPlugin.getImageCache(); ImageDescriptor desc; if (forceTabs) { desc = imageCache.getDescriptor(UIConstants.FORCE_TABS_ACTIVE); } else { desc = imageCache.getDescriptor(UIConstants.FORCE_TABS_INACTIVE); } IEditorStatusLine statusLine = (IEditorStatusLine) getAdapter(IEditorStatusLine.class); if (statusLine != null) { statusLine.setMessage(false, forceTabs ? "Forcing tabs" : "Not forcing tabs.", desc.createImage()); } }
/** * Sets the given message as error message to this editor's status line. * * @param msg message to be set */ @Override public void setStatusLineErrorMessage(String msg) { IEditorStatusLine statusLine = (IEditorStatusLine) getAdapter(IEditorStatusLine.class); if (statusLine != null) { statusLine.setMessage(true, msg, null); } }
public CopiedFromFindReplaceDialog(IFindReplaceTarget target, IEditorStatusLine statusLineManager) { this.fTarget = target; this.fStatusLineManager = statusLineManager; }
private static void showMessage(Shell shell, JavaEditor editor, String msg) { IEditorStatusLine statusLine= (IEditorStatusLine) editor.getAdapter(IEditorStatusLine.class); if (statusLine != null) statusLine.setMessage(true, msg, null); shell.getDisplay().beep(); }
/** * Important: keep for scripting */ public void setMessage(boolean error, String message) { IEditorStatusLine statusLine = (IEditorStatusLine) this.getAdapter(IEditorStatusLine.class); statusLine.setMessage(error, message, null); }
public static void setStatusLineErrorMessage(ITextEditor editor, String message, Image image) { IEditorStatusLine statusLine= (IEditorStatusLine)editor.getAdapter(IEditorStatusLine.class); if(statusLine != null) { statusLine.setMessage(true, message, image); } }