sdl: use mouse mode notifier

Today we poll the mouse mode whenever there is a mouse movement.  There is a
subtle usability problem with this though.

If we're in relative mode and grab is enabled, when we change to absolute mode,
we break grab.  This gives a user a seamless transition when the new pointer
is enabled.

But because we poll for mouse change, this grab break won't occur until the user
attempts to move the mouse.  By using notifiers, the grab break happens as soon
as possible.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
1 file changed
tree: 6c2856fe803e158f4e6083737757624a9388fb49
  1. audio/
  2. block/
  3. bsd-user/
  4. darwin-user/
  5. default-configs/
  6. docs/
  7. fpu/
  8. gdb-xml/
  9. hw/
  10. linux-user/
  11. net/
  12. pc-bios/
  13. QMP/
  14. roms/
  15. slirp/
  16. sysconfigs/
  17. target-alpha/
  18. target-arm/
  19. target-cris/
  20. target-i386/
  21. target-m68k/
  22. target-microblaze/
  23. target-mips/
  24. target-ppc/
  25. target-s390x/
  26. target-sh4/
  27. target-sparc/
  28. tcg/
  29. tests/
  30. .gitignore
  31. .gitmodules
  32. a.out.h
  33. acl.c
  34. acl.h
  35. aes.c
  36. aes.h
  37. aio.c
  38. alpha-dis.c
  39. alpha.ld
  40. arm-dis.c
  41. arm-semi.c
  42. arm.ld
  43. async.c
  44. balloon.h
  45. block-migration.c
  46. block-migration.h
  47. block.c
  48. block.h
  49. block_int.h
  50. bswap.h
  51. bt-host.c
  52. bt-host.h
  53. bt-vhci.c
  54. buffered_file.c
  55. buffered_file.h
  56. cache-utils.c
  57. cache-utils.h
  58. Changelog
  59. check-qdict.c
  60. check-qfloat.c
  61. check-qint.c
  62. check-qjson.c
  63. check-qlist.c
  64. check-qstring.c
  65. cmd.c
  66. cmd.h
  67. cocoa.m
  68. CODING_STYLE
  69. config.h
  70. configure
  71. console.c
  72. console.h
  73. COPYING
  74. COPYING.LIB
  75. cpu-all.h
  76. cpu-common.h
  77. cpu-defs.h
  78. cpu-exec.c
  79. create_config
  80. cris-dis.c
  81. curses.c
  82. curses_keys.h
  83. cutils.c
  84. d3des.c
  85. d3des.h
  86. def-helper.h
  87. device_tree.c
  88. device_tree.h
  89. dis-asm.h
  90. disas.c
  91. disas.h
  92. dma-helpers.c
  93. dma.h
  94. dyngen-exec.h
  95. elf.h
  96. envlist.c
  97. envlist.h
  98. exec-all.h
  99. exec.c
  100. feature_to_c.sh
  101. gdbstub.c
  102. gdbstub.h
  103. gen-icount.h
  104. host-utils.c
  105. host-utils.h
  106. hpet.h
  107. hppa-dis.c
  108. hppa.ld
  109. hxtool
  110. i386-dis.c
  111. i386.ld
  112. ia64.ld
  113. input.c
  114. ioport-user.c
  115. ioport.c
  116. ioport.h
  117. json-lexer.c
  118. json-lexer.h
  119. json-parser.c
  120. json-parser.h
  121. json-streamer.c
  122. json-streamer.h
  123. keymaps.c
  124. keymaps.h
  125. kvm-all.c
  126. kvm.h
  127. libfdt_env.h
  128. LICENSE
  129. linux-aio.c
  130. m68k-dis.c
  131. m68k-semi.c
  132. m68k.ld
  133. MAINTAINERS
  134. Makefile
  135. Makefile.hw
  136. Makefile.objs
  137. Makefile.target
  138. Makefile.user
  139. microblaze-dis.c
  140. migration-exec.c
  141. migration-fd.c
  142. migration-tcp.c
  143. migration-unix.c
  144. migration.c
  145. migration.h
  146. mips-dis.c
  147. mips.ld
  148. module.c
  149. module.h
  150. monitor.c
  151. monitor.h
  152. nbd.c
  153. nbd.h
  154. net-checksum.c
  155. net.c
  156. net.h
  157. notify.c
  158. notify.h
  159. osdep.c
  160. osdep.h
  161. path.c
  162. pci-ids.txt
  163. posix-aio-compat.c
  164. ppc-dis.c
  165. ppc.ld
  166. ppc64.ld
  167. qbool.c
  168. qbool.h
  169. qdict-test-data.txt
  170. qdict.c
  171. qdict.h
  172. qemu-aio.h
  173. qemu-barrier.h
  174. qemu-binfmt-conf.sh
  175. qemu-char.c
  176. qemu-char.h
  177. qemu-common.h
  178. qemu-config.c
  179. qemu-config.h
  180. qemu-doc.texi
  181. qemu-error.c
  182. qemu-error.h
  183. qemu-img-cmds.hx
  184. qemu-img.c
  185. qemu-img.texi
  186. qemu-io.c
  187. qemu-lock.h
  188. qemu-log.h
  189. qemu-malloc.c
  190. qemu-monitor.hx
  191. qemu-nbd.c
  192. qemu-nbd.texi
  193. qemu-objects.h
  194. qemu-option.c
  195. qemu-option.h
  196. qemu-options.hx
  197. qemu-queue.h
  198. qemu-sockets.c
  199. qemu-tech.texi
  200. qemu-thread.c
  201. qemu-thread.h
  202. qemu-timer.c
  203. qemu-timer.h
  204. qemu-tool.c
  205. qemu-x509.h
  206. qemu.sasl
  207. qemu_socket.h
  208. qerror.c
  209. qerror.h
  210. qfloat.c
  211. qfloat.h
  212. qint.c
  213. qint.h
  214. qjson.c
  215. qjson.h
  216. qlist.c
  217. qlist.h
  218. qobject.h
  219. qstring.c
  220. qstring.h
  221. readline.c
  222. readline.h
  223. README
  224. rules.mak
  225. rwhandler.c
  226. rwhandler.h
  227. s390-dis.c
  228. s390.ld
  229. savevm.c
  230. sdl.c
  231. sdl_keysym.h
  232. sdl_zoom.c
  233. sdl_zoom.h
  234. sdl_zoom_template.h
  235. sh4-dis.c
  236. softmmu-semi.h
  237. softmmu_defs.h
  238. softmmu_exec.h
  239. softmmu_header.h
  240. softmmu_template.h
  241. sparc-dis.c
  242. sparc.ld
  243. sparc64.ld
  244. sysemu.h
  245. targphys.h
  246. tcg-runtime.c
  247. texi2pod.pl
  248. thunk.c
  249. thunk.h
  250. TODO
  251. translate-all.c
  252. uboot_image.h
  253. usb-bsd.c
  254. usb-linux.c
  255. usb-stub.c
  256. VERSION
  257. vgafont.h
  258. vl.c
  259. vnc-auth-sasl.c
  260. vnc-auth-sasl.h
  261. vnc-auth-vencrypt.c
  262. vnc-auth-vencrypt.h
  263. vnc-tls.c
  264. vnc-tls.h
  265. vnc.c
  266. vnc.h
  267. vnc_keysym.h
  268. vnchextile.h
  269. x86_64.ld
  270. x_keymap.c
  271. x_keymap.h