当前位置: 首页>>代码示例>>Java>>正文


Java PropertiesAction类代码示例

本文整理汇总了Java中org.openide.actions.PropertiesAction的典型用法代码示例。如果您正苦于以下问题:Java PropertiesAction类的具体用法?Java PropertiesAction怎么用?Java PropertiesAction使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


PropertiesAction类属于org.openide.actions包,在下文中一共展示了PropertiesAction类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
@Override
public Action[] getActions(boolean context) {
    //FieldInfo fieldInfo = getField();
    ObjectReference component = getComponent();
    ComponentBreakpoint b = ComponentBreakpointActionProvider.findBreakpoint(component);
    
    List<Action> actions = new ArrayList<Action>();
    actions.add(GoToFieldDeclarationAction.get(GoToFieldDeclarationAction.class));
    actions.add(GoToSourceAction.get(GoToSourceAction.class));
    if (getAddCallStack() != null) {
        actions.add(GoToAddIntoHierarchyAction.get(GoToAddIntoHierarchyAction.class));
    }
    actions.add(null);
    actions.add(ShowListenersAction.get(ShowListenersAction.class));
    actions.add(CreateFixedWatchAction.get(CreateFixedWatchAction.class));
    actions.add(null);
    actions.add(ToggleComponentBreakpointAction.get(ToggleComponentBreakpointAction.class));
    if (b != null) {
        actions.add(CBP_CUSTOMIZE_ACTION);
    }
    actions.add(null);
    actions.add(PropertiesAction.get(PropertiesAction.class));
    return actions.toArray(new Action[] {});
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:25,代码来源:RemoteAWTScreenshot.java

示例2: defaultActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
/** Gets default system actions. Overrides superclass method. */
protected SystemAction[] defaultActions() {
    return new SystemAction[] {
        SystemAction.get(OpenAction.class),
        SystemAction.get (FileSystemAction.class),
        null,
        SystemAction.get(CutAction.class),
        SystemAction.get(CopyAction.class),
        SystemAction.get(PasteAction.class),
        null,
        SystemAction.get(DeleteAction.class),
        SystemAction.get(RenameAction.class),
        null,
        SystemAction.get(SaveAsTemplateAction.class),
        null,
        SystemAction.get(ToolsAction.class),
        SystemAction.get(PropertiesAction.class),
    };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:20,代码来源:AnnotationProviderTest.java

示例3: testCompatibilityIsPropagatedToDisk

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
/** Test to see whether a compatibility behaviour is still kept. E.g.
 * if one adds actions using DataLoader.setActions they really will be 
 * there.
 */
public void testCompatibilityIsPropagatedToDisk () throws Exception {
    assertEquals("No actions at the start", Collections.emptyList(), Arrays.asList(node.getActions(false)));
    FileObject test = root;
    
    PCL pcl = new PCL ();
    obj.getLoader ().addPropertyChangeListener (pcl);
    
    obj.getLoader().setActions(new SystemAction[] {
        SystemAction.get(PropertiesAction.class)
    });
    
    pcl.assertEvent (1, "actions");
    
    Action [] res = node.getActions(false);
    assertEquals("There should be exactly one action.", 1, res.length);
    assertEquals("One file created", 1, test.getChildren ().length);
    
    obj.getLoader().setActions(new SystemAction[0]);

    pcl.assertEvent (2, "actions");
    assertEquals("No actions after deleting", 0, node.getActions(false).length);
    
    assertEquals("file disappeared", 0, test.getChildren ().length);
    obj.getLoader ().removePropertyChangeListener (pcl);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:30,代码来源:DataLoaderGetActionsTest.java

示例4: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean context) {
    if (catalog instanceof CatalogWriter)
        return new Action[] {
            SystemAction.get(AddCatalogEntryAction.class),
            SystemAction.get(RefreshAction.class),
            SystemAction.get(CatalogNode.UnmountAction.class),
            null,
            //??? #24349 CustimizeAction sometimes added by BeanNode here
            SystemAction.get(PropertiesAction.class)
        };
    else
        return new Action[] {
            SystemAction.get(RefreshAction.class),
            SystemAction.get(CatalogNode.UnmountAction.class),
            null,
            //??? #24349 CustimizeAction sometimes added by BeanNode here
            SystemAction.get(PropertiesAction.class)
        };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:20,代码来源:CatalogNode.java

示例5: createActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
/** Lazily initialize set of node's actions.
 * Overrides superclass method.
 *
 * @return array of actions for this node
 */
@Override
protected SystemAction[] createActions () {
    return new SystemAction[] {
        SystemAction.get(EditAction.class),
        SystemAction.get(OpenAction.class),
        null,
        SystemAction.get(CutAction.class),
        SystemAction.get(CopyAction.class),
        SystemAction.get(PasteAction.class),
        null,
        SystemAction.get(DeleteAction.class),
        SystemAction.get(LangRenameAction.class),
        null,
        SystemAction.get(NewAction.class),
        SystemAction.get(SaveAsTemplateAction.class),
        null,
        SystemAction.get(FileSystemAction.class),
        null,
        SystemAction.get(ToolsAction.class),
        SystemAction.get(PropertiesAction.class)
    };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:28,代码来源:PropertiesLocaleNode.java

示例6: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public final Action[] getActions(boolean context) {
    if (isUISettingCategoryNode()) {
        return new Action[0];
    } else {
        return new Action[] {
            SystemAction.get(FileSystemAction.class),
            null,
            SystemAction.get(PasteAction.class),
            null,
            SystemAction.get(MoveUpAction.class),
            SystemAction.get(MoveDownAction.class),
            SystemAction.get(ReorderAction.class),
            null,
            SystemAction.get(NewTemplateAction.class),
            null,
            SystemAction.get(ToolsAction.class),
            SystemAction.get(PropertiesAction.class),
        };
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:21,代码来源:LookupNode.java

示例7: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
@Override
public Action[] getActions(boolean context) {
    if (job.getColor() == Color.secured) {
        return new Action[] {new LogInAction(job.getInstance())};
    }
    List<Action> actions = new ArrayList<Action>();
    actions.add(SystemAction.get(StartJobAction.class));
    actions.add(new ProjectAssociationAction(job));
    actions.add(null);
    if (job instanceof OpenableInBrowser) {
        actions.add(OpenUrlAction.forOpenable((OpenableInBrowser) job));
    }
    actions.add(new ViewConfigAction(job));
    actions.add(SystemAction.get(PropertiesAction.class));
    return actions.toArray(new Action[actions.size()]);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:17,代码来源:HudsonJobNode.java

示例8: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean b) {
    List<Action> lst = new ArrayList<Action>();
    
    Action saveAction = null;
    Node parentNode = this.getParentNode();
    if (parentNode != null && parentNode instanceof HttpPostFormFolderNode) {
        HttpPostFormFolderNode hpffn = (HttpPostFormFolderNode)parentNode;
        
        if (hpffn.getCanSave()) {
            saveAction = SaveNodeAction.get( SaveNodeAction.class );
        }
    }
    lst.add(EditNodeAction.get(EditNodeAction.class));
    lst.add(DeleteNodeAction.get(DeleteNodeAction.class));
    if (saveAction != null) {
        lst.add( saveAction );
    }
    lst.add( null );
    lst.add(PropertiesAction.get(PropertiesAction.class));
    
    return (Action[])lst.toArray(new Action[lst.size()]);
}
 
开发者ID:bernhardhuber,项目名称:netbeansplugins,代码行数:23,代码来源:HttpPostFormNode.java

示例9: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
@Messages("LBL_CompilePackage_Action=Compile Package")
@Override
public Action[] getActions( boolean context ) {
    
    if ( !context ) {
        if ( actions == null ) {                
            // Copy actions and leave out the PropertiesAction and FileSystemAction.                
            Action superActions[] = super.getActions( context );            
            List<Action> actionList = new ArrayList<Action>(superActions.length);
            
            for( int i = 0; i < superActions.length; i++ ) {

                if ( (i <= superActions.length - 2) && superActions[ i ] == null && superActions[i + 1] instanceof PropertiesAction ) {
                    i ++;
                    continue;
                }
                else if ( superActions[i] instanceof PropertiesAction ) {
                    continue;
                }
                else if ( superActions[i] instanceof FileSystemAction ) {
                    actionList.add (null); // insert separator and new action
                    actionList.add (FileSensitiveActions.fileCommandAction(ActionProvider.COMMAND_COMPILE_SINGLE, LBL_CompilePackage_Action(), null));                           
                    actionList.add (testPackageAction);
                    actionList.addAll((List<Action>) org.openide.util.Utilities.actionsForPath("Projects/package/Actions"));
                }
                
                actionList.add( superActions[i] );                                                  
            }

            actions = new Action[ actionList.size() ];
            actionList.toArray( actions );
        }
        return actions;
    }
    else {
        return super.getActions( context );
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:39,代码来源:PackageViewChildren.java

示例10: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
@Override
public Action[] getActions(boolean arg0) {
    return new Action[]{
        // XXX Find
        new RefreshIndexAction(), // XXX allow multiselections
        new EditAction(),
        DeleteAction.get(DeleteAction.class),
        null,
        PropertiesAction.get(PropertiesAction.class)
    };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:12,代码来源:RepositoryNode.java

示例11: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean context) {
    Action[] result = new Action[] {
        SystemAction.get(RefreshPropsAction.class),
                null,
                SystemAction.get(OpenLocalExplorerAction.class),
                null,
                SystemAction.get(NewAction.class),
                null,
                SystemAction.get(ToolsAction.class),
                SystemAction.get(PropertiesAction.class),
    };
    return result;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:14,代码来源:AllPropsNode.java

示例12: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean context) {
    Action[] result = new Action[] {
        SystemAction.get(DeleteAction.class),
                SystemAction.get(RenameAction.class),
                null,
                SystemAction.get(ToolsAction.class),
                SystemAction.get(PropertiesAction.class),
    };
    return result;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:11,代码来源:OnePropNode.java

示例13: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean context) {
    return new Action[] {
                SystemAction.get (CutAction.class),
                SystemAction.get (CopyAction.class),
                SystemAction.get (PasteAction.class),
                null,
                SystemAction.get (DeleteAction.class),
                null,
                SystemAction.get (ToolsAction.class),
                SystemAction.get (PropertiesAction.class)
            };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:13,代码来源:BrokenDataShadow.java

示例14: testNoDeserializationOfActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
/** Test to check that the deserialization of actions is completely ignored.
 */
public void testNoDeserializationOfActions () throws Exception {
    assertEquals("No actions at the start", 0, node.getActions(false).length);
    FileObject test = root;
    
    PCL pcl = new PCL ();
    obj.getLoader ().addPropertyChangeListener (pcl);
    
    obj.getLoader().setActions(new SystemAction[] {
        SystemAction.get(PropertiesAction.class)
    });
    
    pcl.assertEvent (1, "actions");
    
    Action [] res = node.getActions(false);
    assertEquals("There should be exactly one action.", 1, res.length);
    assertEquals("One file created", 1, test.getChildren ().length);
    
    NbMarshalledObject m = new NbMarshalledObject (obj.getLoader ());
    
    obj.getLoader().setActions(new SystemAction[0]);

    pcl.assertEvent (2, "actions");
    assertEquals("No actions after deleting", 0, node.getActions(false).length);
    
    assertEquals("file disappeared", 0, test.getChildren ().length);
    
    assertEquals ("Loader deserialized", obj.getLoader (), m.get ());
    assertEquals("Still no actions", 0, node.getActions(false).length);
    
    obj.getLoader ().removePropertyChangeListener (pcl);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:34,代码来源:DataLoaderGetActionsTest.java

示例15: getActions

import org.openide.actions.PropertiesAction; //导入依赖的package包/类
public Action[] getActions(boolean context) {
    if (isCatalogWriter)
        return new Action[] {
            SystemAction.get(EditAction.class),
            SystemAction.get(DeleteAction.class),
            null,
            SystemAction.get(PropertiesAction.class)
        };
    else
        return new Action[] {
            SystemAction.get(ViewAction.class),
            null,
            SystemAction.get(PropertiesAction.class)
        };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:16,代码来源:CatalogEntryNode.java


注:本文中的org.openide.actions.PropertiesAction类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。