예제 #1
0
 public void ShowAcountPanel(bool e)
 {
     if (e)
     {
         AcountPanel.SetActive(true);
         AccountButton.SetActive(false);
         InfoButton.SetActive(false);
         SettingsButton.SetActive(false);
         LeaderButton.SetActive(false);
         PlayScreen.SetActive(false);
         ShopButton.SetActive(false);
         BtnAvatar.SetActive(false);
         Camera.GetComponent <CameraController>().enabled = false;
     }
     else
     {
         AcountPanel.SetActive(false);
         AccountButton.SetActive(true);
         InfoButton.SetActive(true);
         SettingsButton.SetActive(true);
         LeaderButton.SetActive(true);
         ShopButton.SetActive(true);
         BtnAvatar.SetActive(true);
         PlayScreen.SetActive(true);
         Camera.GetComponent <CameraController>().enabled = true;
     }
 }
        public void ResetProduct(string accessGroupName, string productName, DeltaChange deltaChange)
        {
            webDriver.FindElement(By.XPath("//div[@title='" + accessGroupName + "']/../..//input[@name='chkAccessGroup']")).SendKeys(Keys.Space);
            SettingsButton.SendKeys(Keys.Enter);
            webDriver.WaitForElementVisible(By.Id("ctl00_ContentPageHolder_ManageGroupsContainer_AccessGroupTab_ManageAccessGrps_uc_PublishAndUpdate_img_Update"), TimeSpan.FromMinutes(2));
            webDriver.FindElement(By.XPath("//table[@id='ctl00_ContentPageHolder_ManageGroupsContainer_AccessGroupTab_ManageAccessGrps_MyTable']//span[text()='Standard Configurations'][contains(@onclick,'return')]")).Click();

            IWebElement chkElement = ContentTable.FindElement(By.XPath("//tr[@title='" + productName + "']")).FindElement(By.XPath(".//input[contains(@id,'ctl00_ContentPageHolder_ManageGroupsContainer_AccessGroupTab_ManageAccessGrps_grpchk')]"));

            switch (deltaChange)
            {
            case DeltaChange.Add:
                if (chkElement.Selected)
                {
                    chkElement.SendKeys(Keys.Space);
                }
                break;

            case DeltaChange.Remove:
            case DeltaChange.Modify:
                if (!chkElement.Selected)
                {
                    chkElement.SendKeys(Keys.Space);
                }
                break;
            }

            AccessGroup_UpdateButton.SendKeys(Keys.Enter);
            webDriver.WaitForPageLoad(TimeSpan.FromMinutes(2));
        }
예제 #3
0
        public Menu()
        {
            InitializeComponent();
            SettingsButton.Text("Settings");
            HistoryButton.Text("History");
            BookmarksButton.Text("Bookmarks");
            DownloadsButton.Text("Downloads");
            ExtensionsButton.Text("Extensions");
            WindowButton.Text("New window");
            FullscreenButton.Text("Fullscreen");
            ScreenButton.Text("Take screenshot");
            DevButton.Text("Developer tools");
            IncognitoButton.Text("Incognito");

            SettingsButton.ImageSource("settings.png");
            HistoryButton.ImageSource("history.png");
            BookmarksButton.ImageSource("bookmarks.png");
            DownloadsButton.ImageSource("download.png");
            ExtensionsButton.ImageSource("extension.png");
            WindowButton.ImageSource(("window.png"));
            FullscreenButton.ImageSource("fullscreen.png");
            ScreenButton.ImageSource("screen.png");
            DevButton.ImageSource("dev.png");
            IncognitoButton.ImageSource("privacy.png");
        }
예제 #4
0
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            currentDelegate = NSApplication.SharedApplication.Delegate as AppDelegate;

            // Blur Overlay is the Visual Effect View with Blur and Vibrancy
            BlurOverlay.WantsLayer   = true;
            BlurOverlay.Material     = NSVisualEffectMaterial.Dark;
            BlurOverlay.BlendingMode = NSVisualEffectBlendingMode.WithinWindow;

            ThumbnailView.WantsLayer         = true;
            ThumbnailView.Layer.CornerRadius = 32.0f;

            #region Settings Menu
            settingsMenu = new NSMenu();

            artwork = new NSMenuItem("Background Artwork", new ObjCRuntime.Selector("artwork:"), "");
            launch  = new NSMenuItem("Launch at Login", new ObjCRuntime.Selector("launch:"), "");
            NSMenuItem about = new NSMenuItem("About", new ObjCRuntime.Selector("about:"), "");
            NSMenuItem quit  = new NSMenuItem("Quit Carol", new ObjCRuntime.Selector("quit:"), "q");


            settingsMenu.AddItem(artwork);
            settingsMenu.AddItem(launch);
            settingsMenu.AddItem(about);
            settingsMenu.AddItem(NSMenuItem.SeparatorItem);
            settingsMenu.AddItem(quit);
            #endregion

            SettingsButton.AddTrackingArea(new NSTrackingArea(SettingsButton.Bounds, NSTrackingAreaOptions.MouseEnteredAndExited | NSTrackingAreaOptions.ActiveAlways, this, null));
            cursor = NSCursor.CurrentSystemCursor;

            windowController = currentDelegate.Storyboard.InstantiateControllerWithIdentifier("AboutWindow") as NSWindowController;
        }
 private void InitializeMainGameMenuContainer()
 {
     mainGameMenuCanvas = GetComponentInChildren <MainGameMenuCanvas>(true);
     continueGameButton = GetComponentInChildren <ContinueGameButton>(true);
     settingsButton     = GetComponentInChildren <SettingsButton>(true);
     leaveRoomButton    = GetComponentInChildren <LeaveRoomButton>(true);
 }
        void ReleaseDesignerOutlets()
        {
            if (FlightTableView != null)
            {
                FlightTableView.Dispose();
                FlightTableView = null;
            }

            if (NavBar1 != null)
            {
                NavBar1.Dispose();
                NavBar1 = null;
            }

            if (SettingsButton != null)
            {
                SettingsButton.Dispose();
                SettingsButton = null;
            }

            if (StartRangeTextField != null)
            {
                StartRangeTextField.Dispose();
                StartRangeTextField = null;
            }
        }
예제 #7
0
        private void AnimateAddButton(bool open, Grid targetspacer, Grid addButtonGrid)
        {
            SettingsButton.BeginAnimation(OpacityProperty, open ? _opacityUp : _opacityDown);
            return;

            if (open && ((ScaleTransform)targetspacer.LayoutTransform).ScaleX == 1)
            {
                return;
            }
            if (!open && ((ScaleTransform)targetspacer.LayoutTransform).ScaleX == 0)
            {
                return;
            }
            var to = open ? 1 : 0;

            //var from = open ? 0 : 1;
            targetspacer.LayoutTransform.BeginAnimation(ScaleTransform.ScaleXProperty,
                                                        new DoubleAnimation(to, TimeSpan.FromMilliseconds(250))
            {
                EasingFunction = new QuadraticEase()
            });
            addButtonGrid.BeginAnimation(OpacityProperty,
                                         new DoubleAnimation(to, TimeSpan.FromMilliseconds(250))
            {
                EasingFunction = new QuadraticEase()
            });
        }
예제 #8
0
 private void UpMan_FileDownloadCompleted(object sender, UpdateManager.FileProgressEventArgs e)
 {
     if (e.DownloadFileName == "config.xml")
     {
         CheckMusic();
         SettingsButton.BeginInvoke(new Action(() => SettingsButton.Enabled = true));
     }
 }
