Ticket #14 (closed defect: fixed)

Opened 4 years ago

Last modified 4 years ago

The points given by EventMotion and EventKey disagree

Reported by: benl Owned by:
Priority: high Milestone: 1.2.0.0
Component: Unknown Version: 1.1.1.0
Keywords: Cc:

Description

Thomas DuBuisson? report:

The points given by EventMotion? and EventKey? disagree (using Xorg + XMonad, which forces the window dimensions). If they are actually points from different coordinate systems then preventing their mixing is a perfect use for the type system (along with conversion functions).

Attachments

convertMotionPointBasedOnWindowSize.patch (3.5 kB) - added by tommd 4 years ago.
Fixed some typos in the old patch. This one actually builds.

Change History

Changed 4 years ago by tommd

If you look at Graphics/Gloss/Internals/Interface/Game.hs you'll see the function "handle_keyMouse" has point conversions for each action. This conversion needs to be it's own function and used in the "handle_motion" callback as well. Patch attached.

Changed 4 years ago by tommd

Fixed some typos in the old patch. This one actually builds.

Changed 4 years ago by benl

  • priority changed from normal to high

Changed 4 years ago by benl

  • status changed from new to closed
  • resolution set to fixed
Note: See TracTickets for help on using tickets.