diff --git a/capplets/default-applications/ChangeLog b/capplets/default-applications/ChangeLog index 0e10bc336..6a21208f0 100644 --- a/capplets/default-applications/ChangeLog +++ b/capplets/default-applications/ChangeLog @@ -1,3 +1,7 @@ +2001-12-01 Richard Hestilow + + * Initial GNOME2 port. + 2001-08-18 Abel Cheung * interface.c (edit_create): Fixed a string (cut 'n paste is source diff --git a/capplets/default-applications/Makefile.am b/capplets/default-applications/Makefile.am index f4a539dc0..600fe32f0 100644 --- a/capplets/default-applications/Makefile.am +++ b/capplets/default-applications/Makefile.am @@ -2,7 +2,7 @@ cappletname = default-applications cappletgroup = bin_PROGRAMS = default-applications-properties -default_applications_properties_LDADD = $(GNOMECC_CAPPLETS_LIBS) +default_applications_properties_LDADD = @OLD_CAPPLET_LIBS@ default_applications_properties_SOURCES = \ default-application-properties.c \ interface.c interface.h \ @@ -28,7 +28,7 @@ install-data-local: install-data-am: install-data-local ####@###GNOMECC_CAPPLETS_DESKTOP_IN_RULE@ -INCLUDES = $(GNOMECC_CAPPLETS_CFLAGS) +INCLUDES = $(GNOMECC_CAPPLETS_CFLAGS) @OLD_CAPPLET_CFLAGS@ CLEANFILES = $(GNOMECC_CAPPLETS_CLEANFILES) EXTRA_DIST = $(GNOMECC_CAPPLETS_EXTRA_DIST) iconsdir = $(GNOMECC_ICONS_DIR) diff --git a/capplets/default-applications/support.c b/capplets/default-applications/support.c index c76f33308..0553fd691 100644 --- a/capplets/default-applications/support.c +++ b/capplets/default-applications/support.c @@ -124,23 +124,3 @@ create_pixmap (GtkWidget *widget, gdk_bitmap_unref (mask); return pixmap; } - -/* This is an internally used function to create imlib images. */ -GdkImlibImage* -create_image (const gchar *filename) -{ - GdkImlibImage *image; - gchar *pathname; - - pathname = gnome_pixmap_file (filename); - if (!pathname) - { - g_warning (_("Couldn't find pixmap file: %s"), filename); - return NULL; - } - - image = gdk_imlib_load_image (pathname); - g_free (pathname); - return image; -} - diff --git a/capplets/default-applications/support.h b/capplets/default-applications/support.h index d9bb0728a..486dae6a0 100644 --- a/capplets/default-applications/support.h +++ b/capplets/default-applications/support.h @@ -30,5 +30,3 @@ GtkWidget* create_pixmap (GtkWidget *widget, const gchar *filename, gboolean gnome_pixmap); -GdkImlibImage* create_image (const gchar *filename); - diff --git a/capplets/screensaver/ChangeLog b/capplets/screensaver/ChangeLog index 964c56f6d..6499a10b7 100644 --- a/capplets/screensaver/ChangeLog +++ b/capplets/screensaver/ChangeLog @@ -1,3 +1,7 @@ +2001-12-01 Richard Hestilow + + * Initial GNOME2 port. + 2001-10-18 Jakub Steiner * screensaver-capplet.png: fix the icon (bug #61522) diff --git a/capplets/screensaver/Makefile.am b/capplets/screensaver/Makefile.am index ca0000fe7..5a22b58ac 100644 --- a/capplets/screensaver/Makefile.am +++ b/capplets/screensaver/Makefile.am @@ -4,7 +4,7 @@ cappletname = screensaver cappletgroup = bin_PROGRAMS = screensaver-properties-capplet -screensaver_properties_capplet_LDADD = $(GNOMECC_CAPPLETS_LIBS) -lXt +screensaver_properties_capplet_LDADD = @OLD_CAPPLET_LIBS@ -lXt screensaver_properties_capplet_SOURCES = \ main.c \ prefs-widget.c prefs-widget.h\ @@ -17,6 +17,7 @@ screensaver_properties_capplet_SOURCES = \ daemon.c daemon.h\ rc-parse.c rc-parse.h\ resources.c resources.h\ + gnome-startup.c gnome-startup.h \ XScreenSaver_ad.h pixmaps_DATA = no-hack.png blank-screen.png @@ -37,7 +38,7 @@ install-data-local: install-data-am: install-data-local ####@###GNOMECC_CAPPLETS_DESKTOP_IN_RULE@ -INCLUDES = $(GNOMECC_CAPPLETS_CFLAGS) +INCLUDES = $(GNOMECC_CAPPLETS_CFLAGS) @OLD_CAPPLET_CFLAGS@ CLEANFILES = $(GNOMECC_CAPPLETS_CLEANFILES) EXTRA_DIST = $(GNOMECC_CAPPLETS_EXTRA_DIST) $(pixmaps_DATA) iconsdir = $(GNOMECC_ICONS_DIR) diff --git a/capplets/screensaver/gnome-startup.c b/capplets/screensaver/gnome-startup.c new file mode 100644 index 000000000..33c8e0652 --- /dev/null +++ b/capplets/screensaver/gnome-startup.c @@ -0,0 +1,45 @@ +/* gnome-startup.c - Functions for handling one-time startups in sessions. + Written by Tom Tromey . */ + +#include + +#include "gnome-startup.h" + +#include +#include +#include +#include + +gboolean +gnome_startup_acquire_token (const char *property, + const char *session_id) +{ + Atom atom, actual; + unsigned long nitems, nbytes; + unsigned char *current; + int len, format; + gboolean result; + + atom = XInternAtom (GDK_DISPLAY (), property, False); + len = strlen (session_id); + + /* Append our session id to the property. We do this to avoid a + race condition: if two clients run this code, we want to make + sure that only one client can acquire the lock. */ + XChangeProperty (GDK_DISPLAY (), DefaultRootWindow (GDK_DISPLAY ()), atom, + XA_STRING, 8, PropModeAppend, session_id, len); + + if (XGetWindowProperty (GDK_DISPLAY (), DefaultRootWindow (GDK_DISPLAY ()), + atom, 0, len, False, XA_STRING, + &actual, &format, + &nitems, &nbytes, ¤t) != Success) + current = NULL; + + if (! current) + return 0; + + result = ! strncmp (current, session_id, len); + XFree (current); + + return result; +} diff --git a/capplets/screensaver/gnome-startup.h b/capplets/screensaver/gnome-startup.h new file mode 100644 index 000000000..bb2708442 --- /dev/null +++ b/capplets/screensaver/gnome-startup.h @@ -0,0 +1,27 @@ +/* gnome-startup.h - Functions for handling one-time startups in sessions. + Written by Tom Tromey . */ + +#ifndef GNOME_STARTUP_H +#define GNOME_STARTUP_H + +#include +#include + +BEGIN_GNOME_DECLS + +/* This function is used by configurator programs that set some global + X server state. The general idea is that such a program can be run + in an `initialization' mode, where it sets the server state + according to some saved state. This function implements a mutex + for such programs. The mutex a property on the root window. Call + this function with the session manager's session id. If it returns + false, then do nothing. If it returns true, then the caller has + obtained the mutex and should proceed with initialization. The + property name is generally of the form GNOME__PROPERTY. */ + +gboolean gnome_startup_acquire_token (const gchar *property_name, + const gchar *sm_id); + +END_GNOME_DECLS + +#endif /* GNOME_STARTUP_H */ diff --git a/capplets/screensaver/main.c b/capplets/screensaver/main.c index 4a5559d77..169f9b1aa 100644 --- a/capplets/screensaver/main.c +++ b/capplets/screensaver/main.c @@ -28,9 +28,9 @@ #include #include #include -#include -#include -#include +#include +#include +#include #include #include diff --git a/capplets/screensaver/pref-file.c b/capplets/screensaver/pref-file.c index 6b11b94c8..dcf69111f 100644 --- a/capplets/screensaver/pref-file.c +++ b/capplets/screensaver/pref-file.c @@ -206,7 +206,7 @@ parse_config_file (const char *file_name) gint line_no; char *line, *key, *value; - if (!g_file_test (file_name, G_FILE_TEST_ISFILE)) + if (!g_file_test (file_name, G_FILE_TEST_IS_REGULAR)) return NULL; in = fopen (file_name, "r"); @@ -562,7 +562,7 @@ preferences_save_to_file (Preferences *prefs) be world-readable (so that the daemon, running as "nobody", will still be able to read it.) */ - if (g_file_test (name, G_FILE_TEST_ISFILE)) { + if (g_file_test (name, G_FILE_TEST_IS_REGULAR)) { mode_t mode = st.st_mode; mode |= S_IRUSR | S_IWUSR; /* read/write by user */ mode &= ~(S_IXUSR | S_IXGRP | S_IXOTH); /* executable by none */ diff --git a/capplets/screensaver/preferences.c b/capplets/screensaver/preferences.c index 4fb704015..820bfe60e 100644 --- a/capplets/screensaver/preferences.c +++ b/capplets/screensaver/preferences.c @@ -34,7 +34,7 @@ #include #include -#include +#include #include "preferences.h" #include "preview.h" @@ -435,7 +435,7 @@ xml_get_programs_list (xmlNodePtr programs_node) Screensaver *saver; gint id = 0; - for (node = programs_node->childs; node; node = node->next) { + for (node = programs_node->children; node; node = node->next) { saver = screensaver_read_xml (node); if (!saver) continue; saver->id = id++; @@ -462,7 +462,7 @@ preferences_read_xml (xmlDocPtr xml_doc) if (strcmp (root_node->name, "screensaver-prefs")) return NULL; - for (node = root_node->childs; node; node = node->next) { + for (node = root_node->children; node; node = node->next) { if (!strcmp (node->name, "verbose")) prefs->verbose = xml_read_bool (node); else if (!strcmp (node->name, "lock")) @@ -657,7 +657,7 @@ parse_arg_default (GString *s, xmlNodePtr node) g_string_append_c (s, ' '); g_string_append (s, arr[0]); g_string_append (s, val); - if (arr[1] && arg[2]) + if (arr[1] && arr[2]) g_string_append (s, arr[2]); } @@ -680,7 +680,7 @@ screensaver_read_xml (xmlNodePtr saver_node) args = g_string_new (saver->name); - for (node = saver_node->childs; node; node = node->next) { + for (node = saver_node->children; node; node = node->next) { if (!strcmp (node->name, "command-line")) saver->command_line = g_strdup (xmlNodeGetContent (node)); @@ -757,7 +757,7 @@ screensaver_new_from_file (const gchar *filename) if (!doc) return NULL; - node = doc->root; + node = doc->children; if (!node) { xmlFreeDoc (doc); diff --git a/capplets/screensaver/preferences.h b/capplets/screensaver/preferences.h index 0e320341e..e925a9865 100644 --- a/capplets/screensaver/preferences.h +++ b/capplets/screensaver/preferences.h @@ -26,7 +26,7 @@ #include #include -#include +#include enum _SelectionMode { SM_DISABLE_SCREENSAVER, diff --git a/capplets/screensaver/prefs-widget.c b/capplets/screensaver/prefs-widget.c index d11542b6a..4e6378019 100644 --- a/capplets/screensaver/prefs-widget.c +++ b/capplets/screensaver/prefs-widget.c @@ -149,8 +149,8 @@ guint prefs_widget_get_type (void) sizeof (PrefsWidgetClass), (GtkClassInitFunc) prefs_widget_class_init, (GtkObjectInitFunc) prefs_widget_init, - (GtkArgSetFunc) NULL, - (GtkArgGetFunc) NULL, + NULL, + NULL, }; prefs_widget_type = @@ -194,7 +194,7 @@ prefs_widget_init (PrefsWidget *prefs_widget) prefs_widget->priv = g_new0 (PrefsWidgetPrivate, 1); prefs_widget->priv->xml = glade_xml_new (GNOMECC_GLADE_DIR "/screensaver-properties.glade", - NULL); + NULL, NULL); if (!prefs_widget->priv->xml) return; @@ -328,7 +328,7 @@ prefs_widget_class_init (PrefsWidgetClass *class) prefs_widget_signals[STATE_CHANGED_SIGNAL] = gtk_signal_new ("pref-changed", GTK_RUN_FIRST, - object_class->type, + G_OBJECT_CLASS_TYPE (object_class), GTK_SIGNAL_OFFSET (PrefsWidgetClass, state_changed), gtk_signal_default_marshaller, @@ -336,15 +336,12 @@ prefs_widget_class_init (PrefsWidgetClass *class) prefs_widget_signals[ACTIVATE_DEMO_SIGNAL] = gtk_signal_new ("activate_demo", GTK_RUN_FIRST, - object_class->type, + G_OBJECT_CLASS_TYPE (object_class), GTK_SIGNAL_OFFSET (PrefsWidgetClass, activate_demo), gtk_signal_default_marshaller, GTK_TYPE_NONE, 0); - gtk_object_class_add_signals (object_class, prefs_widget_signals, - LAST_SIGNAL); - class->state_changed = NULL; object_class->destroy = prefs_widget_destroy; diff --git a/capplets/screensaver/preview.c b/capplets/screensaver/preview.c index 1e8ad0681..8af80dbb9 100644 --- a/capplets/screensaver/preview.c +++ b/capplets/screensaver/preview.c @@ -263,7 +263,7 @@ show_screensaver_timeout (void) gdk_pixbuf_unref (pixbuf); pixbuf = gdk_pixbuf_new_from_file - (GNOMECC_PIXMAPS_DIR "/no-hack.png"); + (GNOMECC_PIXMAPS_DIR "/no-hack.png", NULL); gdk_pixbuf_render_to_drawable (pixbuf, (GdkDrawable *) preview_window->window, preview_window->style->fg_gc[0], 0, 0, 0, 0, @@ -291,7 +291,7 @@ show_preview (Screensaver *saver) if (saver->fakepreview) { - pixbuf = gdk_pixbuf_new_from_file (saver->fakepreview); + pixbuf = gdk_pixbuf_new_from_file (saver->fakepreview, NULL); gdk_pixbuf_render_to_drawable (pixbuf, (GdkDrawable *) preview_window->window, preview_window->style->fg_gc[0], 0, 0, 0, 0, @@ -332,7 +332,7 @@ show_blank_preview (void) if (pixbuf) gdk_pixbuf_unref (pixbuf); - pixbuf = gdk_pixbuf_new_from_file (GNOMECC_PIXMAPS_DIR "/blank-screen.png"); + pixbuf = gdk_pixbuf_new_from_file (GNOMECC_PIXMAPS_DIR "/blank-screen.png", NULL); gdk_pixbuf_render_to_drawable (pixbuf, (GdkDrawable *) preview_window->window, preview_window->style->fg_gc[0], 0, 0, 0, 0, @@ -344,16 +344,7 @@ show_blank_preview (void) static GdkWindow * gdk_window_new_from_xwindow (Window xwindow) { - GdkWindow *window; - GdkWindowPrivate *window_priv; - - window_priv = g_new0 (GdkWindowPrivate, 1); - window = (GdkWindow *) window_priv; - window_priv->xdisplay = gdk_display; - window_priv->xwindow = xwindow; - window_priv->destroyed = FALSE; - - return window; + return gdk_window_foreign_new (xwindow); } static GdkWindow * diff --git a/capplets/screensaver/rc-parse.c b/capplets/screensaver/rc-parse.c index a7c207b40..398d5029e 100644 --- a/capplets/screensaver/rc-parse.c +++ b/capplets/screensaver/rc-parse.c @@ -230,7 +230,7 @@ get_screensaver_dir_list (void) while (fgets (buffer, 1024, in)) { buffer[strlen(buffer) - 1] = '\0'; - if (g_file_test (buffer, G_FILE_TEST_ISDIR)) { + if (g_file_test (buffer, G_FILE_TEST_IS_DIR)) { list_tail = g_list_append (NULL, g_strdup (buffer)); if (screensaver_dir_list == NULL) screensaver_dir_list = list_tail; @@ -264,7 +264,7 @@ rc_command_exists (char *command) /* If this is a complete path, then just stat it */ if (strchr (program, '/')) { - if (g_file_test (program, G_FILE_TEST_ISFILE)) + if (g_file_test (program, G_FILE_TEST_IS_REGULAR)) ret = TRUE; else ret = FALSE; @@ -280,7 +280,7 @@ rc_command_exists (char *command) for (node = screensaver_dir_list; node; node = node->next) { fullpath = g_concat_dir_and_file ((gchar *) node->data, program); - if (g_file_test (fullpath, G_FILE_TEST_ISFILE)) { + if (g_file_test (fullpath, G_FILE_TEST_IS_REGULAR)) { g_free (program); g_free (fullpath); return TRUE; diff --git a/capplets/screensaver/resources.c b/capplets/screensaver/resources.c index 25cb906fb..c583d7026 100644 --- a/capplets/screensaver/resources.c +++ b/capplets/screensaver/resources.c @@ -30,7 +30,7 @@ #include #include -#include +#include #include "resources.h" #include "rc-parse.h" diff --git a/capplets/screensaver/screensaver-prefs-dialog.c b/capplets/screensaver/screensaver-prefs-dialog.c index 91dd8eec9..e47f78772 100644 --- a/capplets/screensaver/screensaver-prefs-dialog.c +++ b/capplets/screensaver/screensaver-prefs-dialog.c @@ -26,12 +26,12 @@ #endif #include -#include +#include #include #include #include -#include +#include #include "screensaver-prefs-dialog.h" #include "preferences.h" @@ -157,8 +157,8 @@ screensaver_prefs_dialog_get_type (void) sizeof (ScreensaverPrefsDialogClass), (GtkClassInitFunc) screensaver_prefs_dialog_class_init, (GtkObjectInitFunc) screensaver_prefs_dialog_init, - (GtkArgSetFunc) NULL, - (GtkArgGetFunc) NULL + NULL, + NULL }; screensaver_prefs_dialog_type = @@ -233,7 +233,7 @@ screensaver_prefs_dialog_class_init (ScreensaverPrefsDialogClass *class) screensaver_prefs_dialog_signals[OK_CLICKED_SIGNAL] = gtk_signal_new ("ok-clicked", GTK_RUN_FIRST, - object_class->type, + G_OBJECT_CLASS_TYPE (object_class), GTK_SIGNAL_OFFSET (ScreensaverPrefsDialogClass, ok_clicked), gtk_signal_default_marshaller, @@ -241,16 +241,12 @@ screensaver_prefs_dialog_class_init (ScreensaverPrefsDialogClass *class) screensaver_prefs_dialog_signals[DEMO_SIGNAL] = gtk_signal_new ("demo", GTK_RUN_FIRST, - object_class->type, + G_OBJECT_CLASS_TYPE (object_class), GTK_SIGNAL_OFFSET (ScreensaverPrefsDialogClass, demo), gtk_signal_default_marshaller, GTK_TYPE_NONE, 0); - gtk_object_class_add_signals (object_class, - screensaver_prefs_dialog_signals, - LAST_SIGNAL); - object_class->destroy = (void (*) (GtkObject *)) screensaver_prefs_dialog_destroy; @@ -285,7 +281,7 @@ screensaver_prefs_dialog_new (Screensaver *saver) xmlDocGetRootElement (dialog->argument_doc); } - if (dialog->cli_args_db && dialog->argument_data && dialog->argument_data->childs && dialog->argument_data->childs->next) { + if (dialog->cli_args_db && dialog->argument_data && dialog->argument_data->children && dialog->argument_data->children->next) { settings_widget = get_screensaver_widget (dialog); } else { @@ -408,7 +404,7 @@ activate_option_cb (GtkWidget *widget) option_def = gtk_object_get_data (GTK_OBJECT (widget), "option_def"); select_data = gtk_object_get_data (GTK_OBJECT (widget), "select_data"); - node = select_data->childs; + node = select_data->children; while (node) { if (node != option_def) @@ -533,7 +529,7 @@ write_select (xmlNodePtr argument_data, GTree *widget_db) menu_item = GTK_MENU_SHELL (menu)->children; active = gtk_menu_get_active (GTK_MENU (menu)); - for (node = argument_data->childs; node && menu_item; + for (node = argument_data->children; node && menu_item; node = node->next) { if (!xmlGetProp (node, "id")) continue; @@ -593,9 +589,9 @@ write_command_line (gchar *name, xmlNodePtr argument_data, GTree *widget_db) gboolean free_v = FALSE; line = g_string_new (name); - node = argument_data->childs; + node = argument_data->children; - for (node = argument_data->childs; node; node = node->next) { + for (node = argument_data->children; node; node = node->next) { if (!strcmp (node->name, "boolean")) { arg = write_boolean (node, widget_db); free_v = FALSE; @@ -751,13 +747,13 @@ get_argument_data (Screensaver *saver) if (!doc) return NULL; - if (!(doc->root && doc->root->childs)) + if (!(doc->children && doc->children->children)) { xmlFreeDoc (doc); return NULL; } - for (node = doc->root->childs; node != NULL; node = node->next) + for (node = doc->children->children; node != NULL; node = node->next) { if (!strcmp (node->name, "select") || !strcmp (node->name, "number") @@ -903,7 +899,7 @@ get_select_widget (ScreensaverPrefsDialog *dialog, xmlNodePtr select_data, gtk_object_set_data (GTK_OBJECT (option_menu), "option_def", select_data); - for (node = select_data->childs; node; node = node->next) { + for (node = select_data->children; node; node = node->next) { option_str = xmlGetProp (node, "_label"); if (!option_str) continue; @@ -1186,7 +1182,7 @@ place_hgroup (ScreensaverPrefsDialog *dialog, hbox = gtk_hbox_new (FALSE, 5); - for (node = hgroup_data->childs; node; node = node->next) { + for (node = hgroup_data->children; node; node = node->next) { id = xmlGetProp (node, "id"); if (!id) continue; @@ -1296,7 +1292,7 @@ populate_table (ScreensaverPrefsDialog *dialog, GtkTable *table) g_return_if_fail (table != NULL); g_return_if_fail (GTK_IS_TABLE (table)); - for (node = dialog->argument_data->childs; node; node = node->next) { + for (node = dialog->argument_data->children; node; node = node->next) { id = xmlGetProp (node, "id"); if (!id && strcmp (node->name, "hgroup")) continue; @@ -1568,7 +1564,7 @@ read_select (GTree *widget_db, xmlNodePtr argument_data, /* Get the index of the selected option */ - for (node = argument_data->childs; node; node = node->next) { + for (node = argument_data->children; node; node = node->next) { if (!xmlGetProp (node, "id")) continue; found = arg_is_set (node, cli_db); @@ -1588,7 +1584,7 @@ read_select (GTree *widget_db, xmlNodePtr argument_data, i = 0; - for (node = argument_data->childs; node; node = node->next) { + for (node = argument_data->children; node; node = node->next) { if (!xmlGetProp (node, "id")) continue; if (i != set_idx) @@ -1600,7 +1596,7 @@ read_select (GTree *widget_db, xmlNodePtr argument_data, i = 0; - for (node = argument_data->childs; node; node = node->next) { + for (node = argument_data->children; node; node = node->next) { if (!xmlGetProp (node, "id")) continue; if (i == set_idx) { @@ -1656,7 +1652,7 @@ place_screensaver_properties (ScreensaverPrefsDialog *dialog, { xmlNodePtr node; - for (node = argument_data->childs; node; node = node->next) { + for (node = argument_data->children; node; node = node->next) { if (!strcmp (node->name, "boolean")) read_boolean (dialog->widget_db, node, dialog->cli_args_db); @@ -1738,6 +1734,8 @@ demo_cb (GtkWidget *widget, ScreensaverPrefsDialog *dialog) static void help_cb (GtkWidget *widget, ScreensaverPrefsDialog *dialog) { + /* I can't even find the current help... */ +#if 0 GnomeHelpMenuEntry entry; gchar *url; @@ -1756,6 +1754,7 @@ help_cb (GtkWidget *widget, ScreensaverPrefsDialog *dialog) gnome_url_show (url); g_free (url); } +#endif } static void diff --git a/capplets/screensaver/screensaver-prefs-dialog.h b/capplets/screensaver/screensaver-prefs-dialog.h index 1c29489a6..001cb5e22 100644 --- a/capplets/screensaver/screensaver-prefs-dialog.h +++ b/capplets/screensaver/screensaver-prefs-dialog.h @@ -25,7 +25,7 @@ #define __SCREENSAVER_PREFS_DIALOG_H #include -#include +#include #include #include "preferences.h" diff --git a/capplets/screensaver/screensaver-properties.glade b/capplets/screensaver/screensaver-properties.glade index 6439c3635..001c79a41 100644 --- a/capplets/screensaver/screensaver-properties.glade +++ b/capplets/screensaver/screensaver-properties.glade @@ -1,1005 +1,1041 @@ - - + + - - New-screensaver-properties - new-screensaver-properties - - src - - C - True - True - + + + no + About "<Screensaver name>" + GTK_WINDOW_TOPLEVEL + no + 308 + 285 + yes + yes + GTK_WIN_POS_NONE - - GnomeDialog - About <screensaver name> - False - About "<Screensaver name>" - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - 308 - 285 - True - True - False - True - True + + + no + 8 + yes + + + + GTK_BUTTONBOX_END + 8 + yes + + + + yes + yes + yes + gtk-ok + yes + yes + + + + + + yes + yes + yes + gtk-cancel + yes + yes + + + + + 0 + no + yes + GTK_PACK_END + + + + + + Draws quasiperiodic tilings; think of the implications on modern formica technology. Written by Time Korlove. In April 1997, Sir Roger Penrose, a British math professor who has worked with Stephen Hawking on such topics as relatvity, black holes, and whether time has a beginning, files a copyright-infringement lawsuit against Kimberly-Clark Corporation, wchih Penrose said copied a pattern he created ( apattern demonstrating that "a nonrepeating pattern could exist in nature") for its Kleenex quilted toilet paper. + GTK_JUSTIFY_RIGHT + yes + 7.45058e-09 + 0.5 + 4 + 4 + yes + + + 0 + no + no + + + + + 4 + yes + yes + + + + + no + Configure Power Management + GTK_WINDOW_TOPLEVEL + no + yes + yes + GTK_WIN_POS_NONE + + + + no + 8 + yes + + + + GTK_BUTTONBOX_END + 8 + yes + + + + yes + yes + yes + gtk-ok + yes + yes + + + + + + yes + yes + yes + gtk-cancel + yes + yes + + + + + 0 + no + yes + GTK_PACK_END + + + + + + 3 + no + 3 + 3 + 3 + 3 + yes + + + + yes + Go to standby mode after + no + yes + yes + + + 0 + 1 + 0 + 1 + 0 + 0 + fill + + + + + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 1 0 100 1 10 10 + + + 1 + 2 + 0 + 1 + 0 + 0 + + + + + + + + minutes + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 0 + 1 + 0 + 0 + fill + + + + + + + yes + Go to suspend mode after + no + yes + yes + + + 0 + 1 + 1 + 2 + 0 + 0 + fill + + + + + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 1 0 100 1 10 10 + + + 1 + 2 + 1 + 2 + 0 + 0 + + + + + + + + minutes + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 1 + 2 + 0 + 0 + fill + + + + + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 1 0 100 1 10 10 + + + 1 + 2 + 2 + 3 + 0 + 0 + + + + + + + + yes + Shut down monitor after + no + yes + yes + + + 0 + 1 + 2 + 3 + 0 + 0 + fill + + + + + + + minutes + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 2 + 3 + 0 + 0 + fill + + + + + + 0 + yes + yes + + + + + 4 + yes + yes + + + + + no + Settings for "<Screensaver name>" + GTK_WINDOW_TOPLEVEL + no + 302 + 257 + yes + yes + GTK_WIN_POS_NONE + + + + no + 8 + yes + + + + GTK_BUTTONBOX_END + 8 + yes + + + + yes + yes + yes + gtk-ok + yes + yes + + + + + + yes + yes + yes + gtk-cancel + yes + yes + + + + + 0 + no + yes + GTK_PACK_END + + + + + + There are no configurable settings for this +screensaver. + GTK_JUSTIFY_CENTER + yes + 0.5 + 0 + 0 + 0 + yes + + + 0 + yes + no + + + + + 4 + yes + yes + + + + + no - - GtkVBox - GnomeDialog:vbox - dialog-vbox3 - False - 8 - 4 - True - True + + yes + + + + + + gtk-new + yes + + + + + + _Add + 0.0 + yes + yes + + + - - GtkHButtonBox - GnomeDialog:action_area - dialog-action_area3 - GTK_BUTTONBOX_END - 8 - 85 - 27 - 7 - 0 - - 0 - False - True - GTK_PACK_END - - - - GtkButton - button42 - True - True - GNOME_STOCK_BUTTON_OK - - - - GtkButton - button44 - True - True - GNOME_STOCK_BUTTON_CANCEL - - - - - GtkLabel - label64 - - GTK_JUSTIFY_RIGHT - True - 7.45058e-09 - 0.5 - 4 - 4 - - 0 - False - False - - - - - - - GnomeDialog - pwr_conf_dialog - False - Configure Power Management - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - True - True - False - False - False - - - GtkVBox - GnomeDialog:vbox - dialog-vbox4 - False - 8 - 4 - True - True + + yes + + + + + + gtk-pref + yes + + + + + + _Settings + 0.0 + yes + yes + + + - - GtkHButtonBox - GnomeDialog:action_area - dialog-action_area4 - GTK_BUTTONBOX_END - 8 - 85 - 27 - 7 - 0 - - 0 - False - True - GTK_PACK_END - - - - GtkButton - button45 - True - True - GNOME_STOCK_BUTTON_OK - - - - GtkButton - button47 - True - True - GNOME_STOCK_BUTTON_CANCEL - - - - - GtkTable - table14 - 3 - 3 - 3 - False - 3 - 3 - - 0 - True - True - - - - GtkCheckButton - pwr_standby_enable - True - - False - True - - 0 - 1 - 0 - 1 - 0 - 0 - False - False - False - False - True - False - - - - - GtkSpinButton - pwr_standby_entry - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 1 - 0 - 100 - 1 - 10 - 10 - - 1 - 2 - 0 - 1 - 0 - 0 - False - False - False - False - False - False - - - - - GtkLabel - label67 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 0 - 1 - 0 - 0 - False - False - False - False - True - False - - - - - GtkCheckButton - pwr_suspend_enable - True - - False - True - - 0 - 1 - 1 - 2 - 0 - 0 - False - False - False - False - True - False - - - - - GtkSpinButton - pwr_suspend_entry - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 1 - 0 - 100 - 1 - 10 - 10 - - 1 - 2 - 1 - 2 - 0 - 0 - False - False - False - False - False - False - - - - - GtkLabel - label66 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 1 - 2 - 0 - 0 - False - False - False - False - True - False - - - - - GtkSpinButton - pwr_shutdown_entry - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 1 - 0 - 100 - 1 - 10 - 10 - - 1 - 2 - 2 - 3 - 0 - 0 - False - False - False - False - False - False - - - - - GtkCheckButton - pwr_shutdown_enable - True - - False - True - - 0 - 1 - 2 - 3 - 0 - 0 - False - False - False - False - True - False - - - - - GtkLabel - label65 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 2 - 3 - 0 - 0 - False - False - False - False - True - False - - - - - - - - GnomeDialog - Setting->no options example - False - Settings for "<Screensaver name>" - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - 302 - 257 - True - True - False - False - False - - - GtkVBox - GnomeDialog:vbox - dialog-vbox5 - False - 8 - 4 - True - True + + yes + + + + + + _Remove + 0.0 + yes + yes + + + - - GtkHButtonBox - GnomeDialog:action_area - dialog-action_area5 - GTK_BUTTONBOX_END - 8 - 85 - 27 - 7 - 0 - - 0 - False - True - GTK_PACK_END - - - - GtkButton - button48 - True - True - GNOME_STOCK_BUTTON_OK + + + yes + - - GtkButton - button50 - True - True - GNOME_STOCK_BUTTON_CANCEL + + + yes + + + + + + gnome-stock-about + yes + + + + + + _About this screensaver... + 0.0 + yes + yes + + - - - - GtkLabel - label68 - - GTK_JUSTIFY_CENTER - True - 0.5 - 0 - 0 - 0 - - 0 - True - False - - + - + + no + window1 + GTK_WINDOW_TOPLEVEL + no + no + yes + GTK_WIN_POS_NONE - - GtkMenu - popup_menu - False + + + no + 3 + 3 + 3 + 2 + yes - - GtkPixmapMenuItem - popup_add - - activate - on_add1_activate - Thu, 28 Jun 2001 16:18:44 GMT - - - False - GNOME_STOCK_MENU_NEW - + + + no + 0 + yes - - GtkPixmapMenuItem - popup_settings - - activate - on_settings1_activate - Thu, 28 Jun 2001 16:18:44 GMT - - - False - GNOME_STOCK_MENU_PREF - + + + no + 0 + yes - - GtkMenuItem - popup_remove - - activate - on_remove1_activate - Thu, 28 Jun 2001 16:18:44 GMT - - - False - + + + 3 + no + 3 + 1 + 2 + 3 + yes - - GtkMenuItem - separator1 - False - + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 10 0 100 1 10 10 + + + 1 + 2 + 0 + 1 + 0 + 0 + + + + - - GtkPixmapMenuItem - popup_about - - activate - on_about_this_screensaver1_activate - Thu, 28 Jun 2001 16:46:14 GMT - - - False - GNOME_STOCK_MENU_ABOUT - - + + + minutes + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 0 + 1 + 0 + 0 + fill + + + - - GtkWindow - throwaway_window - False - window1 - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - False - True - False + + + minutes + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 1 + 2 + 0 + 0 + fill + + + - - GtkTable - prefs_widget - 3 - 2 - False - 3 - 3 + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 10 0 100 1 10 10 + + + 1 + 2 + 1 + 2 + 0 + 0 + + + + - - GtkHBox - hbox25 - False - 0 - - 0 - 2 - 2 - 3 - 0 - 0 - False - False - False - False - True - True - + + + S_tart screensaver after + GTK_JUSTIFY_LEFT + no + 0 + 0.5 + 0 + 0 + timeout_widget + yes + yes + + + 0 + 1 + 0 + 1 + 0 + 0 + fill + + + - - GtkVBox - vbox14 - False - 0 - - 0 - False - False - + + + S_witch screensavers after + GTK_JUSTIFY_LEFT + no + 0 + 0.5 + 0 + 0 + cycle_length_widget + yes + yes + + + 0 + 1 + 1 + 2 + 0 + 0 + fill + + + + + + 0 + no + no + + + + + 0 + no + no + + - - GtkTable - table13 - 3 - 2 - 3 - False - 3 - 1 - - 0 - False - False - + + + yes + + + 6 + yes + yes + + - - GtkSpinButton - timeout_widget - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 10 - 0 - 100 - 1 - 10 - 10 - - 1 - 2 - 0 - 1 - 0 - 0 - False - False - False - False - False - False - - + + + 7.45058e-09 + 7.45058e-09 + 1 + 0 + yes - - GtkLabel - label55 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 0 - 1 - 0 - 0 - False - False - False - False - True - False - - + + + no + 0 + yes - - GtkLabel - label56 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 1 - 2 - 0 - 0 - False - False - False - False - True - False - - + + + yes + R_equire password to unlock screen + no + yes + yes + yes + + + 0 + no + no + + - - GtkSpinButton - cycle_length_widget - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 10 - 0 - 100 - 1 - 10 - 10 - - 1 - 2 - 1 - 2 - 0 - 0 - False - False - False - False - False - False - - + + + no + 0 + yes - - GtkLabel - label57 - - GTK_JUSTIFY_LEFT - False - 0 - 0.5 - 0 - 0 - timeout_widget - - 0 - 1 - 0 - 1 - 0 - 0 - False - False - False - False - True - False - - + + + yes + Enable _power management + no + yes + yes + yes + + + 0 + no + no + + - - GtkLabel - label58 - - GTK_JUSTIFY_LEFT - False - 0 - 0.5 - 0 - 0 - cycle_length_widget - - 0 - 1 - 1 - 2 - 0 - 0 - False - False - False - False - True - False - - - + + + yes + Configure... + GTK_RELIEF_NORMAL + yes + + + 0 + no + no + + + + + 0 + no + no + + + + + + + 0 + yes + yes + + + + + 0 + 2 + 2 + 3 + 0 + 0 + fill + fill + + + + + + Preview + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 300 + 200 + yes + + + + + 1 + 2 + 0 + 2 + 0 + 0 + + + + + + + + 4 + no + 4 + yes + + + + no + 0 + yes + + + + _Mode: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + mode_option + yes + yes + + + 0 + no + no + + + + + + yes + yes + 2 + + + + yes + + + + yes + + + + Disable screensaver + 0.0 + yes + yes + + + + + + + + yes + + + + Black screen only + 0.0 + yes + yes + + + + + + + + yes + + + + One screensaver all the time + 0.0 + yes + yes + + + + + + + + yes + + + + Random (checked screensavers) + 0.0 + yes + yes + + + + + + + + yes + + + + Random (all screensavers) + 0.0 + yes + yes + + + + + + + + + 0 + no + no + + + + + 0 + no + no + + + + + + GTK_POLICY_AUTOMATIC + GTK_POLICY_AUTOMATIC + yes + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + 0 + yes + yes + + + + + 0 + 1 + 0 + 2 + 0 + 0 + fill + fill + + - - - GtkVSeparator - vseparator4 - - 6 - True - True - - - - - GtkAlignment - alignment4 - 7.45058e-09 - 7.45058e-09 - 1 - 0 - - 0 - True - True - - - - GtkVBox - vbox15 - False - 0 - - - GtkCheckButton - lock_widget - True - - False - True - - 0 - False - False - - - - - GtkHBox - hbox26 - False - 0 - - 0 - False - False - - - - GtkCheckButton - pwr_manage_enable - True - - False - True - - 0 - False - False - - - - - GtkButton - pwr_conf_button - True - - GTK_RELIEF_NORMAL - - 0 - False - False - - - - - - - - - GtkFrame - frame5 - - 0 - GTK_SHADOW_ETCHED_IN - - 1 - 2 - 0 - 2 - 0 - 0 - False - False - False - False - False - False - - - - GtkDrawingArea - preview_window - 300 - 200 - - - - - GtkVBox - vbox16 - 4 - False - 4 - - 0 - 1 - 0 - 2 - 0 - 0 - False - False - False - False - True - True - - - - GtkHBox - hbox27 - False - 0 - - 0 - False - False - - - - GtkLabel - label54 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - mode_option - - 0 - False - False - - - - - GtkOptionMenu - mode_option - True - Disable screensaver -Black screen only -One screensaver all the time -Random (checked screensavers) -Random (all screensavers) - - 2 - - 0 - False - False - - - - - - GtkScrolledWindow - etable_scrolled - GTK_POLICY_AUTOMATIC - GTK_POLICY_AUTOMATIC - GTK_UPDATE_CONTINUOUS - GTK_UPDATE_CONTINUOUS - - 0 - True - True - - - - Placeholder - - - + - - - + diff --git a/capplets/screensaver/selection-dialog.c b/capplets/screensaver/selection-dialog.c index 98c6d5283..d45758d4e 100644 --- a/capplets/screensaver/selection-dialog.c +++ b/capplets/screensaver/selection-dialog.c @@ -32,7 +32,7 @@ #include #include -#include +#include #include "selection-dialog.h" #include "preferences.h" @@ -78,8 +78,8 @@ selection_dialog_get_type (void) sizeof (SelectionDialogClass), (GtkClassInitFunc) selection_dialog_class_init, (GtkObjectInitFunc) selection_dialog_init, - (GtkArgSetFunc) NULL, - (GtkArgGetFunc) NULL + NULL, + NULL }; selection_dialog_type = @@ -143,16 +143,12 @@ selection_dialog_class_init (SelectionDialogClass *class) selection_dialog_signals[OK_CLICKED_SIGNAL] = gtk_signal_new ("ok-clicked", GTK_RUN_FIRST, - object_class->type, + G_OBJECT_CLASS_TYPE (object_class), GTK_SIGNAL_OFFSET (SelectionDialogClass, ok_clicked), gtk_marshal_NONE__POINTER, GTK_TYPE_NONE, 1, GTK_TYPE_POINTER); - gtk_object_class_add_signals (object_class, - selection_dialog_signals, - LAST_SIGNAL); - known_savers = get_known_savers (); class->ok_clicked = NULL; diff --git a/capplets/screensaver/selection-dialog.h b/capplets/screensaver/selection-dialog.h index f672cf93b..2487057a0 100644 --- a/capplets/screensaver/selection-dialog.h +++ b/capplets/screensaver/selection-dialog.h @@ -26,7 +26,7 @@ #define __SELECTION_DIALOG_H #include -#include +#include #include "prefs-widget.h"