Skip to content

Commit

Permalink
Replaced a hardcoded path, which was a development remnant
Browse files Browse the repository at this point in the history
  • Loading branch information
sgrottel committed Jun 16, 2024
1 parent 9e3f90b commit 979ffcf
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion Dib/DIBForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
using System.Xml.Serialization;
using System.Xml;
using System.Runtime.Versioning;
using System.Reflection;

namespace Dib {

Expand Down Expand Up @@ -417,7 +418,13 @@ public class IconCollection : List<MyIconInfo> { };
/// </summary>
public DIBForm() {
InitializeComponent();
Icon = Icon.ExtractAssociatedIcon(@"C:\dev\tiny-tools\Dib\bin\Debug\net8.0-windows7.0\Dib.exe");
try
{
Icon = Icon.ExtractAssociatedIcon(Assembly.GetExecutingAssembly().Location);
}
catch
{
}
try {
this.filename = Microsoft.Win32.Registry.GetValue(
filenameRegKeyPath, filenameRegKeyName, string.Empty)
Expand Down

0 comments on commit 979ffcf

Please sign in to comment.