Beispiel #1
0
        private void SetFrameSpeed(FrameSpeedOption value)
        {
            _fps = value;

            if (_fps == FrameSpeedOption.FPS25)
            {
                fpsToolStripMenuItem25.Checked = true;
                _fpsvalue = 25;
            }
            else fpsToolStripMenuItem25.Checked = false;

            if (_fps == FrameSpeedOption.FPS30)
            {
                fpsToolStripMenuItem30.Checked = true;
                _fpsvalue = 30;
            }
            else fpsToolStripMenuItem30.Checked = false;

            if (_fps == FrameSpeedOption.FPS50)
            {
                fpsToolStripMenuItem50.Checked = true;
                _fpsvalue = 50;
            }
            else fpsToolStripMenuItem50.Checked = false;

            if (_fps == FrameSpeedOption.FPS60)
            {
                fpsToolStripMenuItem60.Checked = true;
                _fpsvalue = 60;
            }
            else fpsToolStripMenuItem60.Checked = false;

            ddbFPS.Text = _fpsvalue + " fps";
        }
Beispiel #2
0
        private void LoadConfig()
        {
            RegistryKey key;
            key = Registry.CurrentUser.OpenSubKey(_configRegistryKey, false);
            if (key != null)
            {
                _currentPath = key.GetValue("CurrentPath", "").ToString();
                _currentBackground = key.GetValue("CurrentBackground", "").ToString();

                if ((int)key.GetValue("Rollover", 0) != 0) _rollover = true;
                if ((int)key.GetValue("DisableAlphaChannel", 0) != 0) _disableAlphaChannel = true;
                if ((int)key.GetValue("DisableTransparency", 0) != 0) _disableTransparency = true;
                if ((int)key.GetValue("DisableHelpers", 0) != 0) _disableHelpers = true;

                _backgroundStyle = (BackgroundStyle)key.GetValue("BackgroundStyle", 0);
                _fps = (FrameSpeedOption)key.GetValue("FPS",0);

                _updateHelperEventDisable = true;

                udX1.Value = (int)key.GetValue("HelperX1", 0);
                udX2.Value = (int)key.GetValue("HelperX2", 0);
                udY1.Value = (int)key.GetValue("HelperY1", 0);
                udY2.Value = (int)key.GetValue("HelperY2", 0);

                _updateHelperEventDisable = false;

                key.Close();
            }
        }