summaryrefslogtreecommitdiffstats
path: root/chrome/browser/shell_integration_win.cc
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-15 01:59:15 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-15 01:59:15 +0000
commit935aa54d9a5e2e617c61c9f8dcea398768413443 (patch)
tree3df9ec9316cd4d5b7171e5c6c869a01d823cc507 /chrome/browser/shell_integration_win.cc
parent7d1f3348c26eda2d1656860c821d335bf94d4cda (diff)
downloadchromium_src-935aa54d9a5e2e617c61c9f8dcea398768413443.zip
chromium_src-935aa54d9a5e2e617c61c9f8dcea398768413443.tar.gz
chromium_src-935aa54d9a5e2e617c61c9f8dcea398768413443.tar.bz2
Move windows version-related stuff out of base/win_util and into base/win/windows_version. Many files now only need to include this instead of all of win_util.
Remove a bunch of unused code from base/win_util. There was a surprising amount. Replace the AppUserModel property key with the one from the SDK now that we use the Win7 SDK. Move GetLogonSessionOnlyDACL from win_util to ipc since it's only used in that one place. TEST=it compiles BUG=none Review URL: http://codereview.chromium.org/3823002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62694 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/shell_integration_win.cc')
-rw-r--r--chrome/browser/shell_integration_win.cc13
1 files changed, 7 insertions, 6 deletions
diff --git a/chrome/browser/shell_integration_win.cc b/chrome/browser/shell_integration_win.cc
index 9b1c7d3..98e6729 100644
--- a/chrome/browser/shell_integration_win.cc
+++ b/chrome/browser/shell_integration_win.cc
@@ -5,9 +5,9 @@
#include "chrome/browser/shell_integration.h"
#include <windows.h>
-#include <propvarutil.h>
-#include <shlobj.h>
#include <shobjidl.h>
+#include <propkey.h>
+#include <propvarutil.h>
#include "base/command_line.h"
#include "base/file_util.h"
@@ -19,6 +19,7 @@
#include "base/task.h"
#include "base/utf_string_conversions.h"
#include "base/win_util.h"
+#include "base/win/windows_version.h"
#include "chrome/browser/browser_thread.h"
#include "chrome/browser/web_applications/web_app.h"
#include "chrome/common/chrome_constants.h"
@@ -249,7 +250,7 @@ bool MigrateChromiumShortcutsTask::GetShortcutAppId(
PROPVARIANT appid_value;
PropVariantInit(&appid_value);
- if (FAILED(property_store->GetValue(win_util::kPKEYAppUserModelID,
+ if (FAILED(property_store->GetValue(PKEY_AppUserModel_ID,
&appid_value)))
return false;
@@ -300,7 +301,7 @@ ShellIntegration::DefaultBrowserState ShellIntegration::IsDefaultBrowser() {
// to show up in Add/Remove programs for us.
const std::wstring kChromeProtocols[] = {L"http", L"https"};
- if (win_util::GetWinVersion() >= win_util::WINVERSION_VISTA) {
+ if (base::win::GetVersion() >= base::win::VERSION_VISTA) {
IApplicationAssociationRegistration* pAAR;
HRESULT hr = CoCreateInstance(CLSID_ApplicationAssociationRegistration,
NULL, CLSCTX_INPROC, __uuidof(IApplicationAssociationRegistration),
@@ -368,7 +369,7 @@ ShellIntegration::DefaultBrowserState ShellIntegration::IsDefaultBrowser() {
// is false.
bool ShellIntegration::IsFirefoxDefaultBrowser() {
bool ff_default = false;
- if (win_util::GetWinVersion() >= win_util::WINVERSION_VISTA) {
+ if (base::win::GetVersion() >= base::win::VERSION_VISTA) {
std::wstring app_cmd;
RegKey key(HKEY_CURRENT_USER, ShellUtil::kRegVistaUrlPrefs, KEY_READ);
if (key.Valid() && key.ReadValue(L"Progid", &app_cmd) &&
@@ -407,7 +408,7 @@ std::wstring ShellIntegration::GetChromiumAppId(const FilePath& profile_path) {
}
void ShellIntegration::MigrateChromiumShortcuts() {
- if (win_util::GetWinVersion() < win_util::WINVERSION_WIN7)
+ if (base::win::GetVersion() < base::win::VERSION_WIN7)
return;
BrowserThread::PostTask(