Example #1
0
        public override bool IsEquivalentTo(ActionNodeEntityHandler other)
        {
            if (other.GetType() != GetType())
            {
                return(false);
            }

            return(Action.ActionID == ((ActionEntityHandler)other).Action.ActionID);
        }
Example #2
0
        public override bool IsEquivalentTo(ActionNodeEntityHandler other)
        {
            if (other.GetType() != GetType())
            {
                return(false);
            }

            return(AreEquivalent(ChildHandlers, ((BranchActionEntityHandler)other).ChildHandlers));
        }
Example #3
0
        private void UpdateActionModel(bool notify)
        {
            DisposeActionHandlers();
            _actionHandlers.AddRange(ActionNodeEntityHandler.Create(_viewer.ToolbarModel.ChildNodes));
            if (!notify)
            {
                return;
            }

            NotifyEntityPropertyChanged("ToolbarActions", GetToolbarActionEntities());
        }
Example #4
0
        public static List <ActionNodeEntityHandler> Create(ActionModelNodeList nodes)
        {
            var handlers = new List <ActionNodeEntityHandler>();

            foreach (ActionModelNode node in nodes)
            {
                //TODO (CR May 2010): remove the try/catch and let it crash?
                try
                {
                    ActionNodeEntityHandler handler = Create(node);
                    if (handler != null)
                    {
                        handlers.Add(handler);
                    }
                }
                catch (Exception e)
                {
                    Platform.Log(LogLevel.Error, e,
                                 "Unexpected exception processing action node: {0}", node);
                }
            }

            return(handlers);
        }
Example #5
0
 public override bool IsEquivalentTo(ActionNodeEntityHandler other)
 {
     return(base.IsEquivalentTo(other) &&
            AreEquivalent(ChildHandlers, ((DropDownActionEntityHandler)other).ChildHandlers));
 }
Example #6
0
 public abstract bool IsEquivalentTo(ActionNodeEntityHandler other);
Example #7
0
		public override bool IsEquivalentTo(ActionNodeEntityHandler other)
		{
			return base.IsEquivalentTo(other) && 
			       AreEquivalent(ChildHandlers, ((DropDownActionEntityHandler)other).ChildHandlers);
		}
Example #8
0
		public abstract bool IsEquivalentTo(ActionNodeEntityHandler other);
Example #9
0
		public override bool IsEquivalentTo(ActionNodeEntityHandler other)
		{
			if (other.GetType() != GetType())
				return false;

			return Action.ActionID == ((ActionEntityHandler)other).Action.ActionID;
		}
Example #10
0
		public override bool IsEquivalentTo(ActionNodeEntityHandler other)
		{
			if (other.GetType() != GetType())
				return false;

			return AreEquivalent(ChildHandlers, ((BranchActionEntityHandler)other).ChildHandlers);
		}
Example #11
0
 public ContextMenuContainer(ActionModelNode modelNode)
 {
     _contextMenuHandlers = ActionNodeEntityHandler.Create(modelNode.ChildNodes);
 }