diff options
author | joi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-01 19:58:30 +0000 |
---|---|---|
committer | joi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-01 19:58:30 +0000 |
commit | 38f57abb36fa6c91d9939a2393f9998dd40c51ba (patch) | |
tree | 061d6b93b361cd12589bb8fb294e831b6a66382b /chrome_frame | |
parent | cb4da7b7cca16b19401ae9475383c70ac310337e (diff) | |
download | chromium_src-38f57abb36fa6c91d9939a2393f9998dd40c51ba.zip chromium_src-38f57abb36fa6c91d9939a2393f9998dd40c51ba.tar.gz chromium_src-38f57abb36fa6c91d9939a2393f9998dd40c51ba.tar.bz2 |
Always use persistent profile for CF+CEEE installs.
BUG=64840
TEST=With --enable-ceee, CF profiles on IE7 should not be under Temporary Internet Files.
Review URL: http://codereview.chromium.org/5254012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@67890 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame')
-rw-r--r-- | chrome_frame/chrome_frame.gyp | 2 | ||||
-rw-r--r-- | chrome_frame/chrome_frame_activex_base.h | 8 | ||||
-rw-r--r-- | chrome_frame/test/chrome_frame_test_utils.cc | 9 |
3 files changed, 15 insertions, 4 deletions
diff --git a/chrome_frame/chrome_frame.gyp b/chrome_frame/chrome_frame.gyp index 6fc4d6d..095a1ed 100644 --- a/chrome_frame/chrome_frame.gyp +++ b/chrome_frame/chrome_frame.gyp @@ -695,6 +695,8 @@ 'chrome_frame_strings', 'chrome_frame_utils', 'chrome_tab_idl', + '../ceee/ie/common/common.gyp:ie_common', + '../ceee/ie/common/common.gyp:ie_guids', '../chrome/chrome.gyp:common', '../chrome/chrome.gyp:utility', '../build/temp_gyp/googleurl.gyp:googleurl', diff --git a/chrome_frame/chrome_frame_activex_base.h b/chrome_frame/chrome_frame_activex_base.h index ebaf06c..1dd2755 100644 --- a/chrome_frame/chrome_frame_activex_base.h +++ b/chrome_frame/chrome_frame_activex_base.h @@ -24,6 +24,7 @@ #include "base/win/scoped_comptr.h" #include "base/win/scoped_variant.h" #include "grit/chrome_frame_resources.h" +#include "ceee/ie/common/ceee_util.h" #include "chrome/common/url_constants.h" #include "chrome_frame/chrome_frame_plugin.h" #include "chrome_frame/com_message_event.h" @@ -411,7 +412,12 @@ END_MSG_MAP() (lstrcmpi(profile_name.c_str(), kRundllProfileName) == 0); // Browsers without IDeleteBrowsingHistory in non-priv mode // have their profiles moved into "Temporary Internet Files". - if (is_IE && GetIEVersion() < IE_8 && !is_privileged_) { + // + // If CEEE is registered, we must have a persistent profile. We + // considered checking if e.g. ceee_ie.dll is loaded in the process + // but this gets into edge cases when the user enables the CEEE add-on + // after CF is first loaded. + if (is_IE && GetIEVersion() < IE_8 && !ceee_util::IsIeCeeeRegistered()) { *profile_path = GetIETemporaryFilesFolder(); *profile_path = profile_path->Append(L"Google Chrome Frame"); } else { diff --git a/chrome_frame/test/chrome_frame_test_utils.cc b/chrome_frame/test/chrome_frame_test_utils.cc index c51877f..f44f22c 100644 --- a/chrome_frame/test/chrome_frame_test_utils.cc +++ b/chrome_frame/test/chrome_frame_test_utils.cc @@ -24,6 +24,7 @@ #include "base/win_util.h" #include "base/win/registry.h" #include "base/win/windows_version.h" +#include "ceee/ie/common/ceee_util.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/chrome_paths.h" #include "chrome/common/chrome_paths_internal.h" @@ -400,6 +401,7 @@ HRESULT LaunchIEAsComServer(IWebBrowser2** web_browser) { return hr; } +// TODO(joi@chromium.org) Could share this code with chrome_frame_plugin.h FilePath GetProfilePath(const std::wstring& profile_name) { FilePath profile_path; chrome::GetChromeFrameUserDataDirectory(&profile_path); @@ -432,17 +434,18 @@ IEVersion GetInstalledIEVersion() { return IE_UNSUPPORTED; } +// TODO(joi@chromium.org) Could share this code with chrome_frame_plugin.h FilePath GetProfilePathForIE() { FilePath profile_path; // Browsers without IDeleteBrowsingHistory in non-priv mode // have their profiles moved into "Temporary Internet Files". // The code below basically retrieves the version of IE and computes // the profile directory accordingly. - if (GetInstalledIEVersion() >= IE_8) { - profile_path = GetProfilePath(kIEProfileName); - } else { + if (GetInstalledIEVersion() <= IE_7 && !ceee_util::IsIeCeeeRegistered()) { profile_path = GetIETemporaryFilesFolder(); profile_path = profile_path.Append(L"Google Chrome Frame"); + } else { + profile_path = GetProfilePath(kIEProfileName); } return profile_path; } |