예제 #9
0
 private void SetFeedbackVisibility()
 {
     if (StoreServicesFeedbackLauncher.IsSupported() && false)
     {
         FeedbackButton.Visibility = Visibility.Visible;
         SettingsButton.SetValue(Grid.ColumnSpanProperty, 1);
         SettingsButton.SetValue(Grid.ColumnProperty, 1);
     }
 }
 private void CreateButtons(List <SettingItemModel> items)
 {
     foreach (SettingItemModel model in items)
     {
         var btn = new SettingsButton();
         btn.BindingContext = model;
         StackButtons.Children.Add(btn);
     }
 }
예제 #11
0
    private void OnScreenChanged(string from, string to)
    {
        // Assign all variables
        mainUIPanel      = FindObjectOfType <MainUIPanel>().GetComponent <RectTransform>();
        mainUIPanelImage = mainUIPanel.GetComponent <Image>();
        mainUIPanelImage.raycastTarget = false;

        // add callback to main ui panel, so when we click on it it close the settingspanel
        EventTrigger.Entry entry = new EventTrigger.Entry();
        entry.eventID = EventTriggerType.PointerClick;
        entry.callback.AddListener((eventData) => {
            CloseSettingsPanel();
        });
        mainUIPanelEventTrigger = mainUIPanel.GetComponent <EventTrigger>();
        if (mainUIPanelEventTrigger == null) // We don't have an eventtrigger on it so add one
        {
            mainUIPanelEventTrigger = mainUIPanel.gameObject.AddComponent <EventTrigger>();
        }
        mainUIPanelEventTrigger.triggers.Add(entry);
        mainUIPanelEventTrigger.enabled = false;


        bool panelInstantiated = false;

        for (int i = 0; i < changePanels.Length; i++)
        {
            if (changePanels[i].screenName == to)
            {
                // We already have the one we needed to instantiated
                if (currentChangePanel == i)
                {
                    break;
                }

                InstantiateChangePanel(changePanels[i]);
                panelInstantiated = true;
                break;
            }
        }

        // If we found no screens in changePanels instantiate the very first element
        if (!panelInstantiated)   // We already have it instatiated
        {
            InstantiateChangePanel(changePanels[0]);
        }

        SettingsButton sB = FindObjectOfType <SettingsButton>();

        if (sB != null)   // We have no button -> no setup of button needed
        {
            settingsButton = sB.GetComponent <Button>();
            settingsButton.onClick.AddListener(() => {
                ToggleSettingsPanel();
            });
        }
    }
예제 #12
0
 private void OnWindowMouseLeave(object sender, MouseEventArgs e)
 {
     SettingsButton.BeginAnimation(OpacityProperty, _opacityDown);
     Task.Delay(1000).ContinueWith(t => Dispatcher.InvokeAsync(() =>
     {
         if (IsMouseOver)
         {
             return;
         }
         AbnormalityIndicatorBase.InvokeVisibilityChanged(this, false);
     }));
 }
예제 #13
0
        void ReleaseDesignerOutlets()
        {
            if (AlbumArtView != null)
            {
                AlbumArtView.Dispose();
                AlbumArtView = null;
            }

            if (BlurOverlay != null)
            {
                BlurOverlay.Dispose();
                BlurOverlay = null;
            }

            if (TrackName != null)
            {
                TrackName.Dispose();
                TrackName = null;
            }

            if (ArtistName != null)
            {
                ArtistName.Dispose();
                ArtistName = null;
            }

            if (InstrumentalTag != null)
            {
                InstrumentalTag.Dispose();
                InstrumentalTag = null;
            }

            if (PlayerIcon != null)
            {
                PlayerIcon.Dispose();
                PlayerIcon = null;
            }

            if (ThumbnailView != null)
            {
                ThumbnailView.Dispose();
                ThumbnailView = null;
            }

            if (SettingsButton != null)
            {
                SettingsButton.Dispose();
                SettingsButton = null;
            }
        }
예제 #14
0
        void ReleaseDesignerOutlets()
        {
            if (titleText != null)
            {
                titleText.Dispose();
                titleText = null;
            }

            if (SettingsButton != null)
            {
                SettingsButton.Dispose();
                SettingsButton = null;
            }
        }
예제 #15
0
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            currentDelegate = NSApplication.SharedApplication.Delegate as AppDelegate;

            LyricsTextView.BackgroundColor = NSColor.Clear;
            //Getting the font size from preferences
            LyricsTextView.Font = NSFont.SystemFontOfSize(NSUserDefaults.StandardUserDefaults.FloatForKey("TextSize"), 0.2f);

            // Blur Overlay is the Visual Effect View with Blur and Vibrancy
            BlurOverlay.WantsLayer   = true;
            BlurOverlay.Material     = NSVisualEffectMaterial.Dark;
            BlurOverlay.BlendingMode = NSVisualEffectBlendingMode.WithinWindow;

            ThumbnailView.WantsLayer         = true;
            ThumbnailView.Layer.CornerRadius = 32.0f;

            // Progress bar shows how much of lyrics have you covered. It works with scrollview
            progress = ProgressBar.Frame;

            //Adding observer of Scroll view change in Notification Center. It helps to update the width of progress bar
            MainScroll.ContentView.PostsBoundsChangedNotifications = true;
            NSNotificationCenter.DefaultCenter.AddObserver(this, new ObjCRuntime.Selector("boundsChange:"),
                                                           NSView.BoundsChangedNotification, MainScroll.ContentView);

            #region Settings Menu
            settingsMenu = new NSMenu();

            artwork = new NSMenuItem("Background Artwork", new ObjCRuntime.Selector("artwork:"), "");
            launch  = new NSMenuItem("Launch at Login", new ObjCRuntime.Selector("launch:"), "");
            NSMenuItem about = new NSMenuItem("About", new ObjCRuntime.Selector("about:"), "");
            NSMenuItem quit  = new NSMenuItem("Quit Carol", new ObjCRuntime.Selector("quit:"), "q");


            settingsMenu.AddItem(artwork);
            settingsMenu.AddItem(launch);
            settingsMenu.AddItem(about);
            settingsMenu.AddItem(NSMenuItem.SeparatorItem);
            settingsMenu.AddItem(quit);
            #endregion

            OpenInBrowserButton.AddTrackingArea(new NSTrackingArea(OpenInBrowserButton.Bounds, NSTrackingAreaOptions.MouseEnteredAndExited | NSTrackingAreaOptions.ActiveAlways, this, null));
            ChangeTextSizeButton.AddTrackingArea(new NSTrackingArea(ChangeTextSizeButton.Bounds, NSTrackingAreaOptions.MouseEnteredAndExited | NSTrackingAreaOptions.ActiveAlways, this, null));
            SettingsButton.AddTrackingArea(new NSTrackingArea(SettingsButton.Bounds, NSTrackingAreaOptions.MouseEnteredAndExited | NSTrackingAreaOptions.ActiveAlways, this, null));
            cursor = NSCursor.CurrentSystemCursor;

            windowController = currentDelegate.Storyboard.InstantiateControllerWithIdentifier("AboutWindow") as NSWindowController;
        }
        async void SignInUser()
        {
            string samp037 = "C316560C5B925874FF30D49DCAE42478";
            string samp    = "";

            try
            {
                if (Registry.GetValue(@"HKEY_CURRENT_USER\Software\DStories", "created", null) == null)
                {
                    RegistryKey key;
                    key = Registry.CurrentUser.CreateSubKey(@"Software\DStories");
                    key.SetValue("created", "1");
                    key.Close();
                }
            }
            catch (SecurityException) { Error.ShowError("Brak permisji!\nUruchom program jako Administrator!"); }
            catch (ArgumentException) { Error.ShowError("Klucz nie zaczyna się od głównego prawidłowy rejestru!"); }

            try
            {
                if (Registry.GetValue(@"HKEY_CURRENT_USER\Software\SAMP", "gta_sa_exe", null) != null)
                {
                    samp = Registry.GetValue(@"HKEY_CURRENT_USER\Software\SAMP", "gta_sa_exe", null).ToString().Replace("gta_sa.exe", "samp.exe");
                    if (await MD5Checksum.CalculateMD5Async(samp) == samp037)
                    {
                        SettingsButton.Show();
                        LowerPB.Show();
                        BiggerPB.Show();
                        PlayButton.Show();
                        PlayImage.Show();
                        DiscordButton.Show();
                        LoginDim.Hide();
                    }
                    else
                    {
                        Error.ShowError("Posiadasz złą wersję SA-MP!\n Wymagana wersja to 0.3.7!");
                        System.Diagnostics.Process.Start("https://www.sa-mp.com/download.php");
                        Environment.Exit(0);
                    }
                }
                else
                {
                    System.Diagnostics.Process.Start("https://www.sa-mp.com/download.php");
                    Environment.Exit(0);
                }
            }
            catch (SecurityException) { Error.ShowError("Brak permisji!\nUruchom program jako Administrator!"); }
            catch (ArgumentException) { Error.ShowError("Klucz nie zaczyna się od głównego prawidłowego rejestru!"); }
        }
