示例#1
0
        public WelcomePage()
        {
            AvaloniaXamlLoader.Load(this);

            _darkMode = this.FindControl <SwitchDetailListItem>("DarkMode");
            _locale   = this.FindControl <Border>("Locales");
        }
        public TouchpadGesturePage()
        {
            AvaloniaXamlLoader.Load(this);
            Single = this.FindControl <SwitchDetailListItem>("SingleTouch");
            Double = this.FindControl <SwitchDetailListItem>("DoubleTouch");
            Triple = this.FindControl <SwitchDetailListItem>("TripleTouch");
            Hold   = this.FindControl <SwitchDetailListItem>("HoldTouch");

            SPPMessageHandler.Instance.ExtendedStatusUpdate += InstanceOnExtendedStatusUpdate;
        }
示例#3
0
        public AdvancedPage()
        {
            AvaloniaXamlLoader.Load(this);
            _seamlessConnection = this.FindControl <SwitchDetailListItem>("SeamlessConnection");
            _resumeSensor       = this.FindControl <SwitchDetailListItem>("ResumeSensor");
            _sidetone           = this.FindControl <SwitchDetailListItem>("Sidetone");
            _passthrough        = this.FindControl <SwitchDetailListItem>("Passthrough");

            SPPMessageHandler.Instance.ExtendedStatusUpdate += InstanceOnExtendedStatusUpdate;
        }
示例#4
0
        public PopupSettingsPage()
        {
            AvaloniaXamlLoader.Load(this);
            _popupToggle   = this.FindControl <SwitchDetailListItem>("PopupToggle");
            _compactToggle = this.FindControl <SwitchDetailListItem>("CompactPopup");
            _overrideTitle = this.FindControl <DetailListItem>("OverrideTitle");
            _placement     = this.FindControl <MenuDetailListItem>("PositionPopup");

            Loc.LanguageUpdated += UpdateMenuDescriptions;
            Loc.LanguageUpdated += UpdateMenus;
        }
示例#5
0
        public SettingsPage()
        {
            AvaloniaXamlLoader.Load(this);
            _darkMode         = this.FindControl <SwitchDetailListItem>("DarkModeSelect");
            _locale           = this.FindControl <MenuDetailListItem>("LocaleSelect");
            _minimizeTray     = this.FindControl <SwitchDetailListItem>("MinimizeTrayToggle");
            _autostart        = this.FindControl <SwitchDetailListItem>("AutostartToggle");
            _trayOptionBorder = this.FindControl <Border>("TrayOptionBorder");

            _trayOptionBorder.IsVisible = PlatformUtils.SupportsTrayIcon;
        }
示例#6
0
        public BixbyRemapPage()
        {
            AvaloniaXamlLoader.Load(this);
            _bixbyToggle = this.FindControl <SwitchDetailListItem>("BixbyToggle");
            _bixbyLang   = this.FindControl <MenuDetailListItem>("BixbyLanguage");
            _bixbyAction = this.FindControl <MenuDetailListItem>("BixbyRemapAction");

            SPPMessageHandler.Instance.ExtendedStatusUpdate += OnExtendedStatusUpdate;
            Loc.LanguageUpdated += UpdateMenu;

            UpdateMenu();
        }
示例#7
0
        public TouchpadPage()
        {
            AvaloniaXamlLoader.Load(this);
            _lock        = this.FindControl <SwitchListItem>("LockToggle");
            _edgeTouch   = this.FindControl <SwitchDetailListItem>("DoubleTapVolume");
            _leftOption  = this.FindControl <MenuDetailListItem>("LeftOption");
            _rightOption = this.FindControl <MenuDetailListItem>("RightOption");

            SPPMessageHandler.Instance.ExtendedStatusUpdate += InstanceOnExtendedStatusUpdate;
            EventDispatcher.Instance.EventReceived          += OnEventReceived;

            Loc.LanguageUpdated += UpdateTouchActionMenus;
            Loc.LanguageUpdated += UpdateMenuDescriptions;
            UpdateTouchActionMenus();
        }
示例#8
0
        public AmbientSoundPage()
        {
            AvaloniaXamlLoader.Load(this);
            _ambientSwitch    = this.FindControl <SwitchListItem>("AmbientToggle");
            _voiceFocusSwitch = this.FindControl <SwitchListItem>("AmbientVoiceFocusToggle");
            _volumeSlider     = this.FindControl <SliderListItem>("AmbientVolume");
            _extraLoud        = this.FindControl <SwitchDetailListItem>("AmbientExtraLoud");

            _voiceFocusBorder = this.FindControl <Border>("AmbientVoiceFocusBorder");
            _extraLoudBorder  = this.FindControl <Border>("AmbientExtraLoudBorder");

            SPPMessageHandler.Instance.AmbientEnabledUpdateResponse += (sender, b) => _ambientSwitch.IsChecked = b;
            SPPMessageHandler.Instance.ExtendedStatusUpdate         += OnExtendedStatusUpdate;

            EventDispatcher.Instance.EventReceived += OnEventReceived;

            Loc.LanguageUpdated += UpdateStrings;
            UpdateStrings();
        }
        public NoiseProPage()
        {
            AvaloniaXamlLoader.Load(this);
            _ambientSwitch = this.FindControl <SwitchListItem>("AmbientToggle");

            _ancSwitch = this.FindControl <SwitchListItem>("AncToggle");
            _ancLevel  = this.FindControl <SwitchDetailListItem>("AncLevelToggle");

            _voiceDetect        = this.FindControl <SwitchDetailListItem>("VoiceDetect");
            _voiceDetectTimeout = this.FindControl <MenuDetailListItem>("VoiceDetectTimeout");
            _voiceBorder        = this.FindControl <Border>("VoiceDetectBorder");

            SPPMessageHandler.Instance.NoiseControlUpdateResponse += (sender, mode) => SetNoiseControlState(mode);
            SPPMessageHandler.Instance.ExtendedStatusUpdate       += OnExtendedStatusUpdate;

            EventDispatcher.Instance.EventReceived += OnEventReceived;
            Loc.LanguageUpdated += UpdateVoiceDetectTimeout;

            UpdateVoiceDetectTimeout();
        }
 public CrowdsourcingSettingsPage()
 {
     AvaloniaXamlLoader.Load(this);
     _crowdToggle = this.FindControl <SwitchDetailListItem>("CrowdsourcingToggle");
     _crashToggle = this.FindControl <SwitchDetailListItem>("CrashToggle");
 }