Ejemplo n.º 1
0
        public frmMain(string[] args) {
            InitializeComponent();

            this.SetStyle(ControlStyles.UserPaint, true);
            this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
            this.SetStyle(ControlStyles.DoubleBuffer, true);
            
            this.m_blExit = false;

            this.m_frmAbout = new frmAbout();

            this.m_cnmNotificationMenu = new ContextMenu();

            this.m_mnuHideTrayIcon = new MenuItem {
                Index = 0,
                Text = @"Hide Tray Icon"
            };
            this.m_mnuHideTrayIcon.Click += new System.EventHandler(this.m_mnuHideTrayIcon_Click);
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuHideTrayIcon);

            this.m_mnuSeparator = new MenuItem {
                Index = 1,
                Text = @"-"
            };
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuSeparator);

            this.m_mnuExit = new MenuItem {
                Index = 2,
                Text = @"Exit"
            };
            this.m_mnuExit.Click += new System.EventHandler(this.m_mnuExit_Click);
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuExit);

            this.ntfIcon.ContextMenu = this.m_cnmNotificationMenu;

            this.toolsStripDropDownButton.Image = this.iglIcons.Images["wrench.png"];
            this.manageAccountsToolStripMenuItem.Image = this.iglIcons.Images["vcard.png"];

            this.btnStartPage.Image = this.iglIcons.Images["home.png"];
            this.btnShiftServerPrevious.Image = this.iglIcons.Images["arrow-transition-180.png"];
            this.btnShiftServerNext.Image = this.iglIcons.Images["arrow-transition.png"];

            this.checkForUpdatesToolStripMenuItem.Image = this.iglIcons.Images["check.png"];

            //this.toolStripDownloading.Image = picAjaxStyleLoading.Image;

            this.cboServerList.ComboBox.DrawMode = DrawMode.OwnerDrawFixed;
            this.cboServerList.ComboBox.DrawItem += new DrawItemEventHandler(ComboBox_DrawItem);


            //this.m_cdfVersionChecker = new CDownloadFile("http://www.phogue.net/procon/version3.php");
            //this.m_cdfVersionChecker.DownloadComplete += new CDownloadFile.DownloadFileEventDelegate(m_cdfVersionChecker_DownloadComplete);
            //this.m_cdfVersionChecker.DownloadError += new CDownloadFile.DownloadFileEventDelegate(m_cdfVersionChecker_DownloadError);

            //this.m_lstDownloadingLocalizations = new List<CDownloadFile>();

            // Default language.
            //this.m_frmOptions.LocalizationFilename = "au.loc";
        }
Ejemplo n.º 2
0
        public frmMain(string[] args)
        {
            InitializeComponent();

            this.SetStyle(ControlStyles.UserPaint, true);
            this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
            this.SetStyle(ControlStyles.DoubleBuffer, true);

            this.m_blExit = false;

            this.m_frmAbout = new frmAbout();

            this.m_cnmNotificationMenu = new ContextMenu();

            this.m_mnuHideTrayIcon = new MenuItem
            {
                Index = 0,
                Text  = @"Hide Tray Icon"
            };
            this.m_mnuHideTrayIcon.Click += new System.EventHandler(this.m_mnuHideTrayIcon_Click);
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuHideTrayIcon);

            this.m_mnuSeparator = new MenuItem
            {
                Index = 1,
                Text  = @"-"
            };
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuSeparator);

            this.m_mnuExit = new MenuItem
            {
                Index = 2,
                Text  = @"Exit"
            };
            this.m_mnuExit.Click += new System.EventHandler(this.m_mnuExit_Click);
            this.m_cnmNotificationMenu.MenuItems.Add(this.m_mnuExit);

            this.ntfIcon.ContextMenu = this.m_cnmNotificationMenu;

            this.toolsStripDropDownButton.Image        = this.iglIcons.Images["wrench.png"];
            this.manageAccountsToolStripMenuItem.Image = this.iglIcons.Images["vcard.png"];

            this.btnStartPage.Image           = this.iglIcons.Images["home.png"];
            this.btnShiftServerPrevious.Image = this.iglIcons.Images["arrow-transition-180.png"];
            this.btnShiftServerNext.Image     = this.iglIcons.Images["arrow-transition.png"];

            this.checkForUpdatesToolStripMenuItem.Image = this.iglIcons.Images["check.png"];

            //this.toolStripDownloading.Image = picAjaxStyleLoading.Image;

            this.cboServerList.ComboBox.DrawMode  = DrawMode.OwnerDrawFixed;
            this.cboServerList.ComboBox.DrawItem += new DrawItemEventHandler(ComboBox_DrawItem);


            //this.m_cdfVersionChecker = new CDownloadFile("http://www.phogue.net/procon/version3.php");
            //this.m_cdfVersionChecker.DownloadComplete += new CDownloadFile.DownloadFileEventDelegate(m_cdfVersionChecker_DownloadComplete);
            //this.m_cdfVersionChecker.DownloadError += new CDownloadFile.DownloadFileEventDelegate(m_cdfVersionChecker_DownloadError);

            //this.m_lstDownloadingLocalizations = new List<CDownloadFile>();

            // Default language.
            //this.m_frmOptions.LocalizationFilename = "au.loc";
        }