Set black icon for mac

This commit is contained in:
Ruud
2014-10-11 22:45:31 +02:00
parent c657d6d70b
commit c8a3b64624
4 changed files with 11 additions and 5 deletions
+9 -3
View File
@@ -15,6 +15,13 @@ if hasattr(sys, 'frozen'):
else:
base_path = os.path.dirname(os.path.abspath(__file__))
def icon():
icon = 'icon_windows.png'
if os.path.isfile('icon_mac.png'):
icon = 'icon_mac.png'
return wx.Icon(icon, wx.BITMAP_TYPE_PNG)
lib_dir = os.path.join(base_path, 'libs')
sys.path.insert(0, base_path)
@@ -36,8 +43,7 @@ class TaskBarIcon(wx.TaskBarIcon):
wx.TaskBarIcon.__init__(self)
self.frame = frame
icon = wx.Icon('icon.png', wx.BITMAP_TYPE_PNG)
self.SetIcon(icon)
self.SetIcon(icon())
self.Bind(wx.EVT_TASKBAR_LEFT_UP, self.OnTaskBarClick)
self.Bind(wx.EVT_TASKBAR_RIGHT_UP, self.OnTaskBarClick)
@@ -170,7 +176,7 @@ class CouchPotatoApp(wx.App, SoftwareUpdate):
# Updater
base_url = 'https://api.couchpota.to/updates/%s'
self.InitUpdates(base_url % VERSION + '/', 'https://couchpota.to/updates/%s' % 'changelog.html',
icon = wx.Icon('icon.png'))
icon = icon())
self.frame = MainFrame(self)
self.frame.Bind(wx.EVT_CLOSE, self.onClose)
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 435 B

View File

Before

Width:  |  Height:  |  Size: 543 B

After

Width:  |  Height:  |  Size: 543 B

+2 -2
View File
@@ -56,7 +56,7 @@ if sys.platform == "win32":
)
exeICON = os.path.join(base_path, 'icon.ico')
DATA_FILES = getDataFiles([r'.\\couchpotato', r'.\\libs'])
DATA_FILES.append('icon.png')
DATA_FILES.append('icon_windows.png')
file_ext = 'win32.zip'
@@ -78,7 +78,7 @@ elif sys.platform == "darwin":
includes = includes,
)
exeICON = None
DATA_FILES = ['icon.png']
DATA_FILES = ['icon_mac.png']
file_ext = 'macosx-10_6-intel.zip'