|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.diamondspin.DSPopupMenuManager
public class DSPopupMenuManager
DSPopupMenuManager is a utility class for DSTabletopPane. It manages all the popup menus.
Copyright 2002-2009 DiamondSpin project. All Rights Reserved. Permission to use, copy, modify and distribute this software and its documentation for educational, research and non-profit purposes, without fee, and without a written agreement is hereby granted, provided that the above copyright notice and the following three paragraphs appear in all copies. To request Permission to incorporate this software into commercial products contact one of the authors of the project.
IN NO EVENT SHALL THE AUTHORS BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE AUTHORS HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. THE AUTHORS SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE AUTHORS HAS NO OBLIGATIONS TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
Constructor Summary | |
---|---|
protected |
DSPopupMenuManager(DSTabletopPane dsTabletopPane_Arg)
Constructor for the DSPopupMenuManager object |
Method Summary | |
---|---|
int |
checkPopupAsEventTarget(MouseEvent MouseEvent_Arg)
checks if an event(mouse, DT, any spatial event) is targetting a popup menu or not (-1) |
DSPopupMenu |
getDSPopupMenu(int Id)
Gets the DSPopupMenu associated for a user (null if no popupMenu for him) |
boolean |
mousePressedPopup(MouseEvent MouseEvent_Arg,
int Id,
double d,
double alpha)
Description of the Method |
boolean |
mouseReleasedPopup(MouseEvent MouseEvent_Arg,
int Id,
double d,
double alpha)
Description of the Method |
void |
openPopupMenuElement(double d,
double alpha,
DSElement elem,
int id)
directly open a popup menu for an element at a given location |
void |
openPopupMenuGlobal(double d,
double alpha,
int Id)
directly open a popup menu for an element at a given location |
protected void |
setDSPopupMenu(DSPopupMenu DSPopupMenu_Arg,
int Id)
Sets the DSPopupMenu associated for a user (null if no popupMenu for him) |
void |
unsetAllPopupMenus()
discard all the popup menus ! usefull for switching views |
void |
unsetAllPopupMenusForElement(DSElement DSElement_Arg)
Unset the popup menu for a given element (for instance if the element is deleted, modified, etc.) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected DSPopupMenuManager(DSTabletopPane dsTabletopPane_Arg)
dsTabletopPane_Arg
- the DSTabletopPane with whom I'm working withMethod Detail |
---|
public DSPopupMenu getDSPopupMenu(int Id)
Id
- ID of the user
protected void setDSPopupMenu(DSPopupMenu DSPopupMenu_Arg, int Id)
Id
- ID of the userDSPopupMenu_Arg
- The new DSPopupMenu for this userpublic void unsetAllPopupMenusForElement(DSElement DSElement_Arg)
DSElement_Arg
- The element concerned by the operationpublic void unsetAllPopupMenus()
public int checkPopupAsEventTarget(MouseEvent MouseEvent_Arg)
MouseEvent_Arg
- Description of the Parameter
public boolean mousePressedPopup(MouseEvent MouseEvent_Arg, int Id, double d, double alpha)
MouseEvent_Arg
- The mouseevent to propagate to the popup eventuallyId
- The id of the user triggering this eventd
- The Distance form the Centeralpha
- The angle from the horizontal
public boolean mouseReleasedPopup(MouseEvent MouseEvent_Arg, int Id, double d, double alpha)
MouseEvent_Arg
- The mouseevent to propagate to the popup eventuallyId
- The id of the user triggering this eventd
- The Distance form the Centeralpha
- The angle from the horizontal
public void openPopupMenuElement(double d, double alpha, DSElement elem, int id)
elem
- The element to open a ppup menu onid
- The id of the user triggering this eventd
- The Distance form the Centeralpha
- The angle from the horizontalpublic void openPopupMenuGlobal(double d, double alpha, int Id)
Id
- The id of the user triggering this eventd
- The Distance form the Centeralpha
- The angle from the horizontal
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |