summaryrefslogtreecommitdiff
path: root/area.go
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-05-07 17:51:04 -0400
committerPietro Gagliardi <[email protected]>2014-05-07 17:51:04 -0400
commit3508239bf7318019aff660e375fe286ecc2e8047 (patch)
treead733cf9c0432e04c40aa87862dbcb7f6c0c8f84 /area.go
parent0eaffe120b8f95b927a1abc657fdb25e8422bacf (diff)
Completed extending of mouse buttons to the system's limit; defined (as undefined) the mouse drag behavior for buttons >= 3; implemented all that on the GTK+ side, and decided to have MouseEvents.Held[] be sorted (documentation only for now; need to check the code to make sure it follows). Good Lord...
Diffstat (limited to 'area.go')
-rw-r--r--area.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/area.go b/area.go
index b39e448..d6cbf3d 100644
--- a/area.go
+++ b/area.go
@@ -73,6 +73,7 @@ type AreaHandler interface {
// MouseEvent contains all the information for a mous event sent by Area.Mouse.
// Mouse button IDs start at 1, with 1 being the left mouse button, 2 being the middle mouse button, and 3 being the right mouse button.
// If additional buttons are supported, they will be returned with 4 being the first additional button.
+// For example, on Unix systems where mouse buttons 4 through 7 are pseudobuttons for the scroll wheel directions, the next button, button 8, will be returned as 4, 9 as 5, etc.
// The association between button numbers and physical buttons are system-defined.
// For example, on Windows, buttons 4 and 5 are mapped to what are internally referred to as "XBUTTON1" and "XBUTTON2", which often correspond to the dedicated back/forward navigation buttons on the sides of many mice.
// The examples here are NOT a guarantee as to how many buttons maximum will be available on a given system.
@@ -103,7 +104,8 @@ type MouseEvent struct {
// Held is a slice of button IDs that indicate which mouse buttons are being held during the event.
// Held will not include Down and Up.
- // (TODO "There is no guarantee that Held is sorted."?)
+ // Held will be sorted.
+ // Only buttons 1, 2, and 3 are guaranteed to be detected by Held properly; whether or not any others are is implementation-defined.
Held []uint
}