コード例 #1
0
        public override void OnApplicationStarted()
        {
            // Add code to be executed when Playnite is initialized.

            if (settings.EnableIntegrationButtonHeader)
            {
                logger.Info("SuccessStory - Add Header button");
                Button btHeader = new SuccessStoryButtonHeader(TransformIcon.Get("SuccessStory"));
                btHeader.SetValue(TextBlock.FontWeightProperty, FontWeights.Bold);
                btHeader.Click += OnBtHeaderClick;
                ui.AddButtonInWindowsHeader(btHeader);
            }
        }
コード例 #2
0
 public void AddBtHeader()
 {
     if (_PlayniteApi.ApplicationInfo.Mode == ApplicationMode.Desktop)
     {
         if (PluginDatabase.PluginSettings.EnableIntegrationButtonHeader)
         {
             logger.Info("SuccessStory - Add Header button");
             Button btHeader = new SuccessStoryButtonHeader(TransformIcon.Get("SuccessStory"));
             btHeader.SetValue(TextBlock.FontWeightProperty, FontWeights.Bold);
             btHeader.Click += OnBtHeaderClick;
             ui.AddButtonInWindowsHeader(btHeader);
         }
     }
 }