Skip to content

Commit

Permalink
✨ Windows taskbar icon workaround.
Browse files Browse the repository at this point in the history
  • Loading branch information
exislow committed Jan 19, 2024
1 parent d39bcc9 commit 1e4d89a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tidal_dl_ng/gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -484,6 +484,17 @@ def gui_activate(tidal: Tidal | None = None):
icon: QtGui.QIcon = QtGui.QIcon(pixmap)
app.setWindowIcon(icon)

# This bit gets the taskbar icon working properly in Windows
if sys.platform.startswith("win"):
import ctypes

# Make sure Pyinstaller icons are still grouped
if not sys.argv[0].endswith(".exe"):
# Arbitrary string
ctypes.windll.shell32.SetCurrentProcessExplicitAppUserModelID(
"CompanyName.ProductName.SubProduct.VersionInformation"
)

window = MainWindow(tidal=tidal)
window.show()

Expand Down

0 comments on commit 1e4d89a

Please sign in to comment.