update infowindow, bump license year
This commit is contained in:
parent
ebcb8c0a75
commit
1b8e59cf14
7 changed files with 70 additions and 22 deletions
|
@ -16,6 +16,8 @@
|
||||||
<Deterministic>true</Deterministic>
|
<Deterministic>true</Deterministic>
|
||||||
<NuGetPackageImportStamp>
|
<NuGetPackageImportStamp>
|
||||||
</NuGetPackageImportStamp>
|
</NuGetPackageImportStamp>
|
||||||
|
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||||
|
<TargetFrameworkProfile />
|
||||||
<PublishUrl>publish\</PublishUrl>
|
<PublishUrl>publish\</PublishUrl>
|
||||||
<Install>true</Install>
|
<Install>true</Install>
|
||||||
<InstallFrom>Disk</InstallFrom>
|
<InstallFrom>Disk</InstallFrom>
|
||||||
|
@ -28,10 +30,8 @@
|
||||||
<MapFileExtensions>true</MapFileExtensions>
|
<MapFileExtensions>true</MapFileExtensions>
|
||||||
<ApplicationRevision>0</ApplicationRevision>
|
<ApplicationRevision>0</ApplicationRevision>
|
||||||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
||||||
<IsWebBootstrapper>false</IsWebBootstrapper>
|
|
||||||
<UseApplicationTrust>false</UseApplicationTrust>
|
<UseApplicationTrust>false</UseApplicationTrust>
|
||||||
<BootstrapperEnabled>true</BootstrapperEnabled>
|
<BootstrapperEnabled>true</BootstrapperEnabled>
|
||||||
<TargetFrameworkProfile />
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
|
|
@ -11,5 +11,6 @@ namespace EnvyUpdate
|
||||||
public static readonly string startmenu = Environment.GetFolderPath(Environment.SpecialFolder.StartMenu);
|
public static readonly string startmenu = Environment.GetFolderPath(Environment.SpecialFolder.StartMenu);
|
||||||
public static readonly string appdata = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\envyupdate\\";
|
public static readonly string appdata = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\envyupdate\\";
|
||||||
public static readonly string startup = Environment.GetFolderPath(Environment.SpecialFolder.Startup);
|
public static readonly string startup = Environment.GetFolderPath(Environment.SpecialFolder.Startup);
|
||||||
|
public static bool monitoringInstall = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -19,6 +19,8 @@ namespace EnvyUpdate
|
||||||
string version = fvi.FileVersion;
|
string version = fvi.FileVersion;
|
||||||
|
|
||||||
labelVer.Content += " " + version;
|
labelVer.Content += " " + version;
|
||||||
|
if (GlobalVars.monitoringInstall)
|
||||||
|
labelVer.FontStyle = FontStyles.Italic;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ButtonWeb_Click(object sender, RoutedEventArgs e)
|
private void ButtonWeb_Click(object sender, RoutedEventArgs e)
|
||||||
|
|
|
@ -3,8 +3,8 @@ using System;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Management;
|
||||||
using System.Net;
|
using System.Net;
|
||||||
using System.Security.Cryptography;
|
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
using System.Windows.Media;
|
using System.Windows.Media;
|
||||||
|
@ -50,15 +50,10 @@ namespace EnvyUpdate
|
||||||
|
|
||||||
GlobalVars.isMobile = Util.IsMobile();
|
GlobalVars.isMobile = Util.IsMobile();
|
||||||
|
|
||||||
string locDriv = Util.GetLocDriv();
|
localDriv = Util.GetLocDriv();
|
||||||
if (locDriv != null)
|
if (localDriv != null)
|
||||||
{
|
{
|
||||||
localDriv = locDriv;
|
UpdateLocalVer(false);
|
||||||
textblockGPU.Text = locDriv;
|
|
||||||
if (GlobalVars.isMobile)
|
|
||||||
textblockGPUName.Text = Util.GetGPUName(false) + " (mobile)";
|
|
||||||
else
|
|
||||||
textblockGPUName.Text = Util.GetGPUName(false);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -99,6 +94,28 @@ namespace EnvyUpdate
|
||||||
// Check for new updates every 5 hours.
|
// Check for new updates every 5 hours.
|
||||||
Dt.Interval = new TimeSpan(5, 0, 0);
|
Dt.Interval = new TimeSpan(5, 0, 0);
|
||||||
Dt.Start();
|
Dt.Start();
|
||||||
|
|
||||||
|
string watchDirPath = Path.Combine(Environment.ExpandEnvironmentVariables("%ProgramW6432%"), "NVIDIA Corporation\\Installer2\\InstallerCore");
|
||||||
|
if (Directory.Exists(watchDirPath))
|
||||||
|
{
|
||||||
|
GlobalVars.monitoringInstall = true;
|
||||||
|
|
||||||
|
var driverFileChangedWatcher = new FileSystemWatcher(watchDirPath);
|
||||||
|
driverFileChangedWatcher.NotifyFilter = NotifyFilters.Attributes
|
||||||
|
| NotifyFilters.CreationTime
|
||||||
|
| NotifyFilters.FileName
|
||||||
|
| NotifyFilters.LastAccess
|
||||||
|
| NotifyFilters.LastWrite
|
||||||
|
| NotifyFilters.Size;
|
||||||
|
driverFileChangedWatcher.Changed += DriverFileChanged;
|
||||||
|
driverFileChangedWatcher.Created += DriverFileChanged;
|
||||||
|
driverFileChangedWatcher.Deleted += DriverFileChanged;
|
||||||
|
|
||||||
|
driverFileChangedWatcher.Filter = "*.dll";
|
||||||
|
driverFileChangedWatcher.IncludeSubdirectories = false;
|
||||||
|
driverFileChangedWatcher.EnableRaisingEvents = true;
|
||||||
|
}
|
||||||
|
|
||||||
Load();
|
Load();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -113,7 +130,7 @@ namespace EnvyUpdate
|
||||||
infoWin.ShowDialog();
|
infoWin.ShowDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
private async void Load()
|
private void Load()
|
||||||
{
|
{
|
||||||
if (Util.GetDTID() == 18)
|
if (Util.GetDTID() == 18)
|
||||||
radioSD.IsChecked = true;
|
radioSD.IsChecked = true;
|
||||||
|
@ -288,5 +305,29 @@ namespace EnvyUpdate
|
||||||
buttonSkip.Content = Properties.Resources.ui_skipped;
|
buttonSkip.Content = Properties.Resources.ui_skipped;
|
||||||
MessageBox.Show(Properties.Resources.skip_confirm);
|
MessageBox.Show(Properties.Resources.skip_confirm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void UpdateLocalVer(bool reloadLocalDriv = true)
|
||||||
|
{
|
||||||
|
if (reloadLocalDriv)
|
||||||
|
localDriv = Util.GetLocDriv();
|
||||||
|
textblockGPU.Text = localDriv;
|
||||||
|
if (GlobalVars.isMobile)
|
||||||
|
textblockGPUName.Text = Util.GetGPUName(false) + " (mobile)";
|
||||||
|
else
|
||||||
|
textblockGPUName.Text = Util.GetGPUName(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
void DriverFileChanged(object sender, FileSystemEventArgs e)
|
||||||
|
{
|
||||||
|
/*
|
||||||
|
string processName = e.NewEvent.Properties["ProcessName"].Value.ToString();
|
||||||
|
string processID = Convert.ToInt32(e.NewEvent.Properties["ProcessID"].Value).ToString();
|
||||||
|
|
||||||
|
Console.WriteLine("Process stopped. Name: " + processName + " | ID: " + processID);
|
||||||
|
*/
|
||||||
|
|
||||||
|
UpdateLocalVer();
|
||||||
|
Load();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -6,11 +6,11 @@ using System.Windows;
|
||||||
// set of attributes. Change these attribute values to modify the information
|
// set of attributes. Change these attribute values to modify the information
|
||||||
// associated with an assembly.
|
// associated with an assembly.
|
||||||
[assembly: AssemblyTitle("EnvyUpdate")]
|
[assembly: AssemblyTitle("EnvyUpdate")]
|
||||||
[assembly: AssemblyDescription("")]
|
[assembly: AssemblyDescription("Small update checker application for Nvidia GPUs")]
|
||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
[assembly: AssemblyCompany("")]
|
[assembly: AssemblyCompany("fyr77")]
|
||||||
[assembly: AssemblyProduct("EnvyUpdate")]
|
[assembly: AssemblyProduct("EnvyUpdate")]
|
||||||
[assembly: AssemblyCopyright("Copyright © 2021")]
|
[assembly: AssemblyCopyright("Copyright © 2023")]
|
||||||
[assembly: AssemblyTrademark("")]
|
[assembly: AssemblyTrademark("")]
|
||||||
[assembly: AssemblyCulture("")]
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
|
@ -49,5 +49,5 @@ using System.Windows;
|
||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
[assembly: AssemblyVersion("2.13")]
|
[assembly: AssemblyVersion("2.16")]
|
||||||
[assembly: AssemblyFileVersion("2.13")]
|
[assembly: AssemblyFileVersion("2.16")]
|
||||||
|
|
2
LICENSE
2
LICENSE
|
@ -1,6 +1,6 @@
|
||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2019-2022 Jakob Senkl
|
Copyright (c) 2019-2023 Jakob Senkl
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
|
Reference in a new issue