mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-31 17:31:36 +00:00
restore current path after modifying it.
This commit is contained in:
parent
c03705b2a5
commit
c10bacca28
1 changed files with 7 additions and 0 deletions
|
@ -48,6 +48,9 @@ class ElectrumGui:
|
|||
def __init__(self, wallet):
|
||||
self.wallet = wallet
|
||||
self.app = QApplication(sys.argv)
|
||||
# Should probably not modify the current path but instead
|
||||
# change the behaviour of rsrc(...)
|
||||
self.old_path = QDir.currentPath()
|
||||
cd_data_dir()
|
||||
with open(rsrc("style.css")) as style_file:
|
||||
self.app.setStyleSheet(style_file.read())
|
||||
|
@ -57,6 +60,10 @@ class ElectrumGui:
|
|||
self.mini = MiniWindow(actuator, self.expand)
|
||||
driver = MiniDriver(self.wallet, self.mini)
|
||||
|
||||
# Reset path back to original value now that loading the GUI
|
||||
# is completed.
|
||||
QDir.setCurrent(self.old_path)
|
||||
|
||||
if url:
|
||||
self.set_url(url)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue