4
#include <glib/gi18n.h>
6
#include "cc-wacom-page.h"
7
#include "gsd-wacom-device.h"
9
#define FIXED_WIDTH 675
12
cc_wacom_panel_switch_to_panel (CcWacomPanel *self, const char *panel)
14
g_message ("Should launch display preferences here");
18
add_page (GList *devices,
22
GsdWacomDevice *stylus, *eraser, *pad;
28
stylus = eraser = pad = NULL;
29
for (l = devices; l ; l = l->next) {
30
switch (gsd_wacom_device_get_device_type (l->data)) {
31
case WACOM_TYPE_ERASER:
34
case WACOM_TYPE_STYLUS:
45
g_list_free (devices);
47
widget = cc_wacom_page_new (NULL, stylus, eraser, pad);
48
cc_wacom_page_set_navigation (CC_WACOM_PAGE (widget), GTK_NOTEBOOK (notebook), FALSE);
49
gtk_notebook_append_page (GTK_NOTEBOOK (notebook), widget, NULL);
50
gtk_widget_show (widget);
54
delete_event_cb (GtkWidget *widget,
63
int main (int argc, char **argv)
65
GtkWidget *window, *notebook;
68
bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
69
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
70
textdomain (GETTEXT_PACKAGE);
72
gtk_init (&argc, &argv);
74
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
75
gtk_window_set_resizable (GTK_WINDOW (window), FALSE);
76
gtk_widget_set_size_request (window, FIXED_WIDTH, -1);
77
g_signal_connect (G_OBJECT (window), "delete-event",
78
G_CALLBACK (delete_event_cb), NULL);
79
notebook = gtk_notebook_new ();
80
gtk_notebook_set_show_tabs (GTK_NOTEBOOK (notebook), FALSE);
81
gtk_widget_set_vexpand (notebook, TRUE);
82
gtk_container_set_border_width (GTK_CONTAINER (notebook), 24);
83
gtk_container_add (GTK_CONTAINER (window), notebook);
84
gtk_widget_show (notebook);
86
devices = gsd_wacom_device_create_fake_intuos4 ();
87
add_page (devices, notebook);
89
devices = gsd_wacom_device_create_fake_cintiq ();
90
add_page (devices, notebook);
92
devices = gsd_wacom_device_create_fake_bt ();
93
add_page (devices, notebook);
95
devices = gsd_wacom_device_create_fake_x201 ();
96
add_page (devices, notebook);
98
gtk_widget_show (window);