[gtk/wip/baedert/transforms6: 145/155] testformentry: Pass transform in size_allocate
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/baedert/transforms6: 145/155] testformentry: Pass transform in size_allocate
- Date: Sat, 19 Jan 2019 07:17:04 +0000 (UTC)
commit bd49f2ba2291ffc4f95563571caed9bf7ed752ad
Author: Timm Bäder <mail baedert org>
Date: Sat Aug 18 17:06:20 2018 +0200
testformentry: Pass transform in size_allocate
tests/testformentry.c | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
---
diff --git a/tests/testformentry.c b/tests/testformentry.c
index 0105fd4030..bef884f983 100644
--- a/tests/testformentry.c
+++ b/tests/testformentry.c
@@ -55,18 +55,18 @@ gtk_form_entry_size_allocate (GtkWidget *widget,
x *= t;
- gtk_widget_size_allocate (self->placeholder,
- &(GtkAllocation) {
- x, y,
- width,
- placeholder_height
- }, -1);
-
graphene_matrix_init_scale (&m,
CLAMP (t, FINAL_SCALE, 1.0),
CLAMP (t, FINAL_SCALE, 1.0),
1);
- gtk_widget_set_transform (self->placeholder, &m);
+ graphene_matrix_translate (&m,
+ &GRAPHENE_POINT3D_INIT (x, y, 0));
+
+ gtk_widget_size_allocate_transformed (self->placeholder,
+ width,
+ placeholder_height,
+ -1,
+ &m);
}
}
@@ -89,7 +89,7 @@ gtk_form_entry_measure (GtkWidget *widget,
gtk_widget_measure (self->entry, orientation, for_size,
&min1, &nat1, NULL, NULL);
- gtk_widget_measure (self->entry, orientation, for_size,
+ gtk_widget_measure (self->placeholder, orientation, for_size,
&min2, &nat2, NULL, NULL);
*minimum = MAX (min1, min2);
@@ -103,7 +103,7 @@ gtk_form_entry_measure (GtkWidget *widget,
gtk_widget_measure (self->entry, orientation, -1,
&min, &nat, NULL, NULL);
- gtk_widget_measure (self->entry, orientation, -1,
+ gtk_widget_measure (self->placeholder, orientation, -1,
&pmin, &pnat, NULL, NULL);
*minimum = min + (pmin * FINAL_SCALE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]