Examples of RevertLinkAction


Examples of org.wikipediacleaner.gui.swing.action.RevertLinkAction

      if (!Page.areSameTitle(text, page.getTitle())) {
        String newLink = PageElementInternalLink.createInternalLink(text, page.getTitle());
        addItem(
            popup, null, GT._("Reverse to {0}", newLink), true,
            new RevertLinkAction(page.getTitle(), text, element, textPane), null);
      }

    // Redirect page
    } else if (page.isRedirect()) {
      String title = page.getRedirectTitle();

      addItem(
          popup, null, GT._("&Link to {0}", title), false,
          new ReplaceLinkAction(page.getTitle(), title, text, element, textPane, false));

      addItem(
          popup, null, GT._("&Replace with {0}", title), false,
          new ReplaceLinkAction(page.getTitle(), title, text, element, textPane, true));

      if (!Page.areSameTitle(text, page.getTitle())) {
        String newLink = PageElementInternalLink.createInternalLink(text, page.getTitle());
        addItem(
            popup, null, GT._("Reverse to {0}", newLink), true,
            new RevertLinkAction(page.getTitle(), text, element, textPane));
      }

    // Missing page
    } else if (Boolean.FALSE.equals(page.isExisting())) {
      if (!Page.areSameTitle(text, page.getTitle())) {
        String newLink = PageElementInternalLink.createInternalLink(text, page.getTitle());
        addItem(
            popup, null, GT._("Reverse to {0}", newLink), true,
            new RevertLinkAction(page.getTitle(), text, element, textPane));
      }
    }
  }
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.