diff options
author | Daniel Friesel <derf@finalrewind.org> | 2012-01-27 20:23:03 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2012-01-27 20:23:03 +0100 |
commit | 4252f6eb96ef00d5907dceda3af8c581917d7aa1 (patch) | |
tree | 7850c29f32d7bbb2be61d865b2900f24c7d54eb7 /src/keyevents.c | |
parent | f32e4f8b3876b5cf063b92fa8988a7bda3672795 (diff) |
optional exif support (build with exif=1), initial patch import
Diffstat (limited to 'src/keyevents.c')
-rw-r--r-- | src/keyevents.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/keyevents.c b/src/keyevents.c index 873e114..0ada751 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -136,6 +136,9 @@ void init_keyevents(void) { feh_set_kb(&keys.toggle_actions, 0, XK_a, 0, 0, 0, 0); feh_set_kb(&keys.toggle_aliasing, 0, XK_A, 0, 0, 0, 0); feh_set_kb(&keys.toggle_filenames, 0, XK_d, 0, 0, 0, 0); +#ifdef HAVE_LIBEXIF + feh_set_kb(&keys.toggle_exif, 0, XK_e, 0, 0, 0, 0); +#endif feh_set_kb(&keys.toggle_info, 0, XK_i, 0, 0, 0, 0); feh_set_kb(&keys.toggle_pointer, 0, XK_o, 0, 0, 0, 0); feh_set_kb(&keys.toggle_caption, 0, XK_c, 0, 0, 0, 0); @@ -270,6 +273,10 @@ void init_keyevents(void) { cur_kb = &keys.toggle_aliasing; else if (!strcmp(action, "toggle_filenames")) cur_kb = &keys.toggle_filenames; +#ifdef HAVE_LIBEXIF + else if (!strcmp(action, "toggle_exif")) + cur_kb = &keys.toggle_exif; +#endif else if (!strcmp(action, "toggle_info")) cur_kb = &keys.toggle_info; else if (!strcmp(action, "toggle_pointer")) @@ -628,6 +635,12 @@ void feh_event_handle_keypress(XEvent * ev) opt.draw_filename = !opt.draw_filename; winwidget_rerender_all(0); } +#ifdef HAVE_LIBEXIF + else if (feh_is_kp(&keys.toggle_exif, keysym, state)) { + opt.draw_exif = !opt.draw_exif; + winwidget_rerender_all(0); + } +#endif else if (feh_is_kp(&keys.toggle_info, keysym, state)) { opt.draw_info = !opt.draw_info; winwidget_rerender_all(0); |