application/main.c

changeset 119
d7a7fb79b5f7
parent 118
bb21210e9cac
child 120
49bc645df8b7
--- a/application/main.c	Wed Jan 27 12:10:42 2016 +0100
+++ b/application/main.c	Wed Jan 27 12:52:39 2016 +0100
@@ -60,6 +60,7 @@
 
 void action_scroll(UiEvent *event, void *data) {
     ui_drawingarea_redraw(drawingarea);
+    printf("scroll\n");
 }
 
 void draw(UiEvent *event, UiGraphics *g, void *data) {
@@ -142,6 +143,8 @@
 ///*
     ui_hbox(obj);
     
+//*
+    ui_vbox(obj);
     drawingarea = ui_drawingarea(obj, draw, NULL);
     ctxmenu = ui_contextmenu_w(obj, drawingarea);
     ui_widget_menuitem(obj, "Test1", NULL, NULL);
@@ -149,10 +152,12 @@
     ui_widget_menuitem(obj, "Test3", NULL, NULL);
     ui_widget_menuitem(obj, "Test4", NULL, NULL);
     ui_drawingarea_mousehandler(obj, drawingarea, click, NULL);
+    ui_end(obj);
+//*/
     
     ui_vscrollbar(obj, &range, action_scroll, NULL);
-    range.setrange(&range, 0, 400);
-    range.setextent(&range, 1);
+    range.setrange(&range, 0, 100);
+    range.setextent(&range, 20);
     range.set(&range, 0);
     
     ui_end(obj);

mercurial