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

Unified Diff: ui/views/widget/desktop_aura/desktop_root_window_host_win.cc

Issue 136093007: Widget::ShouldUseNativeFrame is now meaningful on Linux. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Big refactor; fix Windows opaque windows when Glass is enabled. Created 6 years, 10 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: ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
diff --git a/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc b/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
index fb7950e161bb48c3eed8f29672af2904d5b699f8..801cfbd2c43c134b9810717240c0b23a85bacb5c 100644
--- a/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
+++ b/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
@@ -372,10 +372,18 @@ void DesktopWindowTreeHostWin::SetVisibilityChangedAnimationsEnabled(
content_window_->SetProperty(aura::client::kAnimationsDisabledKey, !value);
}
-bool DesktopWindowTreeHostWin::ShouldUseNativeFrame() {
+bool DesktopWindowTreeHostWin::ShouldUseNativeFrame() const {
return ui::win::IsAeroGlassEnabled();
}
+bool DesktopWindowTreeHostWin::ShouldWindowContentsBeTransparent() const {
+ // If the window has a native frame, we assume it is an Aero Glass window, and
+ // is therefore transparent. Note: This is not equivalent to calling
+ // IsAeroGlassEnabled, because ShouldUseNativeFrame is overridden in a
+ // subclass.
+ return ShouldUseNativeFrame();
+}
+
void DesktopWindowTreeHostWin::FrameTypeChanged() {
message_handler_->FrameTypeChanged();
SetWindowTransparency();

Powered by Google App Engine
This is Rietveld 408576698