Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6520)

Unified Diff: chrome/browser/ui/webui/options/advanced_options_utils_win.cc

Issue 23889021: Parent SSL certs window properly in win aura (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/options/advanced_options_utils_win.cc
diff --git a/chrome/browser/ui/webui/options/advanced_options_utils_win.cc b/chrome/browser/ui/webui/options/advanced_options_utils_win.cc
index 39e47512f9593eab4b7faeebe6512b280e1a747d..448b75c11aea10e1d598e06c5ff3738de036cf07 100644
--- a/chrome/browser/ui/webui/options/advanced_options_utils_win.cc
+++ b/chrome/browser/ui/webui/options/advanced_options_utils_win.cc
@@ -16,6 +16,7 @@
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/web_contents.h"
#include "content/public/browser/web_contents_view.h"
+#include "ui/views/win/hwnd_util.h"
using content::BrowserThread;
using content::WebContents;
@@ -60,11 +61,12 @@ void AdvancedOptionsUtilities::ShowManageSSLCertificates(
WebContents* web_contents) {
CRYPTUI_CERT_MGR_STRUCT cert_mgr = { 0 };
cert_mgr.dwSize = sizeof(CRYPTUI_CERT_MGR_STRUCT);
- cert_mgr.hwndParent =
+ gfx::NativeWindow top_level_window =
+ web_contents->GetView()->GetTopLevelNativeWindow();
#if defined(USE_AURA)
sky 2013/09/16 16:59:29 Can you use views::HWNDForNativeView to avoid the
scottmg 2013/09/16 17:26:38 Oops, didn't realize those were implemented for no
- NULL;
+ cert_mgr.hwndParent = views::HWNDForNativeWindow(top_level_window);
#else
- web_contents->GetView()->GetTopLevelNativeWindow();
+ cert_mgr.hwndParent = top_level_window;
#endif
::CryptUIDlgCertMgr(&cert_mgr);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698