Skip to content

Commit 50d12f4

Browse files
committed
[0.8.6] fix incorrect tray bar when switching account
1 parent 7f4ea0f commit 50d12f4

File tree

5 files changed

+8
-7
lines changed

5 files changed

+8
-7
lines changed

.github/workflows/compile-standalone.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
env:
1414
UPX_VERSION: "5.0.2"
1515
UPX_DIR: "${{ github.workspace }}/tools/upx"
16-
VERSION: "0.8.5"
16+
VERSION: "0.8.6"
1717

1818
steps:
1919
- name: Check-out repository

.github/workflows/compile-universal.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
env:
1818
UPX_VERSION: "5.0.2"
1919
UPX_DIR: "${{ github.workspace }}/tools/upx"
20-
VERSION: "0.8.5"
20+
VERSION: "0.8.6"
2121

2222
steps:
2323
- name: Check-out repository

constant/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "0.8.5"
1+
__version__ = "0.8.6"

models/widgets/sl_menu_bar.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class StartLiveMenuBar(QMenuBar):
2222
bgDeleted = Signal()
2323
credDeleted = Signal(bool)
2424
accountSwitch = Signal(int)
25-
accountAdded = Signal()
25+
accountAdded = Signal(int)
2626
accountMenuPopulated = Signal(int)
2727

2828
def __init__(self, parent=None, /):
@@ -193,4 +193,4 @@ def _add_new_account(self):
193193
return
194194
self._current_cookie_idx = self._cookie_index_len
195195
CredentialManagerWorker.reset_default()
196-
self.accountAdded.emit()
196+
self.accountAdded.emit(self._current_cookie_idx)

models/window/main_window.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -469,8 +469,9 @@ def _populate_tray_menu(self):
469469
f"当前账号:{app_state.usernames[cookie_indices[self._current_cookie_idx]]}")
470470
self.tray_curr_user.setEnabled(True)
471471

472-
@Slot()
473-
def _on_add_account(self):
472+
@Slot(int)
473+
def _on_add_account(self, cookie_index: int):
474+
self._current_cookie_idx = cookie_index
474475
self.setup_ui(is_new=True)
475476

476477
@Slot(str)

0 commit comments

Comments
 (0)