Beispiel #1
0
        public override void Update()
        {
            base.Update();

            Back.Update();
            if (Back.Press())
            {
                Options.SaveOptions();
                SceneManager.ChangeScene(SceneManager.menuScene);
            }

            Controls.Update();
            if (Controls.Press())
            {
                SceneManager.ChangeScene(SceneManager.controlScene);
            }

            TutorialTips.Update();
            if (TutorialTips.Press())
            {
                TipsEnable               = !TipsEnable;
                TutorialTips.Write       = "Tips: " + TipsEnable.ToString();
                TutorialTips.NormalColor = TipsEnable ? Color.Green : Color.Red;
            }

            StarChanceSlider.Update();
            SoundVolumeSlider.Update();
            MusicVolumeSlider.Update();
        }
Beispiel #2
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            base.Draw(spriteBatch);

            Back.Draw(spriteBatch);
            Controls.Draw(spriteBatch);
            TutorialTips.Draw(spriteBatch);

            StarChanceSlider.Draw(spriteBatch);
            SoundVolumeSlider.Draw(spriteBatch);
            MusicVolumeSlider.Draw(spriteBatch);
        }
        public void ShowTutorialTip(TutorialTips tip)
        {
            string message = null;
            List <NotifyActionItem> items = new List <NotifyActionItem>();

            switch (tip)
            {
            case TutorialTips.DatabasesScreen:
                message = "This is a database management screen.";
                items.Add(new NotifyActionItem()
                {
                    Title  = "Learn more...",
                    Action = () =>
                    {
                        Platform.OpenLink("http://google.com");
                    }
                });
                break;

            case TutorialTips.WorkspacesScreen:
                break;

            case TutorialTips.GraphsScreen:
                break;

            default:
                throw new ArgumentOutOfRangeException("tip", tip, null);
            }

            items.Add(new NotifyActionItem()
            {
                Title  = "Disable Tips",
                Action = () =>
                {
                    ShowTutorialTips = false;
                }
            });

            Signal <INotify>(_ => _.NotifyWithActions(message, NotificationIcon.Info, items.ToArray()));
        }
        public void ShowTutorialTip(TutorialTips tip)
        {
            string message = null;
            List<NotifyActionItem> items = new List<NotifyActionItem>();

            switch (tip)
            {
                case TutorialTips.DatabasesScreen:
                    message = "This is a database management screen.";
                    items.Add(new NotifyActionItem()
                    {
                        Title = "Learn more...",
                        Action = () =>
                        {
                            Platform.OpenLink("http://google.com");
                        }
                    });
                    break;
                case TutorialTips.WorkspacesScreen:
                    break;
                case TutorialTips.GraphsScreen:
                    break;
                default:
                    throw new ArgumentOutOfRangeException("tip", tip, null);
            }

            items.Add(new NotifyActionItem()
            {
                Title = "Disable Tips",
                Action = () =>
                {
                    ShowTutorialTips = false;
                }
            });

            Signal<INotify>(_ => _.NotifyWithActions(message, NotificationIcon.Info, items.ToArray()));
        }