[clutter-gtk] embed: Pass scaled size back to clutter
- From: Adel Gadllah <agadllah src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter-gtk] embed: Pass scaled size back to clutter
- Date: Fri, 14 Feb 2014 14:35:57 +0000 (UTC)
commit 2edce832b767d54b9c0f45d3e9bb549433e28c35
Author: Adel Gadllah <adel gadllah gmail com>
Date: Fri Feb 14 15:16:41 2014 +0100
embed: Pass scaled size back to clutter
Instead of messing with the allocation leave it as is
and send the scaled size to clutter in the synthetic XConfigureEvent.
https://bugzilla.gnome.org/show_bug.cgi?id=724055
clutter-gtk/gtk-clutter-embed.c | 9 ++-------
1 files changed, 2 insertions(+), 7 deletions(-)
---
diff --git a/clutter-gtk/gtk-clutter-embed.c b/clutter-gtk/gtk-clutter-embed.c
index 5204860..ac4f1d7 100644
--- a/clutter-gtk/gtk-clutter-embed.c
+++ b/clutter-gtk/gtk-clutter-embed.c
@@ -508,11 +508,6 @@ gtk_clutter_embed_size_allocate (GtkWidget *widget,
*/
clutter_actor_set_size (priv->stage, allocation->width, allocation->height);
- allocation->x = allocation->x * scale_factor;
- allocation->x = allocation->x * scale_factor;
- allocation->width = allocation->width * scale_factor;
- allocation->height = allocation->height * scale_factor;
-
if (gtk_widget_get_realized (widget))
{
gdk_window_move_resize (gtk_widget_get_window (widget),
@@ -531,8 +526,8 @@ gtk_clutter_embed_size_allocate (GtkWidget *widget,
{
XConfigureEvent xevent = { ConfigureNotify };
xevent.window = GDK_WINDOW_XID (gtk_widget_get_window (widget));
- xevent.width = allocation->width;
- xevent.height = allocation->height;
+ xevent.width = allocation->width * scale_factor;
+ xevent.height = allocation->height * scale_factor;
/* Ensure cogl knows about the new size immediately, as we will
draw before we get the ConfigureNotify response. */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]