Exemplo n.º 1
0
 public ActionSeparatorItemModel(ActionSeparatorItemModel a, IdeCollection <IdeBaseItem> source) : base(source)
 {
     _action = new GroupActionSeparator()
     {
         HeaderExecute = a._action.HeaderExecute,
         IsGroup       = a.IsGroup,
         Name          = a.Name,
         ShowExecute   = a._action.ShowExecute
     };
 }
Exemplo n.º 2
0
 public ActionSeparatorItemModel(ActionSeparatorItemModel a)
 {
     Action = new GroupActionSeparator()
     {
         HeaderExecute = ((GroupActionSeparator)a.Action).HeaderExecute,
         IsGroup       = ((GroupActionSeparator)a.Action).IsGroup,
         Name          = ((GroupActionSeparator)a.Action).Name,
         ShowExecute   = ((GroupActionSeparator)a.Action).ShowExecute
     };
     Parent     = a.Parent;
     ItemSource = a.ItemSource;
 }
Exemplo n.º 3
0
        public static IBaseAction CopyActionItems(IdeBaseItem action, IdeCollection <IdeBaseItem> source)
        {
            IBaseAction ret = null;

            if (action is ActionItemModel)
            {
                ret = new ActionItemModel((ActionItemModel)action, source);
            }
            else if (action is ActionSubmenuItemModel)
            {
                ret = new ActionSubmenuItemModel((ActionSubmenuItemModel)action, source);
            }
            else if (action is ActionSeparatorItemModel)
            {
                ret = new ActionSeparatorItemModel((ActionSeparatorItemModel)action, source);
            }
            return(ret);
        }
Exemplo n.º 4
0
        public static IBaseAction CreateActionItem(IGroupAction action, IdeCollection <IdeBaseItem> source)
        {
            IBaseAction ret = null;

            if (action is GroupAction)
            {
                ret = new ActionItemModel((GroupAction)action, source);
            }
            else if (action is GroupActionSubmenu)
            {
                ret = new ActionSubmenuItemModel((GroupActionSubmenu)action, source);
            }
            else if (action is GroupActionSeparator)
            {
                ret = new ActionSeparatorItemModel((GroupActionSeparator)action, source);
            }
            return(ret);
        }