refactor: run Windows SelectFileDialog
out of process (#42780)
This commit is contained in:
parent
0a73b80127
commit
8d1b4652ff
3 changed files with 17 additions and 0 deletions
|
@ -96,6 +96,7 @@
|
|||
#endif
|
||||
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
#include "chrome/browser/win/chrome_select_file_dialog_factory.h"
|
||||
#include "ui/base/l10n/l10n_util_win.h"
|
||||
#include "ui/gfx/system_fonts_win.h"
|
||||
#include "ui/strings/grit/app_locale_settings.h"
|
||||
|
@ -484,6 +485,11 @@ int ElectronBrowserMainParts::PreMainMessageLoopRun() {
|
|||
|
||||
fake_browser_process_->PreMainMessageLoopRun();
|
||||
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
ui::SelectFileDialog::SetFactory(
|
||||
std::make_unique<ChromeSelectFileDialogFactory>());
|
||||
#endif
|
||||
|
||||
return GetExitCode();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue