image: correct declaration + usage
- Declaration: setup.py declares the image a 'hackertray' data, gives its location and asks its inclusion - appindicator looks for the picture in folders near itself, instead of /usr/bin (near the main executable) or the first entry of path.
This commit is contained in:
parent
73aa49812e
commit
a11f7c4507
|
@ -25,8 +25,8 @@ STATUS_ATTENTION = 1
|
||||||
|
|
||||||
# Locations to search for the given icon
|
# Locations to search for the given icon
|
||||||
search_locations = [ os.path.join(os.path.dirname(sys.executable), "images"),
|
search_locations = [ os.path.join(os.path.dirname(sys.executable), "images"),
|
||||||
os.path.join(os.path.dirname(sys.path[0]), "images"),
|
os.path.join(os.path.dirname(__file__), "images"),
|
||||||
os.path.join(os.path.dirname(sys.path[0]), "../images"),
|
os.path.join(os.path.dirname(__file__), "../images"),
|
||||||
'/usr/share/pixmaps' ]
|
'/usr/share/pixmaps' ]
|
||||||
|
|
||||||
def get_icon_filename(icon_name):
|
def get_icon_filename(icon_name):
|
||||||
|
|
2
setup.py
2
setup.py
|
@ -8,6 +8,8 @@ setup(name='hackertray',
|
||||||
author_email='me@captnemo.in',
|
author_email='me@captnemo.in',
|
||||||
license='MIT',
|
license='MIT',
|
||||||
packages=['hackertray'],
|
packages=['hackertray'],
|
||||||
|
package_data={'hackertray': ['../images/hacker-tray.png']},
|
||||||
|
include_package_data=True,
|
||||||
install_requires=[
|
install_requires=[
|
||||||
'requests',
|
'requests',
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in New Issue