Platforms to show: All Mac Windows Linux Cross-Platform

Back to CarbonWindowsEventsMBS class.

CarbonWindowsEventsMBS.GestureEnded(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 9.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
This event is called when the gesture ends.

GlobalMouseX and GlobalMouseY specify the mouse position. If WindowHandle is not 0, it contains the handle for the current window on that mouse position and WindowMouseX/WindowMouseY specify the window relative position. The WindowPartCode specifies which part of the window was hit. (See WindowPartCode definition in Apple documentation.)

Possible values for the key modifier:
activeFlag= 1= &h000001
btnState= 128= &h000080
cmdKey= 256= &h000100
shiftKey= 512= &h000200
alphaLock= 1024= &h000400
optionKey= 2048= &h000800
controlKey= 4096= &h001000
rightShiftKey= 8192= &h002000
rightOptionKey= 16384= &h004000
rightControlKey= 32768= &h008000
NumLock= 65536= &h010000
Fn= 131072= &h020000

Return true if you handled the event.

Supported on Mac OS X 10.5.5 and newer.
If not supported with the current hardware, this event is never called.

CarbonWindowsEventsMBS.GestureMagnify(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer, MagnificationAmount as Double) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 9.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
This event is called several times while the magnify gesture is performed.

MagnificationAmount the magnification amount.

GlobalMouseX and GlobalMouseY specify the mouse position. If WindowHandle is not 0, it contains the handle for the current window on that mouse position and WindowMouseX/WindowMouseY specify the window relative position. The WindowPartCode specifies which part of the window was hit. (See WindowPartCode definition in Apple documentation.)

Possible values for the key modifier:
activeFlag= 1= &h000001
btnState= 128= &h000080
cmdKey= 256= &h000100
shiftKey= 512= &h000200
alphaLock= 1024= &h000400
optionKey= 2048= &h000800
controlKey= 4096= &h001000
rightShiftKey= 8192= &h002000
rightOptionKey= 16384= &h004000
rightControlKey= 32768= &h008000
NumLock= 65536= &h010000
Fn= 131072= &h020000

Return true if you handled the event.

Supported on Mac OS X 10.5.5 and newer.
If not supported with the current hardware, this event is never called.

CarbonWindowsEventsMBS.GestureRotate(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer, RotationAmount as Double) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 9.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
This event is called several times while the rotation gesture is performed.

The RotationAmount in polar coordinates.

GlobalMouseX and GlobalMouseY specify the mouse position. If WindowHandle is not 0, it contains the handle for the current window on that mouse position and WindowMouseX/WindowMouseY specify the window relative position. The WindowPartCode specifies which part of the window was hit. (See WindowPartCode definition in Apple documentation.)

Possible values for the key modifier:
activeFlag= 1= &h000001
btnState= 128= &h000080
cmdKey= 256= &h000100
shiftKey= 512= &h000200
alphaLock= 1024= &h000400
optionKey= 2048= &h000800
controlKey= 4096= &h001000
rightShiftKey= 8192= &h002000
rightOptionKey= 16384= &h004000
rightControlKey= 32768= &h008000
NumLock= 65536= &h010000
Fn= 131072= &h020000

Return true if you handled the event.

Supported on Mac OS X 10.5.5 and newer.
If not supported with the current hardware, this event is never called.

CarbonWindowsEventsMBS.GestureStarted(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 9.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
This event is called when a gesture starts.

GlobalMouseX and GlobalMouseY specify the mouse position. If WindowHandle is not 0, it contains the handle for the current window on that mouse position and WindowMouseX/WindowMouseY specify the window relative position. The WindowPartCode specifies which part of the window was hit. (See WindowPartCode definition in Apple documentation.)

Possible values for the key modifier:
activeFlag= 1= &h000001
btnState= 128= &h000080
cmdKey= 256= &h000100
shiftKey= 512= &h000200
alphaLock= 1024= &h000400
optionKey= 2048= &h000800
controlKey= 4096= &h001000
rightShiftKey= 8192= &h002000
rightOptionKey= 16384= &h004000
rightControlKey= 32768= &h008000
NumLock= 65536= &h010000
Fn= 131072= &h020000

Return true if you handled the event.

Supported on Mac OS X 10.5.5 and newer.
If not supported with the current hardware, this event is never called.

CarbonWindowsEventsMBS.GestureSwipe(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer, SwipeDirectionX as Double, SwipeDirectionY as Double) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 9.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
This event is called for a swipe gesture.

SwipeDirectionX and SwipeDirectionY specify the swipe direction.

GlobalMouseX and GlobalMouseY specify the mouse position. If WindowHandle is not 0, it contains the handle for the current window on that mouse position and WindowMouseX/WindowMouseY specify the window relative position. The WindowPartCode specifies which part of the window was hit. (See WindowPartCode definition in Apple documentation.)

Possible values for the key modifier:
activeFlag= 1= &h000001
btnState= 128= &h000080
cmdKey= 256= &h000100
shiftKey= 512= &h000200
alphaLock= 1024= &h000400
optionKey= 2048= &h000800
controlKey= 4096= &h001000
rightShiftKey= 8192= &h002000
rightOptionKey= 16384= &h004000
rightControlKey= 32768= &h008000
NumLock= 65536= &h010000
Fn= 131072= &h020000

Return true if you handled the event.

Supported on Mac OS X 10.5.5 and newer.
If not supported with the current hardware, this event is never called.

CarbonWindowsEventsMBS.MouseDown(x as single, y as single, modifierKeys as Integer, button as Integer, clickcount as Integer, MouseChord as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 3.3 ✅ Yes ❌ No ❌ No ❌ No Desktop only
An event which fires when a mousebuton is down.

CarbonWindowsEventsMBS.MouseDragged(x as single, y as single, modifierKeys as Integer, deltax as single, deltay as single, button as Integer, clickcount as Integer, MouseChord as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 3.3 ✅ Yes ❌ No ❌ No ❌ No Desktop only
An event which fires when the mouse is dragged.

In case the tablet property is true, the TabletPoint or the TabletProximity property is filled with an object.

Tablet functions may or may not work in Xojo's debug mode (some RB versions work and some not).

CarbonWindowsEventsMBS.MouseMoved(x as single, y as single, modifierKeys as Integer, deltax as single, deltay as single) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 3.3 ✅ Yes ❌ No ❌ No ❌ No Desktop only
An event which fires when the mouse is moved.

In case the tablet property is true, the TabletPoint or the TabletProximity property is filled with an object.

Tablet functions may or may not work in Xojo's debug mode (some RB versions work and some not).

CarbonWindowsEventsMBS.MouseUp(x as single, y as single, modifierKeys as Integer, button as Integer, clickcount as Integer, MouseChord as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 3.3 ✅ Yes ❌ No ❌ No ❌ No Desktop only
An event which fires when a mousebutton is released.

In case the tablet property is true, the TabletPoint or the TabletProximity property is filled with an object.

Tablet functions may or may not work in Xojo's debug mode (some RB versions work and some not).

CarbonWindowsEventsMBS.MouseWheelMoved(modifierKeys as Integer, axis as Integer, delta as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
event Carbon Events MBS MacCF Plugin 2.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Called whenever the mouse wheel is moved with the mouse cursor within your window.
Example
function MouseWheelMoved(modifierKeys as Integer, axis as Integer, delta as Integer) as boolean
Var d as Integer

const cmdKey=256
const shiftKey=512
const alphaLock=1024
const optionKey=2048
const controlKey=4096
const rightShiftKey=8192
const rightOptionKey=16384
const rightControlKey=32768

const kEventMouseWheelAxisY=1
const kEventMouseWheelAxisX=0

if axis=kEventMouseWheelAxisY then
d=delta

if BitwiseAnd(modifierKeys,optionkey)<>0 then
d=d*4 // scroll faster with option
end if

List.ScrollPosition=List.ScrollPosition-d
end if

List.InsertRow 0,"MouseWheelMoved "+str(delta)
end function

Currently axis is only 0 or 1, but in future new input devices may have up to 32 axises.

The items on this page are in the following plugins: MBS MacCF Plugin.


The biggest plugin in space...