예제 #17
0
    // Use this for initialization
    void Awake()
    {
        //setting filebrowser
        fb = new FileBrowser(0);
        fb.setLayout(0);
        fb.guiSkin           = sk;
        fb.fileTexture       = file;
        fb.directoryTexture  = folder;
        fb.backTexture       = back;
        fb.driveTexture      = drive;
        fb.showSearch        = true;
        fb.searchRecursively = true;
        playspeed            = 1.0f;
        speedtext.text       = "Play Speed: " + playspeed + "x";
        camera3D.enabled     = false;


        ////different action types
        //constructorActions = new List<Action> ();
        //constructorActions.Add (new LocationAction ());
        //constructorActions.Add (new GazeAction ());
        //constructorActions.Add (new HeadFaceAction ());
        //constructorActions.Add (new UpperBodyAction ());
        //constructorActions.Add (new LowerBodyAction ());

        ////functions
        //functions = new Dictionary<string, Color> ();
        //functions.Add ("self_focused", Color.red);
        //functions.Add ("context_focused", Color.green);
        //functions.Add ("communication_focused", Color.blue);

        loadConfigFile();
        actions               = new List <Action> ();
        activeActions         = new List <Action> ();
        timeline              = GameObject.Find("Timeline").GetComponent <Slider> ();
        durationText          = GameObject.Find("TextDuration").GetComponent <Text> ();
        currentText           = GameObject.Find("CurrentText").GetComponent <Text> ();
        control               = GameObject.Find("ButtonPlay").GetComponentInChildren <PlayButton> ();
        settings              = GameObject.Find("Button Settings").GetComponentInChildren <SettingsButton> ();
        setupAnnotation       = GameObject.Find("Button Setup").GetComponentInChildren <SetupButton> ();
        loadedFileText        = GameObject.Find("LoadedFileText").GetComponent <Text> ();
        timeline.value        = 0;
        current               = 0;
        lastActionidx         = 0;
        fileLoaded            = false;
        timeline.interactable = false;
        dragging              = false;
        saveInitialSetup();
    }
