def main(self, url): storage = WalletStorage(self.config) if not storage.file_exists: import installwizard wizard = installwizard.InstallWizard(self.config, self.network, storage) wallet = wizard.run() if not wallet: exit() else: wallet = Wallet(storage) wallet.start_threads(self.network) s = Timer() s.start() w = ElectrumWindow(self.config, self.network, self.minimize) w.load_wallet(wallet) self.windows.append(w) if url: w.set_url(url) w.app = self.app w.connect_slots(s) w.update_wallet() self.expert = w self.mini = self.init_lite(wallet, w, url) if self.config.get('lite_mode'): if not self.mini: QMessageBox.warning(None,"Could not start Lite GUI.", "Electrum was unable to load the 'Lite GUI' because it needs Qt version >= 4.7.\nChanging your config to use the 'Classic' GUI") self.config.set_key('lite_mode', False, True) sys.exit(0) else: self.minimize() else: w.show() if self.mini: self.mini.hide() self.app.exec_() wallet.stop_threads()