Examples of FileNode


Examples of com.qspin.qtaste.ui.tools.FileNode

        }

        protected void addNodesToDir(TreePath path) {
            TCTreeNode tn = getTreeNode(path);
            if (tn != null) {
                FileNode fn = (FileNode) tn.getUserObject();
                if (fn.isDir()) {
                    tn.removeAllChildren();
                    addTreeToDir(fn.getFile(), tn);
                    ((DefaultTreeModel) getModel()).reload(tn);
                }
            }
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

                Action renameTestAction = null;
                TreePath selectedPath = getSelectionPath();
                if (selectedPath == null) {
                    return;
                }
                FileNode fn = getFileNode(selectedPath);
                if (fn != null) {
                    if (fn.isTestcaseDir()) {
                        createTestAction.putValue(Action.NAME, "Copy TestScript...");
                        removeTestAction = new RemoveTestScript();
                        renameTestAction = new RenameTestScript();
                        renameTestAction.putValue(Action.NAME, "Rename TestScript...");
                        removeTestAction.putValue(Action.NAME, "Remove TestScript...");
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

                                selectedText = selectedText.replace(".", File.separator);
                                if (mTcPane != null) {
                                    fileSearch.addSearchPath(new File(getFileName()).getParent());
                                    fileSearch.addSearchPath(mTcPane.getCurrentSelectedTestsuite());
                                    FileNode selectedNode = mTcPane.getCurrentSelectedFileNode();
                                    if (selectedNode != null) {
                                        if (selectedNode.isTestcaseDir()) {
                                            fileSearch.addSearchPath(selectedNode.getFile().getParent());
                                        }
                                    }
                                    for (String dir : pythonLibPath) {
                                        fileSearch.addSearchPath(dir);
                                    }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

        public TestGenerateDocAction() {
            super("Generate documentation");
        }

        public void actionPerformed(ActionEvent e) {
            FileNode fn = getSelectedFileNode();
            if (fn==null) return;
            if (fn.getPythonTestScript()==null) return;
            testCasePane.parent.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
            File testcaseDoc = fn.getPythonTestScript().generateDoc();
            testCasePane.parent.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
            // refresh the test case window
            setTestCaseDoc(testcaseDoc, true);
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

            setTestCaseDoc(testcaseDoc, true);
        }

        @Override
        public boolean isEnabled() {
            FileNode fn = getSelectedFileNode();
            return fn != null && fn.isTestcaseDir();
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

        public TestExternalEditAction() {
            super("Edit in external editor");
        }

        public void actionPerformed(ActionEvent e) {
            FileNode fn = getSelectedFileNode();
            try {
                Desktop.getDesktop().edit(fn.getTestcaseFile().getAbsoluteFile());
            } catch (IOException ex) {
                logger.error("Error while calling Desktop edit on " + fn.getTestcaseFile().getAbsoluteFile());
            }
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

        protected void addNodesToDir(TreePath path) {
            Object obj = path.getLastPathComponent();
            if (obj instanceof TCTreeNode) {
                TCTreeNode tn = (TCTreeNode) obj;
                FileNode fn = (FileNode) tn.getUserObject();
                if (fn.isDir()) {
                    tn.removeAllChildren();
                    addTreeToDir(fn.getFile(), tn);
                    ((DefaultTreeModel) getModel()).reload(tn);
                }
            }
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

            }
        }

        @Override
        public boolean isEnabled() {
            FileNode fn = getSelectedFileNode();
            return fn != null && fn.isTestcaseDir() && Desktop.isDesktopSupported();
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

        public TestOpenFolderAction() {
            super("Open folder");
        }

        public void actionPerformed(ActionEvent e) {
            FileNode fn = getSelectedFileNode();
            try {
                Desktop.getDesktop().open(fn.getFile().getAbsoluteFile());
            } catch (IOException ex) {
                logger.error("Error while calling Desktop open on " + fn.getFile().getAbsoluteFile());
            }
        }
View Full Code Here

Examples of com.qspin.qtaste.ui.tools.FileNode

            }
        }

        @Override
        public boolean isEnabled() {
            FileNode fn = getSelectedFileNode();
            return fn != null && Desktop.isDesktopSupported();
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.