aboutsummaryrefslogtreecommitdiffstats
path: root/eclipse/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'eclipse/plugins')
-rwxr-xr-xeclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/DynamicContextMenu.java4
-rwxr-xr-xeclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java4
2 files changed, 4 insertions, 4 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/DynamicContextMenu.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/DynamicContextMenu.java
index da7d643..96db650 100755
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/DynamicContextMenu.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/DynamicContextMenu.java
@@ -208,7 +208,7 @@ import java.util.regex.Pattern;
final TreeMap<String, ArrayList<MenuAction>> outActionsMap,
final TreeMap<String, MenuAction.Group> outGroupsMap) {
int maxMenuSelection = 0;
- for (CanvasSelection selection : mCanvas.getCanvasSelection()) {
+ for (CanvasSelection selection : mCanvas.getCanvasSelections()) {
List<MenuAction> viewActions = null;
if (selection != null) {
CanvasViewInfo vi = selection.getViewInfo();
@@ -244,7 +244,7 @@ import java.util.regex.Pattern;
// All the actions for the same id should have be equal
if (!actions.isEmpty()) {
- if (action.equals(actions.get(0))) {
+ if (!action.equals(actions.get(0))) {
// TODO Log verbose error for invalid type mismatch.
continue;
}
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java
index 4de76f9..9cb6385 100755
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java
@@ -442,11 +442,11 @@ class LayoutCanvas extends Canvas implements ISelectionProvider {
/**
* Returns the native {@link CanvasSelection} list.
*
- * @return An immutable list of {@link CanvasSelection}
+ * @return An immutable list of {@link CanvasSelection}. Can be empty but not null.
* @see #getSelection() {@link #getSelection()} to retrieve a {@link TreeViewer}
* compatible {@link ISelection}.
*/
- /* package */ List<CanvasSelection> getCanvasSelection() {
+ /* package */ List<CanvasSelection> getCanvasSelections() {
if (mUnmodifiableSelection == null) {
mUnmodifiableSelection = Collections.unmodifiableList(mSelections);
}