Java Code Examples for org.netbeans.jemmy.operators.JPopupMenuOperator#callPopup()
The following examples show how to use
org.netbeans.jemmy.operators.JPopupMenuOperator#callPopup() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TreeTableOperator.java From netbeans with Apache License 2.0 | 6 votes |
/** Calls popup menu on specified tree paths. * @param paths an array of TreePath instances * @param mouseButton mouse button identification * @return JPopupMenu instance opened by this method */ public JPopupMenu callPopupOnPaths(TreePath[] paths, int mouseButton) { oper.makeComponentVisible(); for(int i = 0; i < paths.length; i++) { if(paths[i].getParentPath() != null) { expandPath(paths[i].getParentPath()); } } selectPaths(paths); scrollToPath(paths[paths.length - 1]); Point point = getPointToClick(paths[paths.length - 1]); return(JPopupMenuOperator.callPopup(oper.getSource(), (int)point.getX(), (int)point.getY(), mouseButton)); }
Example 2
Source File: OutlineViewOperator.java From netbeans with Apache License 2.0 | 6 votes |
/** Calls popup menu on specified tree paths. * @param paths an array of TreePath instances * @param mouseButton mouse button identification * @return JPopupMenu instance opened by this method */ public JPopupMenu callPopupOnPaths(TreePath[] paths, int mouseButton) { oper.makeComponentVisible(); for(int i = 0; i < paths.length; i++) { if(paths[i].getParentPath() != null) { expandPath(paths[i].getParentPath()); } } selectPaths(paths); scrollToPath(paths[paths.length - 1]); Point point = getPointToClick(paths[paths.length - 1]); return(JPopupMenuOperator.callPopup(oper.getSource(), (int)point.getX(), (int)point.getY(), mouseButton)); }