[gtk/wip/otte/whatever: 3/5] scrolledwindow: Expand by default
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/otte/whatever: 3/5] scrolledwindow: Expand by default
- Date: Sat, 27 Jun 2020 04:40:23 +0000 (UTC)
commit c0cef79e56a9e9e331a1035085e5b58b1cce580d
Author: Benjamin Otte <otte redhat com>
Date: Sat Jun 27 06:30:31 2020 +0200
scrolledwindow: Expand by default
Use gtk_scrolled_window_set_hexpand/vexpand(FALSE) to make the scrolled
window not expand.
gtk/gtkscrolledwindow.c | 15 ++-------------
1 file changed, 2 insertions(+), 13 deletions(-)
---
diff --git a/gtk/gtkscrolledwindow.c b/gtk/gtkscrolledwindow.c
index 25312db293..15d8af5a9f 100644
--- a/gtk/gtkscrolledwindow.c
+++ b/gtk/gtkscrolledwindow.c
@@ -546,19 +546,8 @@ gtk_scrolled_window_compute_expand (GtkWidget *widget,
gboolean *hexpand,
gboolean *vexpand)
{
- GtkScrolledWindow *scrolled_window = GTK_SCROLLED_WINDOW (widget);
- GtkScrolledWindowPrivate *priv = gtk_scrolled_window_get_instance_private (scrolled_window);
-
- if (priv->child)
- {
- *hexpand = gtk_widget_compute_expand (priv->child, GTK_ORIENTATION_HORIZONTAL);
- *vexpand = gtk_widget_compute_expand (priv->child, GTK_ORIENTATION_VERTICAL);
- }
- else
- {
- *hexpand = FALSE;
- *vexpand = FALSE;
- }
+ *hexpand = TRUE;
+ *vexpand = TRUE;
}
static GtkSizeRequestMode
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]