A massive organize imports and formatting of the sources using default Eclipse code...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / ui / actions / GotoMatchingBracketAction.java
1 package net.sourceforge.phpdt.ui.actions;
2
3 /*
4  * (c) Copyright IBM Corp. 2000, 2001.
5  * All Rights Reserved.
6  */
7
8 import net.sourceforge.phpdt.internal.corext.Assert;
9 import net.sourceforge.phpeclipse.phpeditor.PHPEditor;
10 import net.sourceforge.phpeclipse.phpeditor.PHPEditorMessages;
11
12 import org.eclipse.jface.action.Action;
13
14 public class GotoMatchingBracketAction extends Action {
15
16         public final static String GOTO_MATCHING_BRACKET = "GotoMatchingBracket"; //$NON-NLS-1$
17
18         private final PHPEditor fEditor;
19
20         public GotoMatchingBracketAction(PHPEditor editor) {
21                 super(PHPEditorMessages.getString("GotoMatchingBracket.label"));
22                 Assert.isNotNull(editor);
23                 fEditor = editor;
24                 setEnabled(null != fEditor);
25         }
26
27         public void run() {
28                 fEditor.gotoMatchingBracket();
29         }
30
31 }