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

Side by Side Diff: views/widget/native_widget_gtk.cc

Issue 8351042: Gets disable inactive frame rendering to work correctly for aura. This (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Tweaks Created 9 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/widget/native_widget_gtk.h" 5 #include "views/widget/native_widget_gtk.h"
6 6
7 #include <gdk/gdk.h> 7 #include <gdk/gdk.h>
8 #include <gdk/gdkx.h> 8 #include <gdk/gdkx.h>
9 #include <X11/extensions/shape.h> 9 #include <X11/extensions/shape.h>
10 #include <X11/Xatom.h> 10 #include <X11/Xatom.h>
(...skipping 1353 matching lines...) Expand 10 before | Expand all | Expand 10 after
1364 ViewsDelegate *delegate = ViewsDelegate::views_delegate; 1364 ViewsDelegate *delegate = ViewsDelegate::views_delegate;
1365 if (delegate && delegate->GetDefaultParentView()) { 1365 if (delegate && delegate->GetDefaultParentView()) {
1366 // For views-desktop, the work area is the entire space inside this 1366 // For views-desktop, the work area is the entire space inside this
1367 // containter window. 1367 // containter window.
1368 return gfx::Rect(gfx::Point(0, 0), 1368 return gfx::Rect(gfx::Point(0, 0),
1369 delegate->GetDefaultParentView()->size()); 1369 delegate->GetDefaultParentView()->size());
1370 } else 1370 } else
1371 return gfx::Screen::GetMonitorWorkAreaNearestWindow(GetNativeView()); 1371 return gfx::Screen::GetMonitorWorkAreaNearestWindow(GetNativeView());
1372 } 1372 }
1373 1373
1374 void NativeWidgetGtk::SetInactiveRenderingDisabled(bool value) {
1375 }
1376
1374 //////////////////////////////////////////////////////////////////////////////// 1377 ////////////////////////////////////////////////////////////////////////////////
1375 // NativeWidgetGtk, protected: 1378 // NativeWidgetGtk, protected:
1376 1379
1377 void NativeWidgetGtk::OnSizeRequest(GtkWidget* widget, 1380 void NativeWidgetGtk::OnSizeRequest(GtkWidget* widget,
1378 GtkRequisition* requisition) { 1381 GtkRequisition* requisition) {
1379 // Do only return the preferred size for child windows. GtkWindow interprets 1382 // Do only return the preferred size for child windows. GtkWindow interprets
1380 // the requisition as a minimum size for top level windows, returning a 1383 // the requisition as a minimum size for top level windows, returning a
1381 // preferred size for these would prevents us from setting smaller window 1384 // preferred size for these would prevents us from setting smaller window
1382 // sizes. 1385 // sizes.
1383 if (child_) { 1386 if (child_) {
(...skipping 920 matching lines...) Expand 10 before | Expand all | Expand 10 after
2304 button_pressed = event->type == GDK_BUTTON_PRESS || 2307 button_pressed = event->type == GDK_BUTTON_PRESS ||
2305 event->type == GDK_2BUTTON_PRESS || 2308 event->type == GDK_2BUTTON_PRESS ||
2306 event->type == GDK_3BUTTON_PRESS; 2309 event->type == GDK_3BUTTON_PRESS;
2307 gdk_event_free(event); 2310 gdk_event_free(event);
2308 } 2311 }
2309 return button_pressed; 2312 return button_pressed;
2310 } 2313 }
2311 2314
2312 } // namespace internal 2315 } // namespace internal
2313 } // namespace views 2316 } // namespace views
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698