--- xfdesktop4-4.6.1.orig/common/xfdesktop-common.h 2009-12-19 14:01:05.000000000 -0800 +++ xfdesktop4-4.6.1/common/xfdesktop-common.h 2009-12-19 15:54:17.000000000 -0800 @@ -37,6 +37,7 @@ #define DEFAULT_ICON_SIZE 32 #define LIST_TEXT "# xfce backdrop list" + #define XFDESKTOP_SELECTION_FMT "XFDESKTOP_SELECTION_%d" #define XFDESKTOP_IMAGE_FILE_FMT "XFDESKTOP_IMAGE_FILE_%d" @@ -44,6 +45,8 @@ #define MENU_MESSAGE "menu" #define WINDOWLIST_MESSAGE "windowlist" #define QUIT_MESSAGE "quit" +#define RESIZE_MESSAGE "resizeyes" +#define NORESIZE_MESSAGE "resizeno" G_BEGIN_DECLS --- xfdesktop4-4.6.1.orig/src/main.c 2009-12-19 14:01:05.000000000 -0800 +++ xfdesktop4-4.6.1/src/main.c 2009-12-19 15:54:17.000000000 -0800 @@ -62,6 +62,7 @@ static SessionClient *client_session = NULL; static gboolean is_session_managed = FALSE; +gboolean xfdesktop_noresize = FALSE; static void session_logout(void) @@ -188,6 +189,12 @@ } gtk_main_quit(); return TRUE; + } else if(!strcmp(RESIZE_MESSAGE, evt->data.b)) { + xfdesktop_noresize = FALSE; + return TRUE; + } else if(!strcmp(NORESIZE_MESSAGE, evt->data.b)) { + xfdesktop_noresize = TRUE; + return TRUE; } } @@ -224,6 +231,7 @@ gboolean already_running; gchar buf[1024]; GError *error = NULL; + gboolean grid_message = FALSE; /* bind gettext textdomain */ xfce_textdomain(GETTEXT_PACKAGE, LOCALEDIR, "UTF-8"); @@ -286,6 +294,13 @@ message = QUIT_MESSAGE; else if(!strcmp("--sm-client-id", argv[1])) { /* do nothing */ + } else if(!strcmp("-resize", argument)) { + message = RESIZE_MESSAGE; + grid_message = TRUE; + } else if(!strcmp("-noresize", argument)) { + message = NORESIZE_MESSAGE; + xfdesktop_noresize = TRUE; + grid_message = TRUE; } else { g_printerr(_("%s: Unknown option: %s\n"), PACKAGE, argv[1]); g_printerr(_("Options are:\n")); @@ -311,6 +326,16 @@ g_print("%s[%d]: starting up\n", PACKAGE, getpid()); + /* If resize/noresize was passed, send message if already running. + Otherwise, just clear message as we're not doing anything with it */ + if(grid_message) { + if(already_running) { + xfdesktop_send_client_message(xid, message); + return 0; + } + message = NULL; + } + if(message) { if(!already_running) g_printerr(_("%s is not running.\n"), PACKAGE); --- xfdesktop4-4.6.1.orig/src/xfdesktop-icon-view.c 2009-12-19 14:01:05.000000000 -0800 +++ xfdesktop4-4.6.1/src/xfdesktop-icon-view.c 2009-12-19 16:02:53.000000000 -0800 @@ -2299,6 +2299,9 @@ static void xfdesktop_grid_do_resize(XfdesktopIconView *icon_view) { + /* If we disabled resizing, short-circuit the whole thing. */ + if(xfdesktop_noresize) return; + GList *l, *leftovers = NULL; /* move all icons into the pending_icons list */ --- xfdesktop4-4.6.1.orig/src/xfdesktop-icon-view.h 2009-12-19 14:01:05.000000000 -0800 +++ xfdesktop4-4.6.1/src/xfdesktop-icon-view.h 2009-12-19 16:00:01.000000000 -0800 @@ -56,6 +56,8 @@ void (*icon_activated)(XfdesktopIconView *icon_view); }; +extern gboolean xfdesktop_noresize; + GType xfdesktop_icon_view_get_type() G_GNUC_CONST; GtkWidget *xfdesktop_icon_view_new(XfdesktopIconViewManager *manager); Only in xfdesktop4: xfdesktop.spec