[libwnck] TestTaskList: add option to draw the test in vertical mode



commit f78bebd42ab6484ccb80aa8304803ab2d68ed8c2
Author: Marco Trevisan (TreviƱo) <mail 3v1n0 net>
Date:   Sat Jul 20 01:17:03 2013 +0200

    TestTaskList: add option to draw the test in vertical mode

 libwnck/test-tasklist.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/libwnck/test-tasklist.c b/libwnck/test-tasklist.c
index e76a62e..5e5d1fe 100644
--- a/libwnck/test-tasklist.c
+++ b/libwnck/test-tasklist.c
@@ -9,6 +9,7 @@ static gboolean always_group = FALSE;
 static gboolean rtl = FALSE;
 static gboolean skip_tasklist = FALSE;
 static gboolean transparent = FALSE;
+static gboolean vertical = FALSE;
 
 static GOptionEntry entries[] = {
        {"always-group", 'g', 0, G_OPTION_ARG_NONE, &always_group, "Always group windows", NULL},
@@ -16,6 +17,7 @@ static GOptionEntry entries[] = {
        {"display-all", 'a', 0, G_OPTION_ARG_NONE, &display_all, "Display windows from all workspaces", NULL},
        {"rtl", 'r', 0, G_OPTION_ARG_NONE, &rtl, "Use RTL as default direction", NULL},
        {"skip-tasklist", 's', 0, G_OPTION_ARG_NONE, &skip_tasklist, "Don't show window in tasklist", NULL},
+       {"vertical", 'v', 0, G_OPTION_ARG_NONE, &vertical, "Show in vertical mode", NULL},
        {"transparent", 't', 0, G_OPTION_ARG_NONE, &transparent, "Enable Transparency", NULL},
        {NULL }
 };
@@ -97,6 +99,10 @@ main (int argc, char **argv)
 
   wnck_tasklist_set_middle_click_close (WNCK_TASKLIST (tasklist), TRUE);
 
+  wnck_tasklist_set_orientation (WNCK_TASKLIST (tasklist),
+                                 (vertical ? GTK_ORIENTATION_VERTICAL :
+                                             GTK_ORIENTATION_HORIZONTAL));
+
   if (transparent)
     {
       GdkVisual *visual;


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