예제 #18
0
        private void HandleKeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Escape)
            {
                SettingsButton.PerformClick();
            }

            if (e.KeyCode == Keys.Left)
            {
                foreach (Control control in this.Controls)
                {
                    control.Location = new Point(control.Location.X - 1, control.Location.Y - 1);
                }
            }
        }
        async void HideBtn_Clicked(System.Object sender, System.EventArgs e)
        {
            await SettingsButton.FadeTo(0, 200, Easing.Linear);

            await HomeButton.FadeTo(0, 200, Easing.Linear);

            await ExploreButton.FadeTo(0, 200, Easing.Linear);

            await HideButton.TranslateTo(-deviceWidth - 10, 0, 1000, Easing.SpringOut);

            await ExpandButton.FadeTo(100, 500, Easing.Linear);

            HideButton.Opacity = 0;
            await HideButton.TranslateTo(0, 0, 0);
        }
        async void RevealBtn_Clicked(System.Object s, System.EventArgs e)
        {
            await ExpandButton.TranslateTo(deviceWidth + 10, 0, 1000, Easing.SpringOut);

            await Task.WhenAll(
                ExploreButton.FadeTo(100, 1000, Easing.CubicIn),
                HomeButton.FadeTo(100, 1000, Easing.CubicIn),
                SettingsButton.FadeTo(100, 1000, Easing.CubicIn)
                );

            await HideButton.FadeTo(100, 500, Easing.Linear);

            ExpandButton.Opacity = 0;
            await ExpandButton.TranslateTo(0, 0, 0);
        }
예제 #21
0
        private void load(Storage storage, OsuConfigManager config, OsuGame game)
        {
            Add(new SettingsEnumDropdown <ReleaseStream>
            {
                LabelText = Properties.strings.ReleaseStream,
                Current   = config.GetBindable <ReleaseStream>(OsuSetting.ReleaseStream),
            });

            if (updateManager?.CanCheckForUpdate == true)
            {
                Add(checkForUpdatesButton = new SettingsButton
                {
                    Text   = "Check for updates",
                    Action = () =>
                    {
                        checkForUpdatesButton.Enabled.Value = false;
                        Task.Run(updateManager.CheckForUpdateAsync).ContinueWith(t => Schedule(() =>
                        {
                            if (!t.Result)
                            {
                                notifications?.Post(new SimpleNotification
                                {
                                    Text = $"You are running the latest release ({game.Version})",
                                    Icon = FontAwesome.Solid.CheckCircle,
                                });
                            }

                            checkForUpdatesButton.Enabled.Value = true;
                        }));
                    }
                });
            }

            if (RuntimeInfo.IsDesktop)
            {
                Add(new SettingsButton
                {
                    Text   = Properties.strings.OpenFolder,
                    Action = storage.OpenInNativeExplorer,
                });

                Add(new SettingsButton
                {
                    Text   = Properties.strings.ChangeFolder,
                    Action = () => game?.PerformFromScreen(menu => menu.Push(new MigrationSelectScreen()))
                });
            }
        }
예제 #22
0
            /// <summary>
            /// Instantiates the relevant keys based on the version and button prefab. Forces a layout rebuild.
            /// </summary>
            private void instantiateKeys()
            {
                settingsButtons.Clear();
                foreach (string key in keyList)
                {
                    // Instantiates new button
                    // Handles reloading current config (in Start of buttons)
                    GameObject newButton = Instantiate(buttonPrefab) as GameObject;
                    newButton.transform.SetParent(gameObject.transform, false);
                    ConfigButton   CB = newButton.GetComponent <ConfigButton>();
                    SettingsButton SB = newButton.GetComponent <SettingsButton>();
                    TestButton     TB = newButton.GetComponent <TestButton>();
                    if (key == "")
                    {
                        CB.setInactive();
                    }
                    else
                    {
                        if (SB)
                        {
                            Debug.Log("loading settings buttons");
                            if (FitBoardSave.hasConfig)
                            {
                                Debug.Log("Houston, we have a config");
                                int toggle = ConfigUtils.getConfigToggle(key);
                                SB.setButton(key, ConfigUtils.getToggleColor(toggle), true, toggle);
                                settingsButtons.Add(SB);
                            }
                            else
                            {
                                Debug.Log("loading default config");
                                SB.setButton(key, Color.grey, true);
                                settingsButtons.Add(SB);
                            }
                        }
                        else if (TB)
                        {
                            TB.setButton(key, Color.grey, true);
                        }
                        else
                        {
                            Debug.LogError("Uh oh! This button prefab: " + buttonPrefab + "doesn't have a config or test script");
                        }
                    }
                }

                LayoutRebuilder.ForceRebuildLayoutImmediate(layout);
            }
