Home
last modified time | relevance | path

Searched refs:RuleAction (Results 1 – 21 of 21) sorted by relevance

/sdk/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/common/layout/
DLinearLayoutRuleTest.java35 import com.android.ide.common.api.RuleAction;
36 import com.android.ide.common.api.RuleAction.NestedAction;
131 List<RuleAction> contextMenu = new ArrayList<RuleAction>(); in testContextMenu()
135 assertTrue(contextMenu.get(1) instanceof RuleAction.Separator); in testContextMenu()
138 assertTrue(contextMenu.get(4) instanceof RuleAction.Separator); in testContextMenu()
141 RuleAction propertiesMenu = contextMenu.get(5); in testContextMenu()
153 List<RuleAction> contextMenu = new ArrayList<RuleAction>(); in testContextMenuCustom()
157 RuleAction menuAction = contextMenu.get(2); in testContextMenuCustom()
158 assertTrue(menuAction instanceof RuleAction.Choices); in testContextMenuCustom()
159 RuleAction.Choices choices = (RuleAction.Choices) menuAction; in testContextMenuCustom()
[all …]
/sdk/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/common/layout/
DBaseViewRule.java50 import com.android.ide.common.api.RuleAction;
51 import com.android.ide.common.api.RuleAction.ActionProvider;
52 import com.android.ide.common.api.RuleAction.ChoiceProvider;
127 public void addContextMenuActions(@NonNull List<RuleAction> actions, in addContextMenuActions()
159 final @NonNull RuleAction action, in addContextMenuActions()
375 actions.add(RuleAction.createAction(PROP_PREFIX + ATTR_TEXT, "Edit Text...", onChange, in addContextMenuActions()
381 actions.add(RuleAction.createAction(ATTR_ID, editIdLabel, onChange, null, 20, true)); in addContextMenuActions()
386 actions.add(RuleAction.createSeparator(32)); in addContextMenuActions()
398 actions.add(RuleAction.createChoices( in addContextMenuActions()
419 actions.add(RuleAction.createChoices( in addContextMenuActions()
[all …]
DTableLayoutRule.java29 import com.android.ide.common.api.RuleAction;
75 public void addContextMenuActions(@NonNull List<RuleAction> actions, in addContextMenuActions()
82 @NonNull RuleAction action, in addContextMenuActions()
91 … actions.add(RuleAction.createAction("_addrow", "Add Row", addTab, null, 5, false)); //$NON-NLS-1$ in addContextMenuActions()
96 @NonNull List<RuleAction> actions, in addLayoutActions()
107 List<RuleAction> actions, final INode parentNode, in addTableLayoutActions()
112 final @NonNull RuleAction action, in addTableLayoutActions()
174 actions.add(RuleAction.createSeparator(150)); in addTableLayoutActions()
175 actions.add(RuleAction.createAction(ACTION_ADD_ROW, "Add Table Row", actionCallback, in addTableLayoutActions()
180 actions.add(RuleAction.createAction(ACTION_REMOVE_ROW, "Remove Table Row", in addTableLayoutActions()
DEditTextRule.java30 import com.android.ide.common.api.RuleAction;
63 public void addContextMenuActions(@NonNull List<RuleAction> actions, in addContextMenuActions()
73 @NonNull RuleAction menuAction, in addContextMenuActions()
92 actions.add(RuleAction.createAction("_setfocus", label, onChange, //$NON-NLS-1$ in addContextMenuActions()
94 actions.add(RuleAction.createSeparator(7)); in addContextMenuActions()
DMergeRule.java21 import com.android.ide.common.api.RuleAction;
33 public void addContextMenuActions(@NonNull List<RuleAction> actions, in addContextMenuActions()
DGridLayoutRule.java50 import com.android.ide.common.api.RuleAction;
51 import com.android.ide.common.api.RuleAction.Choices;
154 @NonNull List<RuleAction> actions, in addLayoutActions()
160 Choices orientationAction = RuleAction.createChoices( in addLayoutActions()
174 actions.add(RuleAction.createSeparator(35)); in addLayoutActions()
182 final @NonNull RuleAction action, in addLayoutActions()
224 actions.add(RuleAction.createSeparator(142)); in addLayoutActions()
226 actions.add(RuleAction.createToggle(ACTION_GRID_MODE, "Grid Model Mode", in addLayoutActions()
232 actions.add(RuleAction.createSeparator(150)); in addLayoutActions()
233 actions.add(RuleAction.createAction(ACTION_ADD_COL, "Add Column", actionCallback, in addLayoutActions()
[all …]
DRelativeLayoutRule.java53 import com.android.ide.common.api.RuleAction;
308 @NonNull List<RuleAction> actions, in addLayoutActions()
315 actions.add(RuleAction.createSeparator(25)); in addLayoutActions()
320 public void action(@NonNull RuleAction action, in addLayoutActions()
355 actions.add(RuleAction.createSeparator(150)); in addLayoutActions()
356 actions.add(RuleAction.createAction(ACTION_CENTER_VERTICAL, "Center Vertically", in addLayoutActions()
358 actions.add(RuleAction.createAction(ACTION_CENTER_HORIZONTAL, "Center Horizontally", in addLayoutActions()
362 actions.add(RuleAction.createSeparator(80)); in addLayoutActions()
363 actions.add(RuleAction.createToggle(ACTION_SHOW_CONSTRAINTS, "Show Constraints", in addLayoutActions()
365 actions.add(RuleAction.createToggle(ACTION_SHOW_STRUCTURE, "Show All Relationships", in addLayoutActions()
DPropertyCallback.java24 import com.android.ide.common.api.RuleAction;
59 public void action(@NonNull RuleAction action, @NonNull List<? extends INode> selectedNodes, in action()
DTableRowRule.java26 import com.android.ide.common.api.RuleAction;
55 @NonNull List<RuleAction> actions, in addLayoutActions()
DLinearLayoutRule.java52 import com.android.ide.common.api.RuleAction;
53 import com.android.ide.common.api.RuleAction.Choices;
128 @NonNull List<RuleAction> actions, in addLayoutActions()
133 Choices action = RuleAction.createChoices( in addLayoutActions()
152 actions.add(RuleAction.createToggle(ACTION_BASELINE, "Toggle Baseline Alignment", in addLayoutActions()
162 actions.add(RuleAction.createSeparator(35)); in addLayoutActions()
174 final @NonNull RuleAction action, in addLayoutActions()
211 actions.add(RuleAction.createSeparator(50)); in addLayoutActions()
212 actions.add(RuleAction.createAction(ACTION_DISTRIBUTE, "Distribute Weights Evenly", in addLayoutActions()
214 actions.add(RuleAction.createAction(ACTION_DOMINATE, "Assign All Weight", in addLayoutActions()
[all …]
DFrameLayoutRule.java39 import com.android.ide.common.api.RuleAction;
167 @NonNull List<RuleAction> actions,
171 actions.add(RuleAction.createSeparator(25));
DBaseLayoutRule.java74 import com.android.ide.common.api.RuleAction;
75 import com.android.ide.common.api.RuleAction.ChoiceProvider;
109 protected final RuleAction createMarginAction(final INode parentNode, in createMarginAction()
119 public void action(@NonNull RuleAction action, in createMarginAction()
149 return RuleAction.createAction(ACTION_MARGIN, "Change Margins...", actionCallback, in createMarginAction()
155 protected final RuleAction createGravityAction(final List<? extends INode> targets, final in createGravityAction()
175 return RuleAction.createChoices("_gravity", "Change Gravity", //$NON-NLS-1$ in createGravityAction()
188 @NonNull List<RuleAction> actions, in addLayoutActions()
202 @NonNull RuleAction action, in addLayoutActions()
238 actions.add(RuleAction.createToggle(ACTION_FILL_WIDTH, "Toggle Fill Width", in addLayoutActions()
[all …]
/sdk/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/
DDynamicContextMenu.java34 import com.android.ide.common.api.RuleAction;
35 import com.android.ide.common.api.RuleAction.Choices;
36 import com.android.ide.common.api.RuleAction.NestedAction;
37 import com.android.ide.common.api.RuleAction.Toggle;
188 Map<INode, List<RuleAction>> allActions = new HashMap<INode, List<RuleAction>>(); in getMenuItems()
190 List<RuleAction> actionList = getMenuActions((NodeProxy) node); in getMenuItems()
205 List<RuleAction> firstSelectedActions = allActions.get(first); in getMenuItems()
207 for (RuleAction action : firstSelectedActions) { in getMenuItems()
209 && !(action instanceof RuleAction.Separator)) { in getMenuItems()
316 private Set<String> computeApplicableActionIds(Map<INode, List<RuleAction>> actions) { in computeApplicableActionIds()
[all …]
DLayoutActionBar.java23 import com.android.ide.common.api.RuleAction;
24 import com.android.ide.common.api.RuleAction.Choices;
25 import com.android.ide.common.api.RuleAction.Separator;
26 import com.android.ide.common.api.RuleAction.Toggle;
81 private List<RuleAction> mPrevActions;
146 List<RuleAction> actions = new ArrayList<RuleAction>(); in updateSelection()
159 List<RuleAction> itemActions = new ArrayList<RuleAction>(); in updateSelection()
165 if (!(itemActions.get(0) instanceof RuleAction.Separator)) { in updateSelection()
166 actions.add(RuleAction.createSeparator(0)); in updateSelection()
184 private void updateToolbar(final List<RuleAction> actions, final int labelIndex, in updateToolbar()
[all …]
DSelectionManager.java31 import com.android.ide.common.api.RuleAction;
1137 final List<RuleAction> actions = rulesEngine.callGetContextMenu(primary); in performDefaultAction()
1141 RuleAction matching = null; in performDefaultAction()
1142 for (RuleAction a : actions) { in performDefaultAction()
1158 final RuleAction action = matching; in performDefaultAction()
DPaletteControl.java29 import com.android.ide.common.api.RuleAction.Toggle;
/sdk/rule_api/src/com/android/ide/common/api/
DRuleAction.java49 public class RuleAction implements Comparable<RuleAction> { class
123 public static RuleAction createAction( in createAction()
130 RuleAction action = new RuleAction(id, title, callback, sortPriority, in createAction()
333 private RuleAction( in RuleAction() method in RuleAction
374 if (obj instanceof RuleAction) { in equals()
375 RuleAction rhs = (RuleAction) obj; in equals()
425 public RuleAction setIconUrl(URL iconUrl) { in setIconUrl()
453 public int compareTo(RuleAction other) { in compareTo()
468 public static class Separator extends RuleAction {
483 public static class Toggle extends RuleAction {
[all …]
DIMenuCallback.java48 @NonNull RuleAction action, in action()
58 @NonNull RuleAction action,
DIViewRule.java102 void addContextMenuActions(@NonNull List<RuleAction> actions, @NonNull INode node); in addContextMenuActions()
128 @NonNull List<RuleAction> actions, in addLayoutActions()
DAbstractViewRule.java57 public void addLayoutActions(@NonNull List<RuleAction> actions, @NonNull INode parentNode, in addLayoutActions()
62 public void addContextMenuActions(@NonNull List<RuleAction> actions, @NonNull INode node) { in addContextMenuActions()
/sdk/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gre/
DRulesEngine.java32 import com.android.ide.common.api.RuleAction;
160 public List<RuleAction> callGetContextMenu(NodeProxy selectedNode) { in callGetContextMenu()
167 List<RuleAction> actions = new ArrayList<RuleAction>(); in callGetContextMenu()
218 public List<RuleAction> callAddLayoutActions(List<RuleAction> actions, in callAddLayoutActions()