Skip to main content

performOperation and getOptions don't actually pass selected documents

Comments

2 comments

  • Richard Moir

    It looks like it's because you return an empty array from getSelectionSignatures. The javadoc states:

    "If an operation accepts no documents as input, it should return an empty array and the operation will always be enabled but won't be passed any documents as input."

    If you want to accept any selection of documents rather than no documents you should have the following:

    public DocumentSelectionSignature[] getSelectionSignatures() {
      return new DocumentSelectionSignature[] {
        new DocumentSelectionSignature(PluginDocument.class, 1, Integer.MAX_VALUE)
      };
    }
    0
  • Informatiemanagement

    Ah, thanks for that!

    Ayco

    0

Please sign in to leave a comment.