forked from enlightenment/efl
oops.. ok.. NOw damn jeybindings work.. silly mistake.. fixed :)
SVN revision: 4389
This commit is contained in:
parent
edeb6ec6da
commit
9b8423bacd
|
@ -115,6 +115,7 @@ e_ev_x_init(void)
|
||||||
e_key_grab("Num_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
e_key_grab("Num_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
||||||
e_key_grab("Scroll_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
e_key_grab("Scroll_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
||||||
e_key_grab("Caps_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
e_key_grab("Caps_Lock", EV_KEY_MODIFIER_NONE, 1, 1);
|
||||||
|
*/
|
||||||
current_lock = e_modifier_mask_get();
|
current_lock = e_modifier_mask_get();
|
||||||
if (current_lock & lock_mask_scroll)
|
if (current_lock & lock_mask_scroll)
|
||||||
e_lock_scroll_set(1);
|
e_lock_scroll_set(1);
|
||||||
|
@ -130,7 +131,6 @@ e_ev_x_init(void)
|
||||||
e_mod_alt_set(1);
|
e_mod_alt_set(1);
|
||||||
if (current_lock & mod_mask_win)
|
if (current_lock & mod_mask_win)
|
||||||
e_mod_win_set(1);
|
e_mod_win_set(1);
|
||||||
*/
|
|
||||||
e_add_event_fd(e_x_get_fd(), e_ev_x_handle_events);
|
e_add_event_fd(e_x_get_fd(), e_ev_x_handle_events);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1160,19 +1160,14 @@ e_key_grab(char *key, Ev_Key_Modifiers mods, int anymod, int sync)
|
||||||
mode = GrabModeSync;
|
mode = GrabModeSync;
|
||||||
if (!grabkey_win)
|
if (!grabkey_win)
|
||||||
grabkey_win = default_root;
|
grabkey_win = default_root;
|
||||||
if (!grabkey_win)
|
|
||||||
{
|
|
||||||
grabkey_win = e_window_override_new(0, -1, -1, 1, 1);
|
|
||||||
e_window_show(grabkey_win);
|
|
||||||
}
|
|
||||||
if (mods & EV_KEY_MODIFIER_SHIFT)
|
if (mods & EV_KEY_MODIFIER_SHIFT)
|
||||||
mod |= mod_shift;
|
mod |= e_mod_mask_shift_get();
|
||||||
if (mods & EV_KEY_MODIFIER_CTRL)
|
if (mods & EV_KEY_MODIFIER_CTRL)
|
||||||
mod |= mod_ctrl;
|
mod |= e_mod_mask_ctrl_get();
|
||||||
if (mods & EV_KEY_MODIFIER_ALT)
|
if (mods & EV_KEY_MODIFIER_ALT)
|
||||||
mod |= mod_alt;
|
mod |= e_mod_mask_alt_get();
|
||||||
if (mods & EV_KEY_MODIFIER_WIN)
|
if (mods & EV_KEY_MODIFIER_WIN)
|
||||||
mod |= mod_win;
|
mod |= e_mod_mask_win_get();
|
||||||
mask_scroll = e_lock_mask_scroll_get();
|
mask_scroll = e_lock_mask_scroll_get();
|
||||||
mask_num = e_lock_mask_num_get();
|
mask_num = e_lock_mask_num_get();
|
||||||
mask_caps = e_lock_mask_caps_get();
|
mask_caps = e_lock_mask_caps_get();
|
||||||
|
@ -1185,12 +1180,12 @@ e_key_grab(char *key, Ev_Key_Modifiers mods, int anymod, int sync)
|
||||||
masks[6] = mask_num | mask_caps;
|
masks[6] = mask_num | mask_caps;
|
||||||
masks[7] = mask_scroll | mask_num | mask_caps;
|
masks[7] = mask_scroll | mask_num | mask_caps;
|
||||||
if (anymod)
|
if (anymod)
|
||||||
XGrabKey(disp, keycode, AnyModifier, grabkey_win, False, mode, mode);
|
XGrabKey(disp, keycode, AnyModifier, grabkey_win, False, mode, mode);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
for (i = 0; i < 8; i++)
|
for (i = 0; i < 8; i++)
|
||||||
XGrabKey(disp, keycode, masks[i] | mod, grabkey_win, False,
|
XGrabKey(disp, keycode, masks[i] | mod, grabkey_win, False,
|
||||||
mode, mode);
|
mode, mode);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1208,13 +1203,13 @@ e_key_ungrab(char *key, Ev_Key_Modifiers mods, int anymod)
|
||||||
|
|
||||||
mod = 0;
|
mod = 0;
|
||||||
if (mods & EV_KEY_MODIFIER_SHIFT)
|
if (mods & EV_KEY_MODIFIER_SHIFT)
|
||||||
mod |= mod_shift;
|
mod |= e_mod_mask_shift_get();
|
||||||
if (mods & EV_KEY_MODIFIER_CTRL)
|
if (mods & EV_KEY_MODIFIER_CTRL)
|
||||||
mod |= mod_ctrl;
|
mod |= e_mod_mask_ctrl_get();
|
||||||
if (mods & EV_KEY_MODIFIER_ALT)
|
if (mods & EV_KEY_MODIFIER_ALT)
|
||||||
mod |= mod_alt;
|
mod |= e_mod_mask_alt_get();
|
||||||
if (mods & EV_KEY_MODIFIER_WIN)
|
if (mods & EV_KEY_MODIFIER_WIN)
|
||||||
mod |= mod_win;
|
mod |= e_mod_mask_win_get();
|
||||||
mask_scroll = e_lock_mask_scroll_get();
|
mask_scroll = e_lock_mask_scroll_get();
|
||||||
mask_num = e_lock_mask_num_get();
|
mask_num = e_lock_mask_num_get();
|
||||||
mask_caps = e_lock_mask_caps_get();
|
mask_caps = e_lock_mask_caps_get();
|
||||||
|
|
Loading…
Reference in New Issue