예제 #23
0
        /// <summary>
        /// The set active page.
        /// </summary>
        /// <param name="page">
        /// The page.
        /// </param>
        private void SetActivePage(SettingsButton page)
        {
            WrapPanel wrapPanel = page.Parent as WrapPanel;

            if (wrapPanel != null)
            {
                if (!page.IsSelected || page.SettingsPage == null)
                {
                    return;
                }

                foreach (UIElement tab in wrapPanel.Children)
                {
                    if (tab is SettingsButton && !tab.Equals(page))
                    {
                        (tab as SettingsButton).IsSelected = false;
                    }
                }
            }

            UIElement       lastPage = this.CcOptions.Content as UIElement;
            DoubleAnimation hideLastPageAnimation = new DoubleAnimation(1, 0, new Duration(TimeSpan.FromSeconds(0.10)));

            if (lastPage != null)
            {
                lastPage.BeginAnimation(OpacityProperty, hideLastPageAnimation);
            }

            new Thread(
                delegate()
            {
                Thread.Sleep(200);
                this.Dispatcher.Invoke(
                    (App.SimpleVoidDelegate) delegate
                {
                    DoubleAnimation showPageAnimation = new DoubleAnimation(
                        0,
                        1,
                        new Duration(TimeSpan.FromSeconds(0.10)));
                    page.SettingsPage.BeginAnimation(OpacityProperty, showPageAnimation);
                    this.CcOptions.Content = page.SettingsPage;
                },
                    new object[] { });
            })
            {
                IsBackground = true
            }.Start();
        }
예제 #24
0
        public void Update(GameTime gameTime)
        {
            background.Update(gameTime);
            HelpButton.Update(gameTime);
            ExitButton.Update(gameTime);
            SettingsButton.Update(gameTime);

            if (GameScreenManager.Instance.ClientID != -1)
            {
                User usr = RetroEnvironment.GetGame().GetClientManager().GetClientByUserID(GameScreenManager.Instance.ClientID).GetUser();
                if (usr != null)
                {
                    txtDiamond.SetText(usr.GetDiamonds());
                    txtCredit.SetText(usr.GetCredits());
                    txtDucket.SetText(usr.GetDuckets());
                }
            }
        }
        public Client()
        {
            Debug.WriteLine(installing_path);
            InitializeComponent();
            CenterToScreen();
            MaximizeBox              = false;
            PanelOpacity.BackColor   = Color.FromArgb(125, Color.Black);
            SettingsButton.BackColor = Color.FromArgb(25, Color.Gray);
            LoginDim.BackColor       = Color.FromArgb(125, Color.Black);

            SettingsButton.Hide();
            LowerPB.Hide();
            BiggerPB.Hide();
            PlayButton.Hide();
            PlayImage.Hide();
            StatusBar.Hide();
            DiscordButton.Hide();
        }
예제 #26
0
        void ReleaseDesignerOutlets()
        {
            if (SettingsButton != null)
            {
                SettingsButton.Dispose();
                SettingsButton = null;
            }

            if (StartNewGameButton != null)
            {
                StartNewGameButton.Dispose();
                StartNewGameButton = null;
            }

            if (VersionLabel != null)
            {
                VersionLabel.Dispose();
                VersionLabel = null;
            }
        }
예제 #27
0
        public void Start()
        {
            DontDestroyOnLoad(this);

            button = new SettingsButton()
            {
                Text     = "Keys",
                Value    = false,
                OnToggle = OnInterfaceToggle
            };
            button.Create();

            windowRect.x      = Configuration.GetFloat("main-x", 1100f);
            windowRect.y      = Configuration.GetFloat("main-y", 309);
            windowRect.width  = 400;
            windowRect.height = 500;
            editInterface.LoadWindowPosition();

            toggleKey = Keybindings.AddKeybinding("Key Manager",
                                                  new Key(KeyCode.RightControl, KeyCode.M));
        }
예제 #28
0
        public OverworldHUD(GDOverworldScreen scrn, bool firstShow) : base(scrn, Textures.HUDFontRegular)
        {
            AddElement(Settings = new SettingsButton());

            ScoreDispMan = new ScoreDisplayManager(this, firstShow);

#if FALSE
            AddElement(new HUDLabel
            {
                Alignment        = HUDAlignment.CENTER,
                RelativePosition = new FPoint(0, -200),

                AutoSize = true,

                Background = HUDBackgroundDefinition.CreateSimple(Color.LightBlue),
                TextColor  = Color.Red,

                FontSize = 64,
                Text     = "INTERNAL ALPHA VERSION 4",
            });
#endif
        }
예제 #29
0
        /////////////////////////////////////////////////////////////////////////////
        // Overridden Package Implementation
        #region Package Members

        /// <summary>
        /// Initialization of the package; this method is called right after the package is sited, so this is the place
        /// where you can put all the initialization code that rely on services provided by VisualStudio.
        /// </summary>
        protected override void Initialize()
        {
            Instance = this;
            Debug.WriteLine(string.Format(CultureInfo.CurrentCulture, "Entering Initialize() of: {0}", this.ToString()));
            base.Initialize();

            m_writer = OutputWriter.Instance;

            var teamPage = (TeamSettingsPage)PublicGetDialogPage(typeof(TeamSettingsPage));
            var extPage  = (ExtensionSettingsPage)PublicGetDialogPage(typeof(ExtensionSettingsPage));
            var depPage  = (DependencySettingsPage)PublicGetDialogPage(typeof(DependencySettingsPage));

            SettingsProvider.SetSettingsPages(teamPage, extPage, depPage);


            m_deployButton = new DeployDebugButton(this, (int)PkgCmdIDList.cmdidDeployCode, false);
            m_debugButton  = new DeployDebugButton(this, (int)PkgCmdIDList.cmdidDebugCode, true);

            m_killButton = new KillButton(this);


            string monoFolder = WPILibFolderStructure.CreateMonoFolder();

            string monoFile = monoFolder + Path.DirectorySeparatorChar + DeployProperties.MonoVersion;

            m_monoFile = new MonoFile(monoFile);

            m_installMonoButton  = new InstallMonoButton(this, m_monoFile);
            m_downloadMonoButton = new DownloadMonoButton(this, m_monoFile, m_installMonoButton);
            m_saveMonoButton     = new SaveMonoButton(this, m_monoFile);


            m_aboutButton      = new AboutButton(this);
            m_netConsoleButton = new NetConsoleButton(this);
            m_settingsButton   = new SettingsButton(this);

            m_setMainRobotButton = new SetMainRobotButton(this);
        }
        private void load(Storage storage, OsuConfigManager config, OsuGame game)
        {
            Add(new SettingsEnumDropdown <ReleaseStream>
            {
                LabelText = "Release stream",
                Bindable  = config.GetBindable <ReleaseStream>(OsuSetting.ReleaseStream),
            });

            if (updateManager?.CanCheckForUpdate == true)
            {
                Add(checkForUpdatesButton = new SettingsButton
                {
                    Text   = "Check for updates",
                    Action = () =>
                    {
                        checkForUpdatesButton.Enabled.Value = false;
                        Task.Run(updateManager.CheckForUpdateAsync).ContinueWith(t => Schedule(() => checkForUpdatesButton.Enabled.Value = true));
                    }
                });
            }

            if (RuntimeInfo.IsDesktop)
            {
                Add(new SettingsButton
                {
                    Text   = "Open osu! folder",
                    Action = storage.OpenInNativeExplorer,
                });

                Add(new SettingsButton
                {
                    Text   = "Change folder location...",
                    Action = () => game?.PerformFromScreen(menu => menu.Push(new MigrationSelectScreen()))
                });
            }
        }