Skip to content

Commit

Permalink
fix: Corrupted title of alert dialog (electron#32434)
Browse files Browse the repository at this point in the history
  • Loading branch information
babatakao authored and t57ser committed Jan 25, 2022
1 parent 52ca276 commit 2e2e46c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion shell/browser/ui/message_box_win.cc
Expand Up @@ -171,8 +171,9 @@ DialogResult ShowTaskDialogWstr(NativeWindow* parent,

// TaskDialogIndirect doesn't allow empty name, if we set empty title it
// will show "electron.exe" in title.
std::wstring app_name;
if (title.empty()) {
std::wstring app_name = base::UTF8ToWide(Browser::Get()->GetName());
app_name = base::UTF8ToWide(Browser::Get()->GetName());
config.pszWindowTitle = app_name.c_str();
} else {
config.pszWindowTitle = base::as_wcstr(title);
Expand Down

0 comments on commit 2e2e46c

Please sign in to comment.