Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.ui.texteditor
Class AbstractRulerActionDelegate


java.lang.Object
  extended by 

org.eclipse.ui.actions.ActionDelegate
      extended by 
org.eclipse.ui.texteditor.AbstractRulerActionDelegate
All Implemented Interfaces:
EventListener, IMenuListener, MouseListener, org.eclipse.swt.internal.SWTEventListener, IActionDelegate, IActionDelegate2, IEditorActionDelegate
Direct Known Subclasses:
BookmarkRulerAction, RulerEnableDisableBreakpointActionDelegate, RulerToggleBreakpointActionDelegate, SelectRulerAction, TaskRulerAction

public abstract class AbstractRulerActionDelegate
extends ActionDelegate
implements IEditorActionDelegate, MouseListener, IMenuListener

This class serves as an adapter for actions contributed to the vertical ruler's context menu. This adapter provides the contributed actions access to their editor and the editor's vertical ruler. These actions gain only limited access to the vertical ruler as defined by IVerticalRulerInfo. The adapter updates the adapter (inner) action on menu and mouse action on the vertical ruler.

Extending classes must implement the factory method createAction(ITextEditor editor, IVerticalRulerInfo).

Since:
2.0

Constructor Summary
AbstractRulerActionDelegate ()
           
 
Method Summary
protected abstract   IAction createAction ( ITextEditor editor, IVerticalRulerInfo rulerInfo)
          The factory method creating the underlying action.
 void menuAboutToShow ( IMenuManager manager)
          Notifies this listener that the menu is about to be shown by the given menu manager.
 void mouseDoubleClick ( MouseEvent e)
          Sent when a mouse button is pressed twice within the (operating system specified) double click period.
 void mouseDown ( MouseEvent e)
          Sent when a mouse button is pressed.
 void mouseUp ( MouseEvent e)
          Sent when a mouse button is released.
 void run ( IAction callerAction)
          The ActionDelegate implementation of this IActionDelegate method does nothing.
 void runWithEvent ( IAction action, Event event)
          The ActionDelegate implementation of this IActionDelegate2 method redirects to the run method.
 void selectionChanged ( IAction action, ISelection selection)
          The ActionDelegate implementation of this IActionDelegate method does nothing.
 void setActiveEditor ( IAction callerAction, IEditorPart targetEditor)
          Sets the active editor for the delegate.
 
Methods inherited from class org.eclipse.ui.actions. ActionDelegate
dispose, init
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractRulerActionDelegate

public AbstractRulerActionDelegate()
Method Detail

createAction

protected abstract 
IAction createAction(
ITextEditor editor,
                                        
IVerticalRulerInfo rulerInfo)
The factory method creating the underlying action.

Parameters:
editor - the editor the action to be created will work on
rulerInfo - the vertical ruler the action to be created will work on
Returns:
the created action

setActiveEditor

public void setActiveEditor(
IAction callerAction,
                            
IEditorPart targetEditor)
Description copied from interface: IEditorActionDelegate
Sets the active editor for the delegate. Implementors should disconnect from the old editor, connect to the new editor, and update the action to reflect the new editor.

Specified by:
setActiveEditor in interface IEditorActionDelegate
Parameters:
callerAction - the action proxy that handles presentation portion of the action
targetEditor - the new editor target

run

public void run(
IAction callerAction)
Description copied from class: ActionDelegate
The ActionDelegate implementation of this IActionDelegate method does nothing. Subclasses may reimplement.

Note: This method is not called directly by the proxy action. Only by the default implementation of runWithEvent of this abstract class.

Specified by:
run in interface IActionDelegate
Overrides:
run in class ActionDelegate
Parameters:
callerAction - the action proxy that handles the presentation portion of the action

runWithEvent

public void runWithEvent(
IAction action,
                         
Event event)
Description copied from class: ActionDelegate
The ActionDelegate implementation of this IActionDelegate2 method redirects to the run method. Subclasses may reimplement.

Specified by:
runWithEvent in interface IActionDelegate2
Overrides:
runWithEvent in class ActionDelegate
Parameters:
action - the action proxy that handles the presentation portion of the action
event - the SWT event which triggered this action being run

selectionChanged

public void selectionChanged(
IAction action,
                             
ISelection selection)
Description copied from class: ActionDelegate
The ActionDelegate implementation of this IActionDelegate method does nothing. Subclasses may reimplement.

Specified by:
selectionChanged in interface IActionDelegate
Overrides:
selectionChanged in class ActionDelegate
Parameters:
action - the action proxy that handles presentation portion of the action
selection - the current selection, or null if there is no selection.

menuAboutToShow

public void menuAboutToShow(
IMenuManager manager)
Description copied from interface: IMenuListener
Notifies this listener that the menu is about to be shown by the given menu manager.

Specified by:
menuAboutToShow in interface IMenuListener
Parameters:
manager - the menu manager

mouseDoubleClick

public void mouseDoubleClick(
MouseEvent e)
Description copied from interface: MouseListener
Sent when a mouse button is pressed twice within the (operating system specified) double click period.

Specified by:
mouseDoubleClick in interface MouseListener
Parameters:
e - an event containing information about the mouse double click
See Also:
Display.getDoubleClickTime()

mouseDown

public void mouseDown(
MouseEvent e)
Description copied from interface: MouseListener
Sent when a mouse button is pressed.

Specified by:
mouseDown in interface MouseListener
Parameters:
e - an event containing information about the mouse button press

mouseUp

public void mouseUp(
MouseEvent e)
Description copied from interface: MouseListener
Sent when a mouse button is released.

Specified by:
mouseUp in interface MouseListener
Parameters:
e - an event containing information about the mouse button release

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire