Append the app user model ID as a switch
This commit is contained in:
parent
a0784bd038
commit
779583adf5
1 changed files with 11 additions and 0 deletions
|
@ -50,6 +50,7 @@
|
||||||
|
|
||||||
#if defined(OS_WIN)
|
#if defined(OS_WIN)
|
||||||
#include "ui/gfx/switches.h"
|
#include "ui/gfx/switches.h"
|
||||||
|
#include <shlobj.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
using content::NavigationEntry;
|
using content::NavigationEntry;
|
||||||
|
@ -388,6 +389,16 @@ void NativeWindow::AppendExtraCommandLineSwitches(
|
||||||
command_line->AppendSwitchASCII(switches::kZoomFactor,
|
command_line->AppendSwitchASCII(switches::kZoomFactor,
|
||||||
base::DoubleToString(zoom_factor_));
|
base::DoubleToString(zoom_factor_));
|
||||||
|
|
||||||
|
#if defined(OS_WIN)
|
||||||
|
PWSTR explicit_app_id;
|
||||||
|
|
||||||
|
if (SUCCEEDED(GetCurrentProcessExplicitAppUserModelID(&explicit_app_id))) {
|
||||||
|
base::string16 appId = base::string16(explicit_app_id);
|
||||||
|
command_line->AppendSwitchNative(switches::kAppUserModelId, appId);
|
||||||
|
CoTaskMemFree(explicit_app_id);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if (web_preferences_.IsEmpty())
|
if (web_preferences_.IsEmpty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue