Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

oracle.jdeveloper.vcs.spi
Class VCSContextMenuListener

java.lang.Object
  extended by oracle.jdeveloper.vcs.spi.VCSContextMenuListener
All Implemented Interfaces:
ContextMenuListener

public abstract class VCSContextMenuListener
extends java.lang.Object
implements ContextMenuListener

Utility listener class for handling context menu events.

Since:
9.0.5

Constructor Summary
VCSContextMenuListener(java.lang.String vcsId)
           
 
Method Summary
protected abstract  java.awt.Component[] getContextMenuItems(Context context)
          Gets the menu items to be added directly to the context menu when popup notification is received.
protected  float getSection()
           
 boolean handleDefaultAction(Context context)
          Called when the user double clicks on an item that has a context menu.
 void menuWillHide(ContextMenu popup)
          This method is called just before a showing context menu is dismissed.
 void menuWillShow(ContextMenu popup)
          Called just before the context menu is shown.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VCSContextMenuListener

public VCSContextMenuListener(java.lang.String vcsId)
Method Detail

handleDefaultAction

public boolean handleDefaultAction(Context context)
Description copied from interface: ContextMenuListener
Called when the user double clicks on an item that has a context menu. If the listener handles the action, then it must return true; otherwise it must return false. Processing of handleDefaultAction stops on the first return of true.

Specified by:
handleDefaultAction in interface ContextMenuListener
Parameters:
context - the context on which the default action needs to occur.

menuWillHide

public void menuWillHide(ContextMenu popup)
Description copied from interface: ContextMenuListener
This method is called just before a showing context menu is dismissed. Most implementations should not do anything in this method. In particular, it is not necessary to clean out menu items or submenus that were added during ContextMenuListener.menuWillShow(oracle.ide.controller.ContextMenu), since the IDE takes care of that automatically.

Specified by:
menuWillHide in interface ContextMenuListener
Parameters:
popup - the context menu being hidden

menuWillShow

public void menuWillShow(ContextMenu popup)
Description copied from interface: ContextMenuListener
Called just before the context menu is shown. Implementations should add their items to the context menu here.

Specified by:
menuWillShow in interface ContextMenuListener
Parameters:
popup - the context menu being shown

getContextMenuItems

protected abstract java.awt.Component[] getContextMenuItems(Context context)
Gets the menu items to be added directly to the context menu when popup notification is received.

Parameters:
context - the current context.
Returns:
the menu item components to add.

getSection

protected float getSection()

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

Copyright © 1997, 2011, Oracle. All rights reserved.