當前位置: 首頁>>代碼示例>>C#>>正文


C# Browser.Setup方法代碼示例

本文整理匯總了C#中Browser.Setup方法的典型用法代碼示例。如果您正苦於以下問題:C# Browser.Setup方法的具體用法?C# Browser.Setup怎麽用?C# Browser.Setup使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Browser的用法示例。


在下文中一共展示了Browser.Setup方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: Form1_Load

        //default functionality as form loads
        private void Form1_Load(object sender, EventArgs e)
        {
            //objects which reference the form and/or other class objects

            //option objects
            this.aspectOption = new Option(installer, aspectCombobox, aspectPicturebox, aspectLabel, Properties.Settings.Default.settingComboboxAspect);
            this.scoreboardMinmodeOption = new Option(installer, scoreboardMinmodeCombobox, scoreboardMinmodePicturebox, scoreboardMinmodeLabel, Properties.Settings.Default.settingComboboxMinmode);
            this.scoreboardMaxmodeOption = new Option(installer, scoreboardMaxmodeCombobox, scoreboardMaxmodePicturebox, scoreboardMaxmodeLabel, Properties.Settings.Default.settingComboboxMaxmode);

            //hud location objects
            this.assetLocation = new Location();
            this.installLocation = new Location();

            //one-off class objects
            this.buttons = new Buttons(this, uninstallButton, installButton);
            this.installer = new Installer(buttons, assetLocation, installLocation);
            this.uninstaller = new Uninstaller();
            this.browser = new Browser(installer, InstallBrowserDialog, InstallBrowserPathLabel, InstallBrowserInstructLabel, Properties.Settings.Default.settingInstallBrowserPath);
            this.downloader = new Downloader(assetLocation, installLocation);

            this.tracker = new Tracker(buttons, installer, assetLocation, installLocation, aspectOption, scoreboardMinmodeOption, scoreboardMaxmodeOption);

            //TODO make these actually dynamic
            //assetLocation.VersionHud = new Version("2.0.4");
            //installLocation.VersionHud = new Version("2.0.4");

            //MessageBox.Show(Convert.ToString("asset version " + assetLocation.VersionHud));
            //MessageBox.Show(Convert.ToString("install version " + installLocation.VersionHud));

            //generate tooltips for the form
            updateTooltips();

            //Generate tooltips, populate strings, comboboxes, and assets.
            tracker.Setup();

            //Fill the browser with a best guess default string or a saved string, if one exists
            browser.Setup();

            //download current updates and check if they need to be installed
            if (downloader.checkAndUpdate())
            {
                //TODO special mode for the install button
            }
        }
開發者ID:TDarkShadow,項目名稱:thwartski-tf2-hud,代碼行數:45,代碼來源:Form1.cs


注:本文中的Browser.Setup方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。