OSDN Git Service

Use Reference Chooser rather than String dialog for "Edit Text"
authorTor Norbye <tnorbye@google.com>
Mon, 10 Jan 2011 03:43:23 +0000 (19:43 -0800)
committerTor Norbye <tnorbye@google.com>
Mon, 10 Jan 2011 03:43:23 +0000 (19:43 -0800)
Fix 13880: Dialog opened by contextual properties menu item should be
the reference chooser.

Change-Id: I88d994271217c96985a0e18c84efc16a232c2bd4

eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/common/layout/BaseViewRule.java

index 8346d6e..131bf7a 100644 (file)
@@ -186,7 +186,7 @@ public class BaseViewRule implements IViewRule {
                 } else if (fullActionId.equals(EDIT_TEXT_ID)) {
                     String oldText = node.getStringAttr(ANDROID_URI, ATTR_TEXT);
                     oldText = ensureValidString(oldText);
-                    String newText = mRulesEngine.displayInput("New Text:", oldText, null);
+                    String newText = mRulesEngine.displayReferenceInput(oldText);
                     if (newText != null) {
                         node.editXml("Change text", new PropertySettingNodeHandler(ANDROID_URI,
                                 ATTR_TEXT, newText));