summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBertrand Jacquin <beber@meleeweb.net>2009-05-06 00:06:18 +0200
committerBertrand Jacquin <beber@meleeweb.net>2009-05-06 00:06:18 +0200
commitcfb315ae1578a7f49a44b22efa468eec90503a5f (patch)
treeba945e5d1ce1a311525dc7e44ae598988c59b6c8
parentcurl: patch for 2.0.4 for gnutls issue (diff)
downloadpatches-cfb315ae1578a7f49a44b22efa468eec90503a5f.tar.gz
enlightenemnt: Add C-D erase in desklock
-rw-r--r--enlightenment/e17_desklock_flush_on_ctrl-u.diff53
1 files changed, 53 insertions, 0 deletions
diff --git a/enlightenment/e17_desklock_flush_on_ctrl-u.diff b/enlightenment/e17_desklock_flush_on_ctrl-u.diff
new file mode 100644
index 0000000..ed82460
--- /dev/null
+++ b/enlightenment/e17_desklock_flush_on_ctrl-u.diff
@@ -0,0 +1,53 @@
+--- src/bin/e_desklock.c.ori 2008-05-13 21:14:52.000000000 +0200
++++ src/bin/e_desklock.c 2008-05-13 22:56:39.000000000 +0200
+@@ -72,6 +72,7 @@
+ static int _e_desklock_cb_custom_desklock_exit(void *data, int type, void *event);
+ static int _e_desklock_cb_idle_poller(void *data);
+
++static void _e_desklock_null(void);
+ static void _e_desklock_passwd_update(void);
+ static void _e_desklock_backspace(void);
+ static void _e_desklock_delete(void);
+@@ -423,6 +424,8 @@
+ _e_desklock_backspace();
+ else if (!strcmp(ev->keysymbol, "Delete"))
+ _e_desklock_delete();
++ else if (!strcmp(ev->keysymbol, "u") && (ev->modifiers & ECORE_X_MODIFIER_CTRL))
++ _e_desklock_null();
+ else
+ {
+ /* here we have to grab a password */
+@@ -506,6 +509,13 @@
+ }
+
+ static void
++_e_desklock_null(void)
++{
++ memset(edd->passwd, 0, sizeof(char) * PASSWD_LEN);
++ _e_desklock_passwd_update();
++}
++
++static void
+ _e_desklock_backspace(void)
+ {
+ int len, val, pos;
+@@ -578,8 +588,7 @@
+ #endif
+ /* password is definitely wrong */
+ _e_desklock_state_set(E_DESKLOCK_STATE_INVALID);
+- memset(edd->passwd, 0, sizeof(char) * PASSWD_LEN);
+- _e_desklock_passwd_update();
++ _e_desklock_null();
+ return 0;
+ }
+
+@@ -647,8 +656,7 @@
+ {
+ _e_desklock_state_set(E_DESKLOCK_STATE_INVALID);
+ /* security - null out passwd string once we are done with it */
+- memset(edd->passwd, 0, sizeof(char) * PASSWD_LEN);
+- _e_desklock_passwd_update();
++ _e_desklock_null();
+ }
+ ecore_event_handler_del(_e_desklock_exit_handler);
+ _e_desklock_exit_handler = NULL;