Taskbar icon on windows (#861)
* Give app an unique ID when launching on Windows * Improve test coverage
This commit is contained in:
committed by
GitHub
parent
95c79e1c23
commit
7958cb530f
+10
-1
@@ -262,7 +262,16 @@ def main(sysArgs=None):
|
||||
bundle = NSBundle.mainBundle()
|
||||
info = bundle.localizedInfoDictionary() or bundle.infoDictionary()
|
||||
info["CFBundleName"] = "novelWriter"
|
||||
except ImportError:
|
||||
except Exception:
|
||||
logger.error("Failed to set application name")
|
||||
logException()
|
||||
|
||||
elif CONFIG.osWindows:
|
||||
try:
|
||||
import ctypes
|
||||
appID = "io.novelwriter.%s" % __version__
|
||||
ctypes.windll.shell32.SetCurrentProcessExplicitAppUserModelID(appID)
|
||||
except Exception:
|
||||
logger.error("Failed to set application name")
|
||||
logException()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user