From c9bb06f4cee992d31f97ee893663a476d4efba0c Mon Sep 17 00:00:00 2001 From: "xiyuan@chromium.org" Date: Wed, 13 Jan 2010 23:53:48 +0000 Subject: Ensure existing user pinned chrome shortcuts have correct app id. On Win7, check if user has pinned chrome shortcuts and ensure they have correct app id. BUG=28104 TEST=On Win7, install chrome prior 4.0.266.0 and pin chrome shortcut (browser with default profile, browser with non-default profile, web apps etc). Then update to a version with this fix. After update, running chrome should not have duplicate icon spawned. Review URL: http://codereview.chromium.org/548008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36193 0039d316-1c4b-4281-b951-d872f2087c98 --- base/win_util.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'base/win_util.cc') diff --git a/base/win_util.cc b/base/win_util.cc index fa168d0..12cf241 100644 --- a/base/win_util.cc +++ b/base/win_util.cc @@ -21,6 +21,10 @@ namespace win_util { #define NONCLIENTMETRICS_SIZE_PRE_VISTA \ SIZEOF_STRUCT_WITH_SPECIFIED_LAST_MEMBER(NONCLIENTMETRICS, lfMessageFont) +const PROPERTYKEY kPKEYAppUserModelID = + { { 0x9F4C2855, 0x9F79, 0x4B39, + { 0xA8, 0xD0, 0xE1, 0xD4, 0x2D, 0xE1, 0xD5, 0xF3, } }, 5 }; + void GetNonClientMetrics(NONCLIENTMETRICS* metrics) { DCHECK(metrics); @@ -394,10 +398,6 @@ bool SetAppIdForPropertyStore(IPropertyStore* property_store, // See http://msdn.microsoft.com/en-us/library/dd378459%28VS.85%29.aspx DCHECK(lstrlen(app_id) < 128 && wcschr(app_id, L' ') == NULL); - static const PROPERTYKEY kPKEYAppUserModelID = - { { 0x9F4C2855, 0x9F79, 0x4B39, - { 0xA8, 0xD0, 0xE1, 0xD4, 0x2D, 0xE1, 0xD5, 0xF3, } }, 5 }; - PROPVARIANT property_value; if (FAILED(InitPropVariantFromString(app_id, &property_value))) return false; -- cgit v1.1