[PATCH] Test UI improvements



While trying some thing, I saw some annoying things, like not being able
to scroll horizontally both on the metadata and the list panels. Other
thing I though is that we needed a hpaned instead of a hbox to separate
the metadata and the list views. Here you have the patches.

Br.

-- 
Xabier Rodríguez Calvar
Enxeñeiro en Informática
IGALIA http://www.igalia.com
From 316cb03085a03fb67fa9cefa7e8c8bf1b77840cf Mon Sep 17 00:00:00 2001
From: Xabier Rodriguez Calvar <xrcalvar igalia com>
Date: Tue, 8 Jun 2010 10:45:32 +0200
Subject: [PATCH 1/3] [grilo-test-ui] Replaced hbox with hpaned.

Now we can move bar between both panels.
---
 tools/grilo-test-ui/main.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/grilo-test-ui/main.c b/tools/grilo-test-ui/main.c
index e021eb1..f1901b9 100644
--- a/tools/grilo-test-ui/main.c
+++ b/tools/grilo-test-ui/main.c
@@ -1222,7 +1222,7 @@ ui_setup (void)
   gtk_container_add (GTK_CONTAINER (view->window), mainbox);
 
   /* Main layout */
-  GtkWidget *box = gtk_hbox_new (FALSE, 0);
+  GtkWidget *box = gtk_hpaned_new ();
   view->lpane = gtk_vbox_new (FALSE, 0);
   view->rpane = gtk_vbox_new (FALSE, 0);
   gtk_container_add (GTK_CONTAINER (mainbox), box);
-- 
1.7.1

From 5df5d9250bacd69b577c0e6df6d21b475092814d Mon Sep 17 00:00:00 2001
From: Xabier Rodriguez Calvar <xrcalvar igalia com>
Date: Tue, 8 Jun 2010 11:50:09 +0200
Subject: [PATCH 2/3] Fixed horizontal scroll of media list.

---
 tools/grilo-test-ui/main.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/tools/grilo-test-ui/main.c b/tools/grilo-test-ui/main.c
index f1901b9..88b9dec 100644
--- a/tools/grilo-test-ui/main.c
+++ b/tools/grilo-test-ui/main.c
@@ -1321,7 +1321,6 @@ ui_setup (void)
 				  GTK_POLICY_AUTOMATIC);
   view->browser = gtk_tree_view_new ();
   gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (view->browser), FALSE);
-  gtk_tree_view_set_fixed_height_mode (GTK_TREE_VIEW (view->browser), TRUE);
 
   gint i;
   GtkCellRenderer *col_renders[2];
@@ -1337,7 +1336,7 @@ ui_setup (void)
 					col_attributes[i],
 					col_model[i]);
   }
-  gtk_tree_view_column_set_sizing (col, GTK_TREE_VIEW_COLUMN_FIXED);
+  gtk_tree_view_column_set_sizing (col, GTK_TREE_VIEW_COLUMN_AUTOSIZE);
   gtk_tree_view_insert_column (GTK_TREE_VIEW (view->browser), col, -1);
 
   gtk_container_add (GTK_CONTAINER (scroll), view->browser);
-- 
1.7.1

From e3c70631a1d8e9d8775a43a70b30c2054bb8a810 Mon Sep 17 00:00:00 2001
From: Xabier Rodriguez Calvar <xrcalvar igalia com>
Date: Tue, 8 Jun 2010 11:50:32 +0200
Subject: [PATCH 3/3] Fixed horizontal scroll of metadata view.

---
 tools/grilo-test-ui/main.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/tools/grilo-test-ui/main.c b/tools/grilo-test-ui/main.c
index 88b9dec..ca1cf21 100644
--- a/tools/grilo-test-ui/main.c
+++ b/tools/grilo-test-ui/main.c
@@ -1369,7 +1369,6 @@ ui_setup (void)
 				  GTK_POLICY_AUTOMATIC);
   view->metadata = gtk_tree_view_new ();
   gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (view->metadata), FALSE);
-  gtk_tree_view_set_fixed_height_mode (GTK_TREE_VIEW (view->metadata), TRUE);
 
   GtkCellRenderer *col_renders_md[2];
   gchar *col_attributes_md[] = {"text", "text"};
@@ -1384,7 +1383,7 @@ ui_setup (void)
 					col_attributes_md[i],
 					col_model_md[i]);
   }
-  gtk_tree_view_column_set_sizing (col, GTK_TREE_VIEW_COLUMN_FIXED);
+  gtk_tree_view_column_set_sizing (col, GTK_TREE_VIEW_COLUMN_AUTOSIZE);
   gtk_tree_view_insert_column (GTK_TREE_VIEW (view->metadata), col, -1);
 
   gtk_container_add (GTK_CONTAINER (scroll_md), view->metadata);
-- 
1.7.1

Attachment: signature.asc
Description: Esta =?ISO-8859-1?Q?=E9?= unha parte de mensaxe asinada dixitalmente



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]