Revision 63066f4f vl.h
b/vl.h | ||
---|---|---|
179 | 179 |
#define BIOS_SIZE 0 |
180 | 180 |
#endif |
181 | 181 |
|
182 |
/* keyboard/mouse support */ |
|
183 |
|
|
184 |
#define MOUSE_EVENT_LBUTTON 0x01 |
|
185 |
#define MOUSE_EVENT_RBUTTON 0x02 |
|
186 |
#define MOUSE_EVENT_MBUTTON 0x04 |
|
187 |
|
|
188 |
typedef void QEMUPutKBDEvent(void *opaque, int keycode); |
|
189 |
typedef void QEMUPutMouseEvent(void *opaque, int dx, int dy, int dz, int buttons_state); |
|
190 |
|
|
191 |
void qemu_add_kbd_event_handler(QEMUPutKBDEvent *func, void *opaque); |
|
192 |
void qemu_add_mouse_event_handler(QEMUPutMouseEvent *func, void *opaque); |
|
193 |
|
|
194 |
void kbd_put_keycode(int keycode); |
|
195 |
void kbd_mouse_event(int dx, int dy, int dz, int buttons_state); |
|
196 |
|
|
182 | 197 |
/* async I/O support */ |
183 | 198 |
|
184 | 199 |
typedef void IOReadHandler(void *opaque, const uint8_t *buf, int size); |
... | ... | |
530 | 545 |
|
531 | 546 |
/* pckbd.c */ |
532 | 547 |
|
533 |
void kbd_put_keycode(int keycode); |
|
534 |
|
|
535 |
#define MOUSE_EVENT_LBUTTON 0x01 |
|
536 |
#define MOUSE_EVENT_RBUTTON 0x02 |
|
537 |
#define MOUSE_EVENT_MBUTTON 0x04 |
|
538 |
void kbd_mouse_event(int dx, int dy, int dz, int buttons_state); |
|
539 |
|
|
540 | 548 |
void kbd_init(void); |
541 | 549 |
|
542 | 550 |
/* mc146818rtc.c */ |
... | ... | |
627 | 635 |
uint32_t initrd_image, uint32_t initrd_size, |
628 | 636 |
uint32_t NVRAM_image); |
629 | 637 |
|
638 |
/* adb.c */ |
|
639 |
|
|
640 |
#define MAX_ADB_DEVICES 16 |
|
641 |
|
|
642 |
typedef struct ADBDevice ADBDevice; |
|
643 |
|
|
644 |
typedef void ADBDeviceReceivePacket(ADBDevice *d, const uint8_t *buf, int len); |
|
645 |
|
|
646 |
struct ADBDevice { |
|
647 |
struct ADBBusState *bus; |
|
648 |
int devaddr; |
|
649 |
int handler; |
|
650 |
ADBDeviceReceivePacket *receive_packet; |
|
651 |
void *opaque; |
|
652 |
}; |
|
653 |
|
|
654 |
typedef struct ADBBusState { |
|
655 |
ADBDevice devices[MAX_ADB_DEVICES]; |
|
656 |
int nb_devices; |
|
657 |
} ADBBusState; |
|
658 |
|
|
659 |
void adb_receive_packet(ADBBusState *s, const uint8_t *buf, int len); |
|
660 |
void adb_send_packet(ADBBusState *s, const uint8_t *buf, int len); |
|
661 |
|
|
662 |
ADBDevice *adb_register_device(ADBBusState *s, int devaddr, |
|
663 |
ADBDeviceReceivePacket *receive_packet, |
|
664 |
void *opaque); |
|
665 |
void adb_kbd_init(ADBBusState *bus); |
|
666 |
void adb_mouse_init(ADBBusState *bus); |
|
667 |
|
|
668 |
/* cuda.c */ |
|
669 |
|
|
670 |
extern ADBBusState adb_bus; |
|
671 |
int cuda_init(void); |
|
672 |
|
|
630 | 673 |
/* monitor.c */ |
631 | 674 |
void monitor_init(void); |
632 | 675 |
void term_printf(const char *fmt, ...) __attribute__ ((__format__ (__printf__, 1, 2))); |
Also available in: Unified diff