aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbalrog <balrog@c046a42c-6fe2-441c-8c8c-71466251a162>2008-06-09 00:03:47 +0000
committerbalrog <balrog@c046a42c-6fe2-441c-8c8c-71466251a162>2008-06-09 00:03:47 +0000
commitf227f17d1b4f21b681c94efce859b9094482b7e6 (patch)
treec08cd2a2a7cdeb51db47e6a156ecee9e1da97684
parent88d2c950b002a3976cd5673b0214006e72cae191 (diff)
downloadqemu-f227f17d1b4f21b681c94efce859b9094482b7e6.zip
qemu-f227f17d1b4f21b681c94efce859b9094482b7e6.tar.gz
qemu-f227f17d1b4f21b681c94efce859b9094482b7e6.tar.bz2
Fix the sendkey hold time calculation (Jan Kiszka).
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4703 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--monitor.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/monitor.c b/monitor.c
index 002fc02..1eb8be1 100644
--- a/monitor.c
+++ b/monitor.c
@@ -982,8 +982,8 @@ static void do_sendkey(const char *string, int has_hold_time, int hold_time)
kbd_put_keycode(keycode & 0x7f);
}
/* delayed key up events */
- qemu_mod_timer(key_timer,
- qemu_get_clock(vm_clock) + ticks_per_sec * hold_time);
+ qemu_mod_timer(key_timer, qemu_get_clock(vm_clock) +
+ muldiv64(ticks_per_sec, hold_time, 1000));
}
static int mouse_button_state;