Lines Matching refs:ahid
287 struct adbhid *ahid = adbhid[id]; in adbhid_input_keycode() local
297 if (ahid->flags & FLAG_CAPSLOCK_IGNORE_NEXT) { in adbhid_input_keycode()
300 ahid->flags &= ~FLAG_CAPSLOCK_IGNORE_NEXT; in adbhid_input_keycode()
303 ahid->flags |= FLAG_CAPSLOCK_TRANSLATE in adbhid_input_keycode()
307 !(ahid->flags & FLAG_POWER_KEY_PRESSED)) { in adbhid_input_keycode()
311 if (ahid->flags & FLAG_CAPSLOCK_TRANSLATE) { in adbhid_input_keycode()
313 if (ahid->flags & FLAG_CAPSLOCK_DOWN) { in adbhid_input_keycode()
316 ahid->flags &= ~FLAG_CAPSLOCK_DOWN; in adbhid_input_keycode()
320 ahid->flags &= ~FLAG_CAPSLOCK_TRANSLATE; in adbhid_input_keycode()
332 input_report_key(ahid->input, KEY_CAPSLOCK, 1); in adbhid_input_keycode()
333 input_sync(ahid->input); in adbhid_input_keycode()
334 input_report_key(ahid->input, KEY_CAPSLOCK, 0); in adbhid_input_keycode()
335 input_sync(ahid->input); in adbhid_input_keycode()
352 ahid->flags &= ~FLAG_POWER_KEY_PRESSED; in adbhid_input_keycode()
354 ahid->flags |= FLAG_POWER_KEY_PRESSED; in adbhid_input_keycode()
357 if (ahid->flags & FLAG_FN_KEY_PRESSED) { in adbhid_input_keycode()
360 ahid->flags &= ~FLAG_POWER_FROM_FN; in adbhid_input_keycode()
362 ahid->flags |= FLAG_POWER_FROM_FN; in adbhid_input_keycode()
363 } else if (ahid->flags & FLAG_POWER_FROM_FN) { in adbhid_input_keycode()
365 ahid->flags &= ~FLAG_POWER_FROM_FN; in adbhid_input_keycode()
371 ahid->flags &= ~FLAG_FN_KEY_PRESSED; in adbhid_input_keycode()
373 if (ahid->flags & FLAG_EMU_FWDEL_DOWN) { in adbhid_input_keycode()
374 ahid->flags &= ~FLAG_EMU_FWDEL_DOWN; in adbhid_input_keycode()
379 ahid->flags |= FLAG_FN_KEY_PRESSED; in adbhid_input_keycode()
383 if (ahid->flags & FLAG_FN_KEY_PRESSED) { in adbhid_input_keycode()
386 ahid->flags &= ~FLAG_EMU_FWDEL_DOWN; in adbhid_input_keycode()
388 ahid->flags |= FLAG_EMU_FWDEL_DOWN; in adbhid_input_keycode()
704 struct adbhid *ahid; in adbhid_kbd_capslock_remember() local
708 ahid = adbhid[i]; in adbhid_kbd_capslock_remember()
710 if (ahid && ahid->id == ADB_KEYBOARD) in adbhid_kbd_capslock_remember()
711 if (ahid->flags & FLAG_CAPSLOCK_TRANSLATE) in adbhid_kbd_capslock_remember()
712 ahid->flags |= FLAG_CAPSLOCK_IGNORE_NEXT; in adbhid_kbd_capslock_remember()