On 12/18/2006 08:30, Ravenlock wrote:
On 12/17/2006 19:55, Ravenlock wrote:
On 12/17/2006 10:00, Ravenlock wrote:
Hello,
Hoping for comments on the attached patch.
The patch will add "Advanced" features to the Configuration Panel ->
Screen -> Screen Lock panel. You can choose to override the "Lock
Screen" functionality of E, and/or the E Screensaver with a "Custom
Screensaver" which can be any executable you choose.
A slight update.
The only notable changes:
1) I've changed the config dialog to use minutes in stead of seconds.
2) Changed the range from 10 min max (600 seconds) to 90 minutes max.
3) bumped the E_CONFIG_FILE_GENERATION from 0x105 to 0x106
Final update until/unless there is some feedback. There may be no
interest in this though I find it useful.
Notable changes:
1) IPC code in place
2) Fixed memory leak wrt _e_config_free()
Regards.
Ok... really done this time... for now. I think this will suffice as a
first shot. (or is it my forth?)
Either way, this last patch handles the X screensaver a bit better. I
think the functionality included in the patch will do what you would
think it should.
Basically, you now can specify a single application that will respond
when you
- "Lock Screen" from the menu
- Use the "Desktop Lock" keybinding
- "Enable Screensaver" from the config panel.
So... take a look. Comments welcome. Please don't forget to get the
shell script as well (prev post). I do not keep xscreensaver running..
I use the script to launch it and shut it down. Saves a few bytes of
ram. Might be useful.
Now, after doing this. I've come to the conclusion that a much better
job could be done. I could build a new configurator for the screensaver
itself. Seperate the desklock and the screensaver. That way in the
screensaver configuration, you could tweak the actual X screensaver
settings (timeout, cycletime, blank, expose) as well as DPMS settings.
And I could create seperate overrides, one for the desklock and one for
the screensaver. Just an idea.
But I think what I have now might suffice for a while.
Let me know what you think.
Because of the E_CONFIG_FILE_GENERATION bump... please backup your E
config dir (just in case). I had something odd happen in the last
24hrs (lost my config), and I'd hate for my patch to be responsible.
I changed the max timeout because, while I feel 10 min is an
appropriate timeout (for me)... seems a bit restrictive. So I up'd it
a bit.
Regards.
This is handy (I think). There have been some issues with PAM, while
this is no fix for that... it does offer a suitable workaround.
Especially for those of us who would choose to use things like
xscreensaver in the first place.
Yes, you can say "well just disable E's" and configure xscreensaver.
But it was annoying to me that I could not "reconfigure" the lock
function to use <insert_fav_screensaver_here>. And this makes the E
interface feel a little more consistent, in the sense that now I can
use the menu "Lock Scree" option, or keybindings to activate the
screensaver app of my choosing.
So, you can get a little creative with it. If you keep xscreensaver
up and running , you might choose to use 'xscreensaver-command -lock'
as your custom saver. This will lock the screen when you tell it to
(using xscreensaver). Or (using the also attached script)... you
could not run xscreensaver as a daemon, choose to use E's
screensaver, override it using the new custom option, and allow E to
manage the timer which starts xscreensaver.
The GUI changes I've made are a bit suspect as there are conditional
compilations (ifdef HAVE_PAM) that may affect the location of GUI
components. if some who does not HAVE_PAM could comment, that would
be great too.
Anyway, I was hoping someone could give it a try and comment.
------------------------------------------------------------------------
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to
share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
------------------------------------------------------------------------
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
--
Regards,
Ravenlock
Index: e17/libs/ecore/src/lib/ecore_x/Ecore_X.h
===================================================================
RCS file: /var/cvs/e/e17/libs/ecore/src/lib/ecore_x/Ecore_X.h,v
retrieving revision 1.178
diff -u -r1.178 Ecore_X.h
--- e17/libs/ecore/src/lib/ecore_x/Ecore_X.h 13 Dec 2006 19:47:17 -0000
1.178
+++ e17/libs/ecore/src/lib/ecore_x/Ecore_X.h 19 Dec 2006 04:12:52 -0000
@@ -1367,6 +1367,12 @@
EAPI int ecore_x_screensaver_event_available_get(void);
EAPI void ecore_x_screensaver_timeout_set(double timeout);
EAPI double ecore_x_screensaver_timeout_get(void);
+EAPI void ecore_x_screensaver_blank_set(double timeout);
+EAPI double ecore_x_screensaver_blank_get(void);
+EAPI void ecore_x_screensaver_expose_set(double timeout);
+EAPI double ecore_x_screensaver_expose_get(void);
+EAPI void ecore_x_screensaver_interval_set(double timeout);
+EAPI double ecore_x_screensaver_interval_get(void);
EAPI void ecore_x_screensaver_event_listen_set(int on);
/* FIXME: these funcs need categorising */
Index: e17/libs/ecore/src/lib/ecore_x/ecore_x_screensaver.c
===================================================================
RCS file: /var/cvs/e/e17/libs/ecore/src/lib/ecore_x/ecore_x_screensaver.c,v
retrieving revision 1.4
diff -u -r1.4 ecore_x_screensaver.c
--- e17/libs/ecore/src/lib/ecore_x/ecore_x_screensaver.c 5 Nov 2006
15:14:49 -0000 1.4
+++ e17/libs/ecore/src/lib/ecore_x/ecore_x_screensaver.c 19 Dec 2006
04:12:52 -0000
@@ -23,7 +23,7 @@
{
int pto, pint, pblank, pexpo;
- XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
XSetScreenSaver(_ecore_x_disp, (int)timeout,
pint, pblank, pexpo);
}
@@ -38,6 +38,63 @@
}
EAPI void
+ecore_x_screensaver_blank_set(double blank)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ XSetScreenSaver(_ecore_x_disp, pto,
+ pint, (int)blank, pexpo);
+}
+
+EAPI double
+ecore_x_screensaver_blank_get(void)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ return (double)pblank;
+}
+
+EAPI void
+ecore_x_screensaver_expose_set(double expose)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ XSetScreenSaver(_ecore_x_disp, pto,
+ pint, pblank, (int)expose);
+}
+
+EAPI double
+ecore_x_screensaver_expose_get(void)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ return (double)pexpo;
+}
+
+EAPI void
+ecore_x_screensaver_interval_set(double interval)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ XSetScreenSaver(_ecore_x_disp, pto,
+ (int)interval, pblank, pexpo);
+}
+
+EAPI double
+ecore_x_screensaver_interval_get(void)
+{
+ int pto, pint, pblank, pexpo;
+
+ XGetScreenSaver(_ecore_x_disp, &pto, &pint, &pblank, &pexpo);
+ return (double)pint;
+}
+
+EAPI void
ecore_x_screensaver_event_listen_set(int on)
{
#ifdef ECORE_XSS
Index: e17/apps/e/src/bin/e_config.c
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_config.c,v
retrieving revision 1.218
diff -u -r1.218 e_config.c
--- e17/apps/e/src/bin/e_config.c 17 Dec 2006 11:24:59 -0000 1.218
+++ e17/apps/e/src/bin/e_config.c 19 Dec 2006 04:17:27 -0000
@@ -478,6 +478,8 @@
E_CONFIG_VAL(D, T, desklock_use_timeout, INT);
E_CONFIG_VAL(D, T, desklock_timeout, DOUBLE);
E_CONFIG_VAL(D, T, desklock_disable_screensaver, INT);
+ E_CONFIG_VAL(D, T, desklock_use_custom_screensaver, INT);
+ E_CONFIG_VAL(D, T, desklock_custom_screensaver_cmd, STR);
E_CONFIG_VAL(D, T, display_res_restore, INT);
E_CONFIG_VAL(D, T, display_res_width, INT);
E_CONFIG_VAL(D, T, display_res_height, INT);
@@ -1282,6 +1284,12 @@
e_config->remember_internal_windows = 1;
IFCFGEND;
+
+ IFCFG(0x00106);
+ e_config->desklock_use_custom_screensaver = 0;
+ e_config->desklock_custom_screensaver_cmd = NULL;
+ IFCFGEND;
+
#if 0 /* example of new config */
IFCFG(0x0090); /* the version # where this value(s) was introduced */
e_config->new_value = 10; /* set the value(s) */
@@ -1366,8 +1374,9 @@
E_CONFIG_LIMIT(e_config->desklock_login_box_zone, -2, 1000);
E_CONFIG_LIMIT(e_config->desklock_autolock, 0, 1);
E_CONFIG_LIMIT(e_config->desklock_use_timeout, 0, 1);
- E_CONFIG_LIMIT(e_config->desklock_timeout, 1.0, 600.0);
+ E_CONFIG_LIMIT(e_config->desklock_timeout, 1.0, 5400.0);
E_CONFIG_LIMIT(e_config->desklock_disable_screensaver, 0, 1);
+ E_CONFIG_LIMIT(e_config->desklock_use_custom_screensaver, 0, 1);
E_CONFIG_LIMIT(e_config->display_res_restore, 0, 1);
E_CONFIG_LIMIT(e_config->display_res_width, 1, 8192);
E_CONFIG_LIMIT(e_config->display_res_height, 1, 8192);
@@ -1966,6 +1975,7 @@
if (e_config->wallpaper_import_last_dev)
evas_stringshare_del(e_config->wallpaper_import_last_dev);
if (e_config->wallpaper_import_last_path)
evas_stringshare_del(e_config->wallpaper_import_last_path);
if (e_config->theme_default_border_style)
evas_stringshare_del(e_config->theme_default_border_style);
+ if (e_config->desklock_custom_screensaver_cmd)
evas_stringshare_del(e_config->desklock_custom_screensaver_cmd);
E_FREE(e_config);
}
}
Index: e17/apps/e/src/bin/e_config.h
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_config.h,v
retrieving revision 1.136
diff -u -r1.136 e_config.h
--- e17/apps/e/src/bin/e_config.h 17 Dec 2006 16:14:11 -0000 1.136
+++ e17/apps/e/src/bin/e_config.h 19 Dec 2006 04:17:28 -0000
@@ -52,7 +52,7 @@
/* increment this whenever a new set of config values are added but the users
* config doesn't need to be wiped - simply new values need to be put in
*/
-#define E_CONFIG_FILE_GENERATION 0x0105
+#define E_CONFIG_FILE_GENERATION 0x0106
#define E_CONFIG_FILE_VERSION ((E_CONFIG_FILE_EPOCH << 16) |
E_CONFIG_FILE_GENERATION)
#define E_EVAS_ENGINE_DEFAULT 0
@@ -231,7 +231,9 @@
int desklock_use_timeout; // GUI
double desklock_timeout; // GUI
int desklock_disable_screensaver; // GUI
-
+ int desklock_use_custom_screensaver; //GUI
+ const char *desklock_custom_screensaver_cmd; // GUI
+
int display_res_restore; // GUI
int display_res_width; // GUI
int display_res_height; // GUI
Index: e17/apps/e/src/bin/e_desklock.c
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_desklock.c,v
retrieving revision 1.28
diff -u -r1.28 e_desklock.c
--- e17/apps/e/src/bin/e_desklock.c 21 Oct 2006 02:32:13 -0000 1.28
+++ e17/apps/e/src/bin/e_desklock.c 19 Dec 2006 04:17:30 -0000
@@ -49,6 +49,8 @@
static Ecore_Event_Handler *_e_desklock_exit_handler = NULL;
static pid_t _e_desklock_child_pid = -1;
#endif
+static Ecore_Exe *_e_custom_saver_exe = NULL;
+static Ecore_Event_Handler *_e_custom_saver_exe_handler = NULL;
/***********************************************************************/
@@ -57,6 +59,7 @@
static int _e_desklock_cb_mouse_up(void *data, int type, void *event);
static int _e_desklock_cb_mouse_wheel(void *data, int type, void *event);
static int _e_desklock_cb_mouse_move(void *data, int type, void *event);
+static int _e_desklock_cb_custom_saver_exit(void *data, int type, void *event);
static void _e_desklock_passwd_update();
static void _e_desklock_backspace();
@@ -77,17 +80,25 @@
EAPI int
e_desklock_init(void)
{
+
if (e_config->desklock_disable_screensaver)
ecore_x_screensaver_timeout_set(0);
else
{
if (e_config->desklock_use_timeout)
- ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
+ ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
}
-
+
+ /*
+ * Effectively hide the X screensaver yet allow
+ * it to generate the timer events for us.
+ */
+ ecore_x_screensaver_blank_set(!e_config->desklock_use_custom_screensaver);
+ ecore_x_screensaver_expose_set(!e_config->desklock_use_custom_screensaver);
+
if (e_config->desklock_background)
e_filereg_register(e_config->desklock_background);
-
+
return 1;
}
@@ -110,9 +121,22 @@
E_Zone *current_zone;
int zone_counter;
int total_zone_num;
+
- if (edd) return 0;
+ if (_e_custom_saver_exe) return 0;
+
+ if (e_config->desklock_use_custom_screensaver)
+ {
+ _e_custom_saver_exe_handler =
ecore_event_handler_add(ECORE_EXE_EVENT_DEL,
+
_e_desklock_cb_custom_saver_exit,
+ NULL);
+ _e_custom_saver_exe =
ecore_exe_run(e_config->desklock_custom_screensaver_cmd, NULL);
+
+ return 1;
+ }
+ if (edd) return 0;
+
#ifdef HAVE_PAM
if (e_config->desklock_auth_method == 1)
{
@@ -323,8 +347,14 @@
{
E_Desklock_Popup_Data *edp;
- if (!edd) return;
+ if ((!edd) && (!_e_custom_saver_exe)) return;
+ if (e_config->desklock_use_custom_screensaver)
+ {
+ _e_custom_saver_exe = NULL;
+ return;
+ }
+
if (edd->elock_grab_break_wnd)
ecore_x_window_show(edd->elock_grab_break_wnd);
while (edd->elock_wnd_list)
@@ -735,3 +765,30 @@
return strdup("localhost");
}
#endif
+
+static int
+_e_desklock_cb_custom_saver_exit(void *data, int type, void *event)
+{
+ Ecore_Exe_Event_Del *ev;
+
+ ev = event;
+ if (ev->exe != _e_custom_saver_exe) return 1;
+
+ if (ev->exit_code != 0)
+ {
+ /* do something profound here... like notify someone */
+ }
+
+ /*
+ * Miserable HACK alert!!!
+ * Seems I must reset this. Some reason yet unknown, my
+ * intended values are getting reset!?!
+ */
+ ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
+ ecore_x_screensaver_blank_set(!e_config->desklock_use_custom_screensaver);
+ ecore_x_screensaver_expose_set(!e_config->desklock_use_custom_screensaver);
+
+ e_desklock_hide();
+
+ return 0;
+}
Index: e17/apps/e/src/bin/e_int_config_desklock.c
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_int_config_desklock.c,v
retrieving revision 1.43
diff -u -r1.43 e_int_config_desklock.c
--- e17/apps/e/src/bin/e_int_config_desklock.c 14 Dec 2006 19:42:21 -0000
1.43
+++ e17/apps/e/src/bin/e_int_config_desklock.c 19 Dec 2006 04:17:32 -0000
@@ -14,7 +14,6 @@
#define DEF_DESKLOCK_BACKGROUND "theme_desklock_background"
#define DEF_THEME_BACKGROUND "theme_background"
-
static void *_create_data(E_Config_Dialog *cfd);
static void _free_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata);
static int _basic_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data
*cfdata);
@@ -65,6 +64,9 @@
int specific_lb_zone; // local variable
int specific_lb_zone_backup; // used to have smart iface
+ int use_custom_screensaver;
+ char *custom_screensaver_cmd;
+
int zone_count; // local variable;
int bg_mode; // config
@@ -294,7 +296,7 @@
cfdata->autolock = e_config->desklock_autolock;
cfdata->use_timeout = e_config->desklock_use_timeout;
- cfdata->timeout = e_config->desklock_timeout;
+ cfdata->timeout = e_config->desklock_timeout / 60;
/* should be taken from e_config */
//cfdata->login_box_on_zone = -1;
@@ -351,6 +353,10 @@
cfdata->auth_method = e_config->desklock_auth_method;
#endif
+ cfdata->use_custom_screensaver = e_config->desklock_use_custom_screensaver;
+ if (e_config->desklock_custom_screensaver_cmd)
+ cfdata->custom_screensaver_cmd =
strdup(e_config->desklock_custom_screensaver_cmd);
+
//vertical_lb_align = e_config->desklock_login
}
@@ -389,14 +395,16 @@
e_config->desklock_personal_passwd =
evas_stringshare_add(cfdata->desklock_passwd_cp);
e_config->desklock_autolock = cfdata->autolock;
e_config->desklock_use_timeout = cfdata->use_timeout;
- e_config->desklock_timeout = cfdata->timeout;
+ e_config->desklock_timeout = cfdata->timeout * 60;
#ifdef HAVE_PAM
e_config->desklock_auth_method = cfdata->auth_method;
#endif
if (e_config->desklock_use_timeout)
- {
- ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
- }
+ ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
+
+ ecore_x_screensaver_blank_set(!e_config->desklock_use_custom_screensaver);
+ ecore_x_screensaver_expose_set(!e_config->desklock_use_custom_screensaver);
+
e_config_save_queue();
return 1;
}
@@ -465,8 +473,8 @@
ob = e_widget_label_add(evas, _("Time until screensaver starts"));
e_widget_disabled_set(ob, !ecore_x_screensaver_event_available_get());
e_widget_framelist_object_append(of, ob);
- ob = e_widget_slider_add(evas, 1, 0, _("%1.0f seconds"),
- 1.0, 600.0,
+ ob = e_widget_slider_add(evas, 1, 0, _("%1.0f minutes"),
+ 1.0, 90.0,
1.0, 0, &(cfdata->timeout), NULL,
200);
e_widget_framelist_object_append(of, ob);
@@ -515,14 +523,25 @@
e_config->desklock_autolock = cfdata->autolock;
e_config->desklock_use_timeout = cfdata->use_timeout;
- e_config->desklock_timeout = cfdata->timeout;
+ e_config->desklock_timeout = cfdata->timeout * 60;
#ifdef HAVE_PAM
e_config->desklock_auth_method = cfdata->auth_method;
#endif
if (e_config->desklock_use_timeout)
- ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
+ ecore_x_screensaver_timeout_set(e_config->desklock_timeout);
+
+ e_config->desklock_use_custom_screensaver = cfdata->use_custom_screensaver;
+ if (cfdata->custom_screensaver_cmd)
+ {
+ if (e_config->desklock_custom_screensaver_cmd)
+ evas_stringshare_del(e_config->desklock_custom_screensaver_cmd);
+ e_config->desklock_custom_screensaver_cmd =
evas_stringshare_add(cfdata->custom_screensaver_cmd);
+ }
+ ecore_x_screensaver_blank_set(!e_config->desklock_use_custom_screensaver);
+ ecore_x_screensaver_expose_set(!e_config->desklock_use_custom_screensaver);
+
e_config_save_queue();
return 1;
}
@@ -764,7 +783,7 @@
e_widget_disabled_set(of, !ecore_x_screensaver_event_available_get());
- ob = e_widget_check_add(evas, _("Enable screensaver"),
&(cfdata->use_timeout));
+ ob = e_widget_check_add(evas, _("Enable X screensaver"),
&(cfdata->use_timeout));
e_widget_disabled_set(ob, !ecore_x_screensaver_event_available_get());
e_widget_framelist_object_append(of, ob);
@@ -775,8 +794,8 @@
ob = e_widget_label_add(evas, _("Time until screensaver starts"));
e_widget_disabled_set(ob, !ecore_x_screensaver_event_available_get());
e_widget_framelist_object_append(of, ob);
- ob = e_widget_slider_add(evas, 1, 0, _("%1.0f seconds"),
- 1.0, 600.0,
+ ob = e_widget_slider_add(evas, 1, 0, _("%1.0f minutes"),
+ 1.0, 90.0,
1.0, 0, &(cfdata->timeout), NULL,
100);
e_widget_framelist_object_append(of, ob);
@@ -785,6 +804,23 @@
#else
e_widget_table_object_append(ot, of, 1, 2, 1, 1 ,1 ,1 ,1 ,1);
#endif
+
+ /*
+ * Allow Custom Screen Saver
+ * Useful, for example, for those of us who prefer
+ * to use things like xscreensaver, kscreesaver, etc...
+ */
+ of = e_widget_framelist_add(evas, _("Custom Screensaver"), 0);
+ ob = e_widget_check_add(evas, _("Use custom screensaver/desklock"),
+ &(cfdata->use_custom_screensaver));
+ e_widget_framelist_object_append(of, ob);
+ ob = e_widget_entry_add(evas, &(cfdata->custom_screensaver_cmd));
+ e_widget_framelist_object_append(of, ob);
+#ifdef HAVE_PAM
+ e_widget_table_object_append(ot, of, 0, 4, 2, 1, 1, 1, 1, 1);
+#else
+ e_widget_table_object_append(ot, of, 0, 4, 2, 1, 1, 1, 1, 1);
+#endif
e_dialog_resizable_set(cfd->dia, 0);
return ot;
Index: e17/apps/e/src/bin/e_ipc_handlers.h
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_ipc_handlers.h,v
retrieving revision 1.140
diff -u -r1.140 e_ipc_handlers.h
--- e17/apps/e/src/bin/e_ipc_handlers.h 17 Dec 2006 11:24:59 -0000 1.140
+++ e17/apps/e/src/bin/e_ipc_handlers.h 19 Dec 2006 04:17:44 -0000
@@ -7750,3 +7750,83 @@
END_INT;
#endif
#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_SET
+#if (TYPE == E_REMOTE_OPTIONS)
+ OP("-desklock-use-custom-screensaver-set", 1, "Set whether a custom
screensaver will be utilized", 0, HDL)
+#elif (TYPE == E_REMOTE_OUT)
+ REQ_INT(atoi(params[0]), HDL);
+#elif (TYPE == E_WM_IN)
+ START_INT(policy, HDL);
+ e_config->desklock_use_custom_screensaver = policy;
+ E_CONFIG_LIMIT(e_config->desklock_use_custom_screensaver, 0, 1);
+ SAVE;
+ END_INT;
+#elif (TYPE == E_REMOTE_IN)
+#endif
+#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_GET
+#if (TYPE == E_REMOTE_OPTIONS)
+ OP("-desklock-use-custom-screensaver-get", 0, "Get whether a custom screen
saver is being used", 1, HDL)
+#elif (TYPE == E_REMOTE_OUT)
+ REQ_NULL(HDL);
+#elif (TYPE == E_WM_IN)
+ SEND_INT(e_config->desklock_use_custom_screensaver,
E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_GET_REPLY, HDL);
+#elif (TYPE == E_REMOTE_IN)
+#endif
+#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_GET_REPLY
+#if (TYPE == E_REMOTE_OPTIONS)
+#elif (TYPE == E_REMOTE_OUT)
+#elif (TYPE == E_WM_IN)
+#elif (TYPE == E_REMOTE_IN)
+ START_INT(val, HDL);
+ printf("REPLY: POLICY=%d\n", val);
+ END_INT;
+#endif
+#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_SET
+#if (TYPE == E_REMOTE_OPTIONS)
+ OP("-desklock-custom-screensaver-cmd-set", 1, "Set the current custom
screensaver command to OPT1", 0, HDL)
+#elif (TYPE == E_REMOTE_OUT)
+ REQ_STRING(params[0], HDL);
+#elif (TYPE == E_WM_IN)
+ STRING(s, HDL);
+ if (e_config->desklock_custom_screensaver_cmd)
+ evas_stringshare_del(e_config->desklock_custom_screensaver_cmd);
+ e_config->desklock_custom_screensaver_cmd = evas_stringshare_add(s);
+ END_STRING(s);
+#elif (TYPE == E_REMOTE_IN)
+#endif
+#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_GET
+#if (TYPE == E_REMOTE_OPTIONS)
+ OP("-desklock-custom-screensaver-cmd-get", 0, "Get the current custom
screensaver command", 1, HDL)
+#elif (TYPE == E_REMOTE_OUT)
+ REQ_NULL(HDL);
+#elif (TYPE == E_WM_IN)
+ SEND_STRING(e_config->desklock_custom_screensaver_cmd,
E_IPC_OP_PROFILE_GET_REPLY, HDL);
+#elif (TYPE == E_REMOTE_IN)
+#endif
+#undef HDL
+
+/****************************************************************************/
+#define HDL E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_GET_REPLY
+#if (TYPE == E_REMOTE_OPTIONS)
+#elif (TYPE == E_REMOTE_OUT)
+#elif (TYPE == E_WM_IN)
+#elif (TYPE == E_REMOTE_IN)
+ STRING(s, HDL);
+ printf("REPLY: \"%s\"\n", s);
+ END_STRING(s);
+#endif
+#undef HDL
Index: e17/apps/e/src/bin/e_ipc_handlers_list.h
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_ipc_handlers_list.h,v
retrieving revision 1.52
diff -u -r1.52 e_ipc_handlers_list.h
--- e17/apps/e/src/bin/e_ipc_handlers_list.h 16 Dec 2006 21:28:46 -0000
1.52
+++ e17/apps/e/src/bin/e_ipc_handlers_list.h 19 Dec 2006 04:17:44 -0000
@@ -408,3 +408,10 @@
#define E_IPC_OP_REMEMBER_INTERNAL_WINDOWS_SET 372
#define E_IPC_OP_REMEMBER_INTERNAL_WINDOWS_GET 373
#define E_IPC_OP_REMEMBER_INTERNAL_WINDOWS_GET_REPLY 374
+
+#define E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_SET 375
+#define E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_GET 376
+#define E_IPC_OP_DESKLOCK_USE_CUSTOM_SCREENSAVER_GET_REPLY 377
+#define E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_SET 378
+#define E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_GET 379
+#define E_IPC_OP_DESKLOCK_CUSTOM_SCREENSAVER_CMD_GET_REPLY 380
Index: e17/apps/e/src/bin/e_manager.c
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_manager.c,v
retrieving revision 1.58
diff -u -r1.58 e_manager.c
--- e17/apps/e/src/bin/e_manager.c 28 Oct 2006 01:28:01 -0000 1.58
+++ e17/apps/e/src/bin/e_manager.c 19 Dec 2006 04:17:46 -0000
@@ -754,7 +754,8 @@
if (e->on)
{
- if (e_config->desklock_autolock) e_desklock_show();
+ if ((e_config->desklock_autolock) ||
(e_config->desklock_use_custom_screensaver))
+ e_desklock_show();
}
return 1;
}
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel