}
}
-
+#ifdef UI_MOTIF
+static UIWIDGET create_motif_listview(UiObject *obj, UiWidgetArgs *args, void *userdata, Widget parent, Arg *a, int n) {
+ MainWindow *window = userdata;
+
+ Widget w = CreateSidebar(parent, "sidebar", a, n);
+ SidebarSetWindow(w, window);
+
+ return w;
+}
+#endif
MainWindow* WindowCreate(Display *display) {
Arg args[32];
// TODO: enable when the motif splitpane is implemented in the toolkit
/*
- ui_vsplitpane(obj, .value = window->splitview) {
+ ui_vsplitpane(obj, .value = window->splitview, .fill = TRUE) {
window->player_widget = ui_drawingarea(obj, .width = 400, .height = 200);
UIWIDGET listview = ui_listview(obj, .varname = "playlist");
ui_widget_set_visibility_states(obj->ctx, listview, UI_GROUPS(APP_STATES_SHOW_SIDEBAR), 1);
}
*/
+ ui_hbox(obj, .fill = TRUE) {
+ window->player_widget = ui_drawingarea(obj, .width = 400, .height = 200);
+
+#ifndef UI_MOTIF
+ window->listview = ui_listview(obj, .varname = "playlist", .width = 300);
+#else
+ ui_scrolledwindow_w(obj, window->listview_scrolledwindow, 0) {
+ window->listview = ui_customwidget(obj, create_motif_listview, window);
+ }
+#endif
+ }
// toplevel window
n = 0;