lbry-sdk/lbrynet/lbrynet_daemon/LBRYOSXStatusBar.py
2016-02-19 00:07:19 -05:00

15 lines
471 B
Python

import rumps
import xmlrpclib
import os
class DaemonStatusBarApp(rumps.App):
def __init__(self):
super(DaemonStatusBarApp, self).__init__("LBRYnet", icon=os.path.join(os.path.expanduser("~"), "Downloads/lbryio//web/img/fav/apple-touch-icon.png"), quit_button=None)
self.menu = ["Quit"]
@rumps.clicked('Quit')
def clean_quit(self):
d = xmlrpclib.ServerProxy('http://localhost:7080')
d.stop()
rumps.quit_application()