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

Side by Side Diff: ui/views/win/hwnd_message_handler.cc

Issue 1859283003: Avoid restoring maximized window down when going fullscreen. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/views/win/hwnd_message_handler.h" 5 #include "ui/views/win/hwnd_message_handler.h"
6 6
7 #include <dwmapi.h> 7 #include <dwmapi.h>
8 #include <oleacc.h> 8 #include <oleacc.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 #include <tchar.h> 10 #include <tchar.h>
(...skipping 669 matching lines...) Expand 10 before | Expand all | Expand 10 after
680 680
681 bool HWNDMessageHandler::IsActive() const { 681 bool HWNDMessageHandler::IsActive() const {
682 return GetActiveWindow() == hwnd(); 682 return GetActiveWindow() == hwnd();
683 } 683 }
684 684
685 bool HWNDMessageHandler::IsMinimized() const { 685 bool HWNDMessageHandler::IsMinimized() const {
686 return !!::IsIconic(hwnd()); 686 return !!::IsIconic(hwnd());
687 } 687 }
688 688
689 bool HWNDMessageHandler::IsMaximized() const { 689 bool HWNDMessageHandler::IsMaximized() const {
690 return !!::IsZoomed(hwnd()); 690 return !!::IsZoomed(hwnd()) && !IsFullscreen();
691 } 691 }
692 692
693 bool HWNDMessageHandler::IsFullscreen() const { 693 bool HWNDMessageHandler::IsFullscreen() const {
694 return fullscreen_handler_->fullscreen(); 694 return fullscreen_handler_->fullscreen();
695 } 695 }
696 696
697 bool HWNDMessageHandler::IsAlwaysOnTop() const { 697 bool HWNDMessageHandler::IsAlwaysOnTop() const {
698 return (GetWindowLong(hwnd(), GWL_EXSTYLE) & WS_EX_TOPMOST) != 0; 698 return (GetWindowLong(hwnd(), GWL_EXSTYLE) & WS_EX_TOPMOST) != 0;
699 } 699 }
700 700
(...skipping 1928 matching lines...) Expand 10 before | Expand all | Expand 10 after
2629 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size()); 2629 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size());
2630 ResetWindowRegion(false, true); 2630 ResetWindowRegion(false, true);
2631 } 2631 }
2632 2632
2633 if (direct_manipulation_helper_) 2633 if (direct_manipulation_helper_)
2634 direct_manipulation_helper_->SetBounds(bounds_in_pixels); 2634 direct_manipulation_helper_->SetBounds(bounds_in_pixels);
2635 } 2635 }
2636 2636
2637 2637
2638 } // namespace views 2638 } // namespace views
OLDNEW
« ui/views/widget/widget_interactive_uitest.cc ('K') | « ui/views/win/fullscreen_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698