Use platformdirs for finding the desktop path

This commit is contained in:
Deniz Şafak
2025-04-30 16:29:47 +03:00
parent 68dbdf123d
commit 04e16722e2
4 changed files with 7 additions and 3 deletions
+2 -1
View File
@@ -72,6 +72,7 @@ from constants import (
)
from threading import Thread
from voice_formula_gui import VoiceFormulaDialog
from platformdirs import user_desktop_dir
# Import ctypes for Windows-specific taskbar icon
if platform.system() == "Windows":
@@ -1628,7 +1629,7 @@ class abogen(QWidget):
try:
# where to put the .lnk
desktop = os.path.join(os.environ.get("USERPROFILE", ""), "Desktop")
desktop = user_desktop_dir()
shortcut_path = os.path.join(desktop, "abogen.lnk")
# target exe