Exemple #1
0
        public MainForm()
        {
            InitializeComponent();
            #region 初始化 OutLookBar
            outlookBar.BorderStyle = BorderStyle.FixedSingle;
            outlookBar.Initialize();
            IconPanel iconPanel1 = new IconPanel();
            iconPanel1.BorderStyle = BorderStyle.FixedSingle;
            IconPanel iconPanel2 = new IconPanel();
            IconPanel iconPanel3 = new IconPanel();

            outlookBar.AddBand("工具条A", iconPanel1);
            outlookBar.AddBand("工具条B", iconPanel2);
            outlookBar.AddBand("工具条C", iconPanel3);

            //0
            iconPanel1.AddIcon("信息查询", Image.FromFile(@"Image\1.ico"), new EventHandler(PanelEventA));
            //1
            iconPanel1.AddIcon("购物车管理", Image.FromFile(@"Image\2.ico"), new EventHandler(PanelEventA));
            //2
            iconPanel2.AddIcon("电子邮件", Image.FromFile(@"Image\3.ico"), new EventHandler(PanelEventB));
            //3
            iconPanel2.AddIcon("密码管理", Image.FromFile(@"Image\4.ico"), new EventHandler(PanelEventB));
            //4
            iconPanel3.AddIcon("时间设置", Image.FromFile(@"Image\4.ico"), new EventHandler(PanelEventC));
            outlookBar.SelectBand(0);
            #endregion
        }
Exemple #2
0
        /// <summary>
        /// 初始化工具栏中的内容
        /// </summary>
        public void initToolBar()
        {
            List <string> groups = layoutBLL.getAllGroupName();

            for (int i = 0; i < groups.Count; i++)
            {
                IconPanel iconPanel1 = new IconPanel();

                MainToolBar.AddBand(groups[i].ToString(), iconPanel1);
                List <Outlook_Table_Jb_User> items = layoutBLL.getItemNameByGroupName(groups[i].ToString());
                table.Add(iconPanel1, items);
                for (int j = 0; j < items.Count; j++)
                {
                    Outlook_Table_Jb_User outlook = items[j];
                    iconPanel1.AddIcon(outlook.Itemname, imlMain.Images[outlook.Picname], new MouseEventHandler(PanelEvent));
                }
            }
            //if (groups.Count < 3)
            //{
            MainToolBar.SelectBand(0);
            //}
            //else
            //{
            //    MainToolBar.SelectBand(3);
            //    openWatchMain();
            //}
        }
Exemple #3
0
    private void makeIcon(Entity ent, GameTypes.IconType itype)
    {
        IconPanel ip = Instantiate(ObjectManager.getMenu("IconPanel"), mCameraSpaceCanvas.transform).GetComponent <IconPanel>();

        ip.mEntity   = ent;
        ip.mIconType = itype;
        ip.mActive   = true;
        //add it to the list to keep track
        mIcons.Add(ip);
    }
Exemple #4
0
 private void manageIcons()
 {
     //remove icons if no longer necessary
     for (int i = mIcons.Count - 1; i >= 0; i--)
     {
         if (needsIcon(mIcons[i].mEntity) == GameTypes.IconType.Unknown)
         {
             IconPanel pan = mIcons[i];
             mIcons.RemoveAt(i);
             Destroy(pan.gameObject);
         }
     }
 }
Exemple #5
0
 public FileSelectionEntry(Panel parent) : base(parent)
 {
     FileTypeIcon  = Add.Icon(null, "filetype");
     FileNameLabel = Add.Label("", "filename");
 }