mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-03-24 18:28:49 +00:00
Fixed effects not realising they are active in the UI
This commit is contained in:
parent
821726d376
commit
3256666f79
@ -97,9 +97,13 @@ namespace Artemis.Settings
|
|||||||
else
|
else
|
||||||
mgr.RemoveShortcutsForExecutable("Artemis.exe", ShortcutLocation.Startup);
|
mgr.RemoveShortcutsForExecutable("Artemis.exe", ShortcutLocation.Startup);
|
||||||
}
|
}
|
||||||
|
catch (FileNotFoundException)
|
||||||
|
{
|
||||||
|
// Ignored, only happens when running from VS
|
||||||
|
}
|
||||||
catch (DirectoryNotFoundException)
|
catch (DirectoryNotFoundException)
|
||||||
{
|
{
|
||||||
// ignored, this'll only occur if Artemis isn't installed (ran from VS)
|
// Ignored, only happens when running from VS
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -24,19 +24,22 @@ namespace Artemis.Utilities
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public static async void UpdateApp()
|
public static async void UpdateApp()
|
||||||
{
|
{
|
||||||
|
var settings = SettingsProvider.Load<GeneralSettings>();
|
||||||
|
Logger.Info("Update check enabled: {0}", settings.AutoUpdate);
|
||||||
|
|
||||||
// Only update if the user allows it
|
// Only update if the user allows it
|
||||||
if (SettingsProvider.Load<GeneralSettings>().AutoUpdate)
|
if (!SettingsProvider.Load<GeneralSettings>().AutoUpdate)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
Logger.Info("Checking for updates...");
|
|
||||||
// Pre-release
|
// Pre-release
|
||||||
using (var mgr = UpdateManager.GitHubUpdateManager("https://github.com/SpoinkyNL/Artemis", null, null, null, true))
|
// using (var mgr = UpdateManager.GitHubUpdateManager("https://github.com/SpoinkyNL/Artemis", null, null, null, true))
|
||||||
// Release
|
// Release
|
||||||
// using (var mgr = UpdateManager.GitHubUpdateManager("https://github.com/SpoinkyNL/Artemis"))
|
using (var mgr = UpdateManager.GitHubUpdateManager("https://github.com/SpoinkyNL/Artemis"))
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await mgr.Result.UpdateApp();
|
await mgr.Result.UpdateApp();
|
||||||
|
Logger.Info("Update check complete");
|
||||||
mgr.Result.Dispose();
|
mgr.Result.Dispose();
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
|
|||||||
@ -24,6 +24,7 @@ namespace Artemis.ViewModels.Abstract
|
|||||||
EffectSettings = effectModel.Settings;
|
EffectSettings = effectModel.Settings;
|
||||||
|
|
||||||
MainManager.OnEnabledChangedEvent += MainManagerOnOnEnabledChangedEvent;
|
MainManager.OnEnabledChangedEvent += MainManagerOnOnEnabledChangedEvent;
|
||||||
|
MainManager.EffectManager.OnEffectChangedEvent += EffectManagerOnOnEffectChangedEvent;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void MainManagerOnOnEnabledChangedEvent(object sender, EnabledChangedEventArgs e)
|
private void MainManagerOnOnEnabledChangedEvent(object sender, EnabledChangedEventArgs e)
|
||||||
@ -31,6 +32,11 @@ namespace Artemis.ViewModels.Abstract
|
|||||||
NotifyOfPropertyChange(() => EffectEnabled);
|
NotifyOfPropertyChange(() => EffectEnabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void EffectManagerOnOnEffectChangedEvent(object sender, EffectChangedEventArgs e)
|
||||||
|
{
|
||||||
|
NotifyOfPropertyChange(() => EffectEnabled);
|
||||||
|
}
|
||||||
|
|
||||||
[Inject]
|
[Inject]
|
||||||
public MetroDialogService DialogService { get; set; }
|
public MetroDialogService DialogService { get; set; }
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user