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

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
« no previous file with comments | « ui/views/win/fullscreen_handler.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 665 matching lines...) Expand 10 before | Expand all | Expand 10 after
676 676
677 bool HWNDMessageHandler::IsActive() const { 677 bool HWNDMessageHandler::IsActive() const {
678 return GetActiveWindow() == hwnd(); 678 return GetActiveWindow() == hwnd();
679 } 679 }
680 680
681 bool HWNDMessageHandler::IsMinimized() const { 681 bool HWNDMessageHandler::IsMinimized() const {
682 return !!::IsIconic(hwnd()); 682 return !!::IsIconic(hwnd());
683 } 683 }
684 684
685 bool HWNDMessageHandler::IsMaximized() const { 685 bool HWNDMessageHandler::IsMaximized() const {
686 return !!::IsZoomed(hwnd()); 686 return !!::IsZoomed(hwnd()) && !IsFullscreen();
687 } 687 }
688 688
689 bool HWNDMessageHandler::IsFullscreen() const { 689 bool HWNDMessageHandler::IsFullscreen() const {
690 return fullscreen_handler_->fullscreen(); 690 return fullscreen_handler_->fullscreen();
691 } 691 }
692 692
693 bool HWNDMessageHandler::IsAlwaysOnTop() const { 693 bool HWNDMessageHandler::IsAlwaysOnTop() const {
694 return (GetWindowLong(hwnd(), GWL_EXSTYLE) & WS_EX_TOPMOST) != 0; 694 return (GetWindowLong(hwnd(), GWL_EXSTYLE) & WS_EX_TOPMOST) != 0;
695 } 695 }
696 696
(...skipping 1949 matching lines...) Expand 10 before | Expand all | Expand 10 after
2646 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size()); 2646 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size());
2647 ResetWindowRegion(false, true); 2647 ResetWindowRegion(false, true);
2648 } 2648 }
2649 2649
2650 if (direct_manipulation_helper_) 2650 if (direct_manipulation_helper_)
2651 direct_manipulation_helper_->SetBounds(bounds_in_pixels); 2651 direct_manipulation_helper_->SetBounds(bounds_in_pixels);
2652 } 2652 }
2653 2653
2654 2654
2655 } // namespace views 2655 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/win/fullscreen_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698