int max_x, max_y;
struct sdl2_console *scon = get_scon_from_window(ev->key.windowID);
+ if (!qemu_console_is_graphic(scon->dcl.con)) {
+ return;
+ }
+
if (qemu_input_is_absolute() || absolute_enabled) {
int scr_w, scr_h;
SDL_GetWindowSize(scon->real_window, &scr_w, &scr_h);
SDL_MouseButtonEvent *bev;
struct sdl2_console *scon = get_scon_from_window(ev->key.windowID);
+ if (!qemu_console_is_graphic(scon->dcl.con)) {
+ return;
+ }
+
bev = &ev->button;
if (!gui_grab && !qemu_input_is_absolute()) {
if (ev->type == SDL_MOUSEBUTTONUP && bev->button == SDL_BUTTON_LEFT) {
SDL_MouseWheelEvent *wev = &ev->wheel;
InputButton btn;
+ if (!qemu_console_is_graphic(scon->dcl.con)) {
+ return;
+ }
+
if (wev->y > 0) {
btn = INPUT_BUTTON_WHEEL_UP;
} else if (wev->y < 0) {
int x, int y, int on)
{
struct sdl2_console *scon = container_of(dcl, struct sdl2_console, dcl);
+
+ if (!qemu_console_is_graphic(scon->dcl.con)) {
+ return;
+ }
+
if (on) {
if (!guest_cursor) {
sdl_show_cursor();