Examples of canNavigate()


Examples of com.intellij.openapi.fileEditor.OpenFileDescriptor.canNavigate()

                    if (migrationsFolder != null) {
                        migrationsFolder.refresh(false, true);
                        VirtualFile migrationFile = migrationsFolder.findFileByRelativePath(name + ".php"); //migrationPath + "migrations/" +
                        if (migrationFile != null) {
                            OpenFileDescriptor of = new OpenFileDescriptor(_project, migrationFile);
                            if (of.canNavigate()) {
                                of.navigate(true);
                            }
                        } else {
                            PluginManager.getLogger().error("Migrations file not founded");
                        }
View Full Code Here

Examples of com.intellij.pom.Navigatable.canNavigate()

            usage.navigate(false);
            usage.highlightInEditor();
          }
          else if (node.isLeaf()) {
            Navigatable navigatable = getNavigatableForNode(node);
            if (navigatable != null && navigatable.canNavigate()) {
              navigatable.navigate(false);
            }
          }
        }
      }
View Full Code Here

Examples of com.intellij.pom.Navigatable.canNavigate()

  private static Navigatable getNavigatableForNode(DefaultMutableTreeNode node) {
    Object userObject = node.getUserObject();
    if (userObject instanceof Navigatable) {
      final Navigatable navigatable = (Navigatable)userObject;
      return navigatable.canNavigate() ? navigatable : null;
    }
    return null;
  }

  /* nodes with non-valid data are not included */
 
View Full Code Here

Examples of com.intellij.pom.Navigatable.canNavigate()

          int[] ids = list.getSelectedIndices();
          if (ids == null || ids.length == 0) return;
          Object[] selectedElements = list.getSelectedValues();
          for (Object element : selectedElements) {
            Navigatable descriptor = EditSourceUtil.getDescriptor((PsiElement) element);
            if (descriptor != null && descriptor.canNavigate()) {
              descriptor.navigate(true);
            }
          }
        }
      };
View Full Code Here

Examples of com.intellij.psi.PsiDirectory.canNavigate()

      return myDir.isValid();
    }

    public void navigate(boolean focus) throws UnsupportedOperationException {
      final PsiDirectory directory = getDirectory();
      if (directory != null && directory.canNavigate()) {
        directory.navigate(focus);
      }
    }

    private PsiDirectory getDirectory() {
View Full Code Here

Examples of com.intellij.psi.PsiDirectory.canNavigate()

    private PsiDirectory getDirectory() {
      return PsiManager.getInstance(myProject).findDirectory(myDir);
    }
    public boolean canNavigate() {
      final PsiDirectory directory = getDirectory();
      return directory != null && directory.canNavigate();
    }

    public boolean canNavigateToSource() {
      return false;
    }
View Full Code Here

Examples of com.intellij.util.xml.DomElementNavigationProvider.canNavigate()

  public void navigate(final DomElement element) {
    if (element != null && element.isValid()) {
      final DomElement copy = element.createStableCopy();
      final DomElementNavigationProvider navigateProvider = getNavigationProviderName(element.getManager().getProject());

      if (navigateProvider != null && navigateProvider.canNavigate(copy)) {
        ApplicationManager.getApplication().invokeLater(new Runnable() {
          public void run() {
            doNavigate(navigateProvider, copy);
          }
        });
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.