Exemple #1
0
 protected void OnMenuItemSaved(MenuItemSavedEventArgs e)
 {
     if (MenuItemSaved != null)
     {
         MenuItemSaved(this, e);
     }
 }
Exemple #2
0
 protected void OnMenuItemCancel(MenuItemSavedEventArgs e)
 {
     if (MenuItemCancel != null)
     {
         MenuItemCancel(this, e);
     }
 }
Exemple #3
0
 private void menuEditor_MenuItemSaved(object sender, MenuItemSavedEventArgs e)
 {
     if (ctlTreeViewMenuBar.FocusedNode != null)
     {
         ctlTreeViewMenuBar.FocusedNode.SetValue("colCaption", e.MenuItem.Caption);
         ctlTreeViewMenuBar.FocusedNode.SetValue("colObjeto", e.MenuItem);
     }
 }
Exemple #4
0
        private void menuEditor_MenuItemSaved(object sender, MenuItemSavedEventArgs e)
        {
            uC_NavMenu1.ActiveGroupChanged -= new DevExpress.XtraNavBar.NavBarGroupEventHandler(uC_NavMenu1_ActiveGroupChanged);

            #region Group
            if (grpEditionContainer.Controls[0].GetType() == typeof(UC_ButtonGroupEditor))
            {
                if (((UC_ButtonGroupEditor)grpEditionContainer.Controls[0]).ActionType == ActionTypes.Create)
                {
                    uC_NavMenu1.Add_BarGroup((BarGroup)e.MenuItem, true);
                }
                else
                {
                    uC_NavMenu1.Update_BarGroup((BarGroup)e.MenuItem);
                }
            }
            #endregion

            #region  Simple button
            if (grpEditionContainer.Controls[0].GetType() == typeof(UC_ButtonBaseEditor))
            {
                if (((UC_ButtonBaseEditor)grpEditionContainer.Controls[0]).ActionType == ActionTypes.Create)
                {
                    uC_NavMenu1.Add_ItemToGroup(uC_NavMenu1.ActiveGroup, (Fwk.UI.Controls.Menu.ButtonBase)e.MenuItem);
                }
                else
                {
                    uC_NavMenu1.Update_ItemFromGroup((Fwk.UI.Controls.Menu.ButtonBase)e.MenuItem);
                }
            }

            SaveToFile(_SelectedMenuFile);
            #endregion

            grpEditionContainer.Controls.Clear();
            uC_NavMenu1.ActiveGroupChanged += new DevExpress.XtraNavBar.NavBarGroupEventHandler(uC_NavMenu1_ActiveGroupChanged);
        }
Exemple #5
0
 void groupEditor_MenuItemCancel(object sender, MenuItemSavedEventArgs e)
 {
     grpEditionContainer.Controls.Clear();
 }