Skip to content

Commit 7ec4afd

Browse files
[DDW-892] Use fresh locale while rebuilding the application menu (#2813)
Co-authored-by: Daniel Main <[email protected]>
1 parent b5b7664 commit 7ec4afd

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
### Fixes
66

7+
- Fixed immediate language updates of application top menu bar ([PR 2813](https://github.com/input-output-hk/daedalus/pull/2813))
78
- Fixed receiver address validation by disallowing rewards addresses ([PR 2781](https://github.com/input-output-hk/daedalus/pull/2781))
89

910
### Chores

source/main/index.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,8 @@ const onAppReady = async () => {
172172
enableApplicationMenuNavigationChannel.onReceive(
173173
() =>
174174
new Promise((resolve) => {
175-
buildAppMenus(mainWindow, cardanoNode, userLocale, {
175+
const locale = getLocale(network);
176+
buildAppMenus(mainWindow, cardanoNode, locale, {
176177
isNavigationEnabled: true,
177178
});
178179
resolve();
@@ -182,10 +183,11 @@ const onAppReady = async () => {
182183
rebuildApplicationMenu.onReceive(
183184
(data) =>
184185
new Promise((resolve) => {
185-
buildAppMenus(mainWindow, cardanoNode, userLocale, {
186+
const locale = getLocale(network);
187+
buildAppMenus(mainWindow, cardanoNode, locale, {
186188
isNavigationEnabled: data.isNavigationEnabled,
187189
});
188-
mainWindow.updateTitle(userLocale);
190+
mainWindow.updateTitle(locale);
189191
resolve();
190192
})
191193
);

0 commit comments

Comments
 (0)