Skip to content

Commit

Permalink
Folder path fix
Browse files Browse the repository at this point in the history
  • Loading branch information
seerge committed Mar 8, 2024
1 parent 1b098cd commit a49ac10
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions app/Display/VisualControl.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
using GHelper.Helpers;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Management;
using System.Text;
using System.Threading.Tasks;

namespace GHelper.Display
{
Expand Down Expand Up @@ -43,21 +38,26 @@ public static class VisualControl
private static System.Timers.Timer brightnessTimer = new System.Timers.Timer(100);


static VisualControl ()
static VisualControl()
{
brightnessTimer.Elapsed += BrightnessTimerTimer_Elapsed;
}

private static string GetGameVisualPath()
{
return "C:\\ProgramData\\ASUS\\GameVisual";
return Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData) + "\\ASUS\\GameVisual";
}

public static Dictionary<SplendidGamut, string> GetGamutModes()
{
Dictionary<SplendidGamut, string> _modes = new Dictionary<SplendidGamut, string>();

if (!Directory.Exists(GetGameVisualPath())) return _modes;
string gameVisualPath = GetGameVisualPath();
if (!Directory.Exists(gameVisualPath))
{
Logger.WriteLine(gameVisualPath + "doesn't exit");
return _modes;
}

try
{
Expand Down

0 comments on commit a49ac10

Please sign in to comment.