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

Unified Diff: views/window/window.cc

Issue 6975037: Revert 85666 - Consolidate ShouldUseNativeFrame/AlwaysUseNativeFrame/UseNativeFrame spaghetti. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 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 | « views/window/window.h ('k') | views/window/window_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/window/window.cc
===================================================================
--- views/window/window.cc (revision 85701)
+++ views/window/window.cc (working copy)
@@ -37,8 +37,7 @@
saved_maximized_state_(false),
minimum_size_(100, 100),
disable_inactive_rendering_(false),
- window_closed_(false),
- frame_type_(FRAME_TYPE_DEFAULT) {
+ window_closed_(false) {
}
Window::~Window() {
@@ -239,22 +238,9 @@
}
bool Window::ShouldUseNativeFrame() const {
- if (frame_type_ != FRAME_TYPE_DEFAULT)
- return frame_type_ == FRAME_TYPE_FORCE_NATIVE;
return native_window_->ShouldUseNativeFrame();
}
-void Window::DebugToggleFrameType() {
- if (frame_type_ == FRAME_TYPE_DEFAULT) {
- frame_type_ = ShouldUseNativeFrame() ? FRAME_TYPE_FORCE_CUSTOM :
- FRAME_TYPE_FORCE_NATIVE;
- } else {
- frame_type_ = frame_type_ == FRAME_TYPE_FORCE_CUSTOM ?
- FRAME_TYPE_FORCE_NATIVE : FRAME_TYPE_FORCE_CUSTOM;
- }
- FrameTypeChanged();
-}
-
void Window::FrameTypeChanged() {
native_window_->FrameTypeChanged();
}
@@ -283,6 +269,10 @@
return !!window_delegate_->AsDialogDelegate();
}
+bool Window::IsUsingNativeFrame() const {
+ return non_client_view_->UseNativeFrame();
+}
+
gfx::Size Window::GetMinimumSize() const {
return non_client_view_->GetMinimumSize();
}
« no previous file with comments | « views/window/window.h ('k') | views/window/window_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698