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

Unified Diff: chrome/browser/ui/views/panels/panel_view.cc

Issue 13853010: Make panels turn on or off shadow effect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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
Index: chrome/browser/ui/views/panels/panel_view.cc
diff --git a/chrome/browser/ui/views/panels/panel_view.cc b/chrome/browser/ui/views/panels/panel_view.cc
index 8091c9ff283e5c6174dfb42294adbc9bab63fc62..b73731dec4f3c0d66b20f19e4afde047ba4de69a 100644
--- a/chrome/browser/ui/views/panels/panel_view.cc
+++ b/chrome/browser/ui/views/panels/panel_view.cc
@@ -644,6 +644,19 @@ bool PanelView::IsPanelMinimizedBySystem() const {
return window_->IsMinimized();
}
+void PanelView::SetPanelHasShadow(bool has_shadow) {
+#if defined(OS_WIN)
+ // The overlapped window has the shadow while the popup window does not have
+ // the shadow.
+ int overlap_style = WS_OVERLAPPED | WS_THICKFRAME | WS_SYSMENU;
+ int popup_style = WS_POPUP;
+ UpdateWindowAttribute(GWL_STYLE,
+ has_shadow ? overlap_style : popup_style,
+ has_shadow ? popup_style : overlap_style,
+ true);
+#endif
+}
+
void PanelView::AttachWebContents(content::WebContents* contents) {
web_view_->SetWebContents(contents);
}
« chrome/browser/ui/panels/panel.h ('K') | « chrome/browser/ui/views/panels/panel_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698