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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc

Issue 1059853007: Mac/Linux: Ensure window size constraints propagate to the window server during Init (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cracked the case on Windows Created 5 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/test/widget_test_mac.mm ('k') | ui/views/widget/native_widget_mac.mm » ('j') | 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/widget/desktop_aura/desktop_window_tree_host_x11.h" 5 #include "ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h"
6 6
7 #include <X11/extensions/shape.h> 7 #include <X11/extensions/shape.h>
8 #include <X11/extensions/XInput2.h> 8 #include <X11/extensions/XInput2.h>
9 #include <X11/Xatom.h> 9 #include <X11/Xatom.h>
10 #include <X11/Xregion.h> 10 #include <X11/Xregion.h>
(...skipping 1594 matching lines...) Expand 10 before | Expand all | Expand 10 after
1605 1605
1606 XMapWindow(xdisplay_, xwindow_); 1606 XMapWindow(xdisplay_, xwindow_);
1607 1607
1608 // We now block until our window is mapped. Some X11 APIs will crash and 1608 // We now block until our window is mapped. Some X11 APIs will crash and
1609 // burn if passed |xwindow_| before the window is mapped, and XMapWindow is 1609 // burn if passed |xwindow_| before the window is mapped, and XMapWindow is
1610 // asynchronous. 1610 // asynchronous.
1611 if (ui::X11EventSource::GetInstance()) 1611 if (ui::X11EventSource::GetInstance())
1612 ui::X11EventSource::GetInstance()->BlockUntilWindowMapped(xwindow_); 1612 ui::X11EventSource::GetInstance()->BlockUntilWindowMapped(xwindow_);
1613 window_mapped_ = true; 1613 window_mapped_ = true;
1614 1614
1615 UpdateMinAndMaxSize();
1616
1615 // Some WMs only respect maximize hints after the window has been mapped. 1617 // Some WMs only respect maximize hints after the window has been mapped.
1616 // Check whether we need to re-do a maximization. 1618 // Check whether we need to re-do a maximization.
1617 if (should_maximize_after_map_) { 1619 if (should_maximize_after_map_) {
1618 Maximize(); 1620 Maximize();
1619 should_maximize_after_map_ = false; 1621 should_maximize_after_map_ = false;
1620 } 1622 }
1621 } 1623 }
1622 1624
1623 void DesktopWindowTreeHostX11::SetWindowTransparency() { 1625 void DesktopWindowTreeHostX11::SetWindowTransparency() {
1624 compositor()->SetHostHasTransparentBackground(use_argb_visual_); 1626 compositor()->SetHostHasTransparentBackground(use_argb_visual_);
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
1985 if (linux_ui) { 1987 if (linux_ui) {
1986 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window); 1988 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window);
1987 if (native_theme) 1989 if (native_theme)
1988 return native_theme; 1990 return native_theme;
1989 } 1991 }
1990 1992
1991 return ui::NativeTheme::instance(); 1993 return ui::NativeTheme::instance();
1992 } 1994 }
1993 1995
1994 } // namespace views 1996 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/test/widget_test_mac.mm ('k') | ui/views/widget/native_widget_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698