OSDN Git Service

Refactor: rename PaletteComposite into PaletteControl
authorRaphael Moll <ralf@android.com>
Thu, 16 Dec 2010 22:18:55 +0000 (14:18 -0800)
committerRaphael Moll <ralf@android.com>
Fri, 17 Dec 2010 17:56:45 +0000 (09:56 -0800)
Change-Id: I7ce573d729255a07a65857a7f17d6a1cbb7f96d8

eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java
eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/PaletteControl.java [moved from eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/PaletteComposite.java with 99% similarity]

index a964c13..0c8257c 100644 (file)
@@ -193,7 +193,7 @@ public class GraphicalEditorPart extends EditorPart
     private SashForm mSashError;
 
     /** The palette displayed on the left of the sash. */
-    private PaletteComposite mPalette;
+    private PaletteControl mPalette;
 
     /** The layout canvas displayed to the right of the sash. */
     private LayoutCanvasViewer mCanvasViewer;
@@ -394,7 +394,7 @@ public class GraphicalEditorPart extends EditorPart
         mSashPalette = new SashForm(parent, SWT.HORIZONTAL);
         mSashPalette.setLayoutData(new GridData(GridData.FILL_BOTH));
 
-        mPalette = new PaletteComposite(mSashPalette, this);
+        mPalette = new PaletteControl(mSashPalette, this);
 
         mSashError = new SashForm(mSashPalette, SWT.VERTICAL | SWT.BORDER);
         mSashError.setLayoutData(new GridData(GridData.FILL_BOTH));
@@ -83,7 +83,7 @@ import javax.xml.parsers.DocumentBuilderFactory;
 import javax.xml.parsers.ParserConfigurationException;
 
 /**
- * A palette composite for the {@link GraphicalEditorPart}.
+ * A palette control for the {@link GraphicalEditorPart}.
  * <p/>
  * The palette contains several groups, each with a UI name (e.g. layouts and views) and each
  * with a list of element descriptors.
@@ -104,7 +104,7 @@ import javax.xml.parsers.ParserConfigurationException;
  *     - This would only be useful with meaningful icons. Out current 1-letter icons are not enough
  *       to get rid of text labels.
  */
-public class PaletteComposite extends Composite {
+public class PaletteControl extends Composite {
 
 
     /** The parent grid layout that contains all the {@link Toggle} and {@link Item} widgets. */
@@ -119,7 +119,7 @@ public class PaletteComposite extends Composite {
      * @param parent The parent composite.
      * @param editor An editor associated with this palette.
      */
-    public PaletteComposite(Composite parent, GraphicalEditorPart editor) {
+    public PaletteControl(Composite parent, GraphicalEditorPart editor) {
         super(parent, SWT.BORDER | SWT.V_SCROLL);
 
         mEditor = editor;
@@ -428,9 +428,9 @@ public class PaletteComposite extends Composite {
         private boolean mMouseIn;
         private DragSource mSource;
         private final ElementDescriptor mDesc;
-        public PaletteComposite mPalette;
+        public PaletteControl mPalette;
 
-        public Item(Composite parent, PaletteComposite palette, ElementDescriptor desc) {
+        public Item(Composite parent, PaletteControl palette, ElementDescriptor desc) {
             super(parent, SWT.NONE);
             mPalette = palette;
             mDesc = desc;