1
0

plugins: do not overload __init__, use init() instead

This commit is contained in:
ThomasV
2013-08-05 17:15:01 +02:00
parent 58538ba825
commit b08f1a2a7b
8 changed files with 92 additions and 62 deletions

View File

@@ -18,10 +18,14 @@ except ImportError:
from electrum_gui import BasePlugin
class Plugin(BasePlugin):
def __init__(self, gui):
BasePlugin.__init__(self, gui, 'qrscans', 'QR scans', "QR Scans.\nInstall the zbar package (http://zbar.sourceforge.net/download.html) to enable this plugin")
def fullname(self): return 'QR scans'
def description(self): return "QR Scans.\nInstall the zbar package (http://zbar.sourceforge.net/download.html) to enable this plugin"
def __init__(self, gui, name):
BasePlugin.__init__(self, gui, name)
self._is_available = self._init()
def _init(self):
if not zbar:
return False