Exemplo n.º 1
0
        private void ChangeBranch_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            SelectBranch frm = new SelectBranch();

            frm.ShowDialog();
            frm.Dispose();
            CurBranch.Text      = UpdateSystem.GetCurrentBranch();
            CurBranch.ForeColor = UpdateSystem.GetCurrentBranchColor();
            BranchToolTip.SetToolTip(CurBranch, UpdateSystem.GetCurrentBranchToolTip());
        }
Exemplo n.º 2
0
        private void InfoDialog_Load(object sender, EventArgs e)
        {
            if (!KeppySynthConfiguratorMain.IsInternetAvailable)
            {
                CFU.Visible = false;
            }

            ComputerInfo CI      = new ComputerInfo();
            String       Version = String.Format("{0}.{1}.{2}", Driver.FileMajorPart, Driver.FileMinorPart, Driver.FileBuildPart);

            VerLabel.Text       = String.Format("Keppy's Synthesizer {0}\n\nCopyright Ⓒ 2011\nKaleidonKep99, Kode54 && Mudlord", Version, DateTime.Now.Year.ToString());
            DriverVer.Text      = ReturnDriverAssemblyVersion(Version, Driver.FilePrivatePart);
            BASSVer.Text        = ReturnBASSAssemblyVersion(BASS.FileVersion, BASS.FilePrivatePart);
            BASSMIDIVer.Text    = ReturnBASSAssemblyVersion(BASSMIDI.FileVersion, BASSMIDI.FilePrivatePart);
            CompiledOn.Text     = GetLinkerTime(Assembly.GetExecutingAssembly(), TimeZoneInfo.Utc).ToString();
            CurBranch.Text      = UpdateSystem.GetCurrentBranch();
            CurBranch.ForeColor = UpdateSystem.GetCurrentBranchColor();
            BranchToolTip.SetToolTip(CurBranch, UpdateSystem.GetCurrentBranchToolTip());

            OSInfo.OSVERSIONINFOEX osVersionInfo = new OSInfo.OSVERSIONINFOEX();
            osVersionInfo.dwOSVersionInfoSize = Marshal.SizeOf(typeof(OSInfo.OSVERSIONINFOEX));

            if (Properties.Settings.Default.IsItPreRelease)
            {
                DriverVer.Text += " (Pre-release build)";
            }

            WinName.Text = String.Format("{0} ({1})", OSInfo.Name, Environment.Is64BitOperatingSystem ? "64-bit" : "32-bit");

            if (Environment.OSVersion.Version.Major == 10) // If OS is Windows 10, get UBR too
            {
                WinVer.Text = String.Format("{0}.{1}.{2} (Update Build Revision {3})",
                                            Environment.OSVersion.Version.Major, Environment.OSVersion.Version.Minor,
                                            Environment.OSVersion.Version.Build, CurrentVerKey.GetValue("UBR", 0).ToString());
            }
            else // Else, give normal version number
            {
                if (Environment.OSVersion.Version.Major == 6 && Environment.OSVersion.Version.Minor <= 1)
                {
                    WinVer.Text = String.Format("{0}.{1}.{2} ({3})",
                                                Environment.OSVersion.Version.Major, Environment.OSVersion.Version.Minor,
                                                Environment.OSVersion.Version.Build, Environment.OSVersion.ServicePack);
                }
                else
                {
                    WinVer.Text = String.Format("{0}.{1}.{2} (Metro)",
                                                Environment.OSVersion.Version.Major, Environment.OSVersion.Version.Minor,
                                                Environment.OSVersion.Version.Build);
                }
            }

            CheckDateLogo();
        }