com.atlassian.jira.plugin.keyboardshortcut
Enum KeyboardShortcutManager.Operation

java.lang.Object
  extended by java.lang.Enum<KeyboardShortcutManager.Operation>
      extended by com.atlassian.jira.plugin.keyboardshortcut.KeyboardShortcutManager.Operation
All Implemented Interfaces:
Serializable, Comparable<KeyboardShortcutManager.Operation>
Enclosing interface:
KeyboardShortcutManager

public static enum KeyboardShortcutManager.Operation
extends Enum<KeyboardShortcutManager.Operation>

Defines the different operations that can be taken using a KeyboardShortcut. Operations are always coupled with a parameter which will generally be a jQuery selector or URL. The parameter can however also be more generic when coupled with the 'execute' operation where a generic javascript function can be specified as well.


Enum Constant Summary
click
          Clicks an element identified by a jQuery selector
evaluate
          Evaluates javascript on page load.
execute
          Executes a javascript functions specified by the operation parameter
followLink
          Sets the window.location to the href value of the link specified by the jQuery selector.
goTo
          Changes the window.location to go to a specified location
moveToAndClick
          Scrolls the window to an element and clicks that elment using a jQuery selector
moveToAndFocus
          Scrolls the window to a specific element and focuses that element using a jQuery selector
moveToNextItem
          Scrolls to and adds focused class to the next item in the jQuery collection
moveToPrevItem
          Scrolls to and adds focused class to the previous item in the jQuery collection
 
Method Summary
static KeyboardShortcutManager.Operation valueOf(String name)
          Returns the enum constant of this type with the specified name.
static KeyboardShortcutManager.Operation[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

click

public static final KeyboardShortcutManager.Operation click
Clicks an element identified by a jQuery selector


goTo

public static final KeyboardShortcutManager.Operation goTo
Changes the window.location to go to a specified location


followLink

public static final KeyboardShortcutManager.Operation followLink
Sets the window.location to the href value of the link specified by the jQuery selector.


moveToAndFocus

public static final KeyboardShortcutManager.Operation moveToAndFocus
Scrolls the window to a specific element and focuses that element using a jQuery selector


moveToAndClick

public static final KeyboardShortcutManager.Operation moveToAndClick
Scrolls the window to an element and clicks that elment using a jQuery selector


moveToNextItem

public static final KeyboardShortcutManager.Operation moveToNextItem
Scrolls to and adds focused class to the next item in the jQuery collection


moveToPrevItem

public static final KeyboardShortcutManager.Operation moveToPrevItem
Scrolls to and adds focused class to the previous item in the jQuery collection


execute

public static final KeyboardShortcutManager.Operation execute
Executes a javascript functions specified by the operation parameter


evaluate

public static final KeyboardShortcutManager.Operation evaluate
Evaluates javascript on page load. Execute above will execute the javascript provided when the keyboard shortcut is pressed.

Method Detail

values

public static KeyboardShortcutManager.Operation[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (KeyboardShortcutManager.Operation c : KeyboardShortcutManager.Operation.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static KeyboardShortcutManager.Operation valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null


Copyright © 2002-2012 Atlassian. All Rights Reserved.