Platforms to show: All Mac Windows Linux Cross-Platform
CarbonApplicationEventsMBS class Deprecated
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
class | Carbon Events | MBS MacCF Plugin | 2.8 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
This item is deprecated and should no longer be used.
You can use NSApplicationDelegateMBS for Cocoa instead.
A class for receiving events sent to the application.
Even if the name of the class includes Carbon, it works fine with Cocoa applications for most events.
Apple deprecated the carbon framework, but still in a Cocoa application, some features are only available through this class due to missing replacements. So we use CarbonApplicationEventsMBS class until a future MacOS update breaks it.
- 34 events
- event ApplicationActivated
- event ApplicationDeactivated
- event ApplicationGetDockTileMenu as Integer
- event ApplicationHidden
- event ApplicationLaunched(ProcessSerial as memoryblock)
- event ApplicationQuit
- event ApplicationShown
- event ApplicationSwitched(ProcessSerial as memoryblock)
- event ApplicationSystemUIModeChanged(SystemUIMode as Integer)
- event ApplicationTerminated(ProcessSerial as memoryblock)
- event GestureEnded(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer) as boolean
- event 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
- event 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
- event GestureStarted(GlobalMouseX as Double, GlobalMouseY as Double, WindowHandle as Integer, WindowMouseX as Double, WindowMouseY as Double, WindowPartCode as Integer, KeyModifiers as Integer) as boolean
- event 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
- event HotKeyPressed(signature as Integer, id as Integer)
- event HotKeyReleased(signature as Integer, id as Integer)
- event KeyboardRawKeyDown(maccharcode as Integer, keycode as Integer, modifiers as Integer, keyboardtype as Integer) as boolean
- event KeyboardRawKeyModifiersChanged(modifierkeys as Integer) as boolean
- event KeyboardRawKeyRepeat(maccharcode as Integer, keycode as Integer, modifiers as Integer, keyboardtype as Integer) as boolean
- event KeyboardRawKeyUp(maccharcode as Integer, keycode as Integer, modifiers as Integer, keyboardtype as Integer) as boolean
- event MenuPopulate(MenuHandle as Integer)
- event MouseDown(x as single, y as single, modifierKeys as Integer, button as Integer, clickcount as Integer, MouseChord as Integer) as boolean
- event 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
- event MouseMoved(x as single, y as single, modifierKeys as Integer, deltax as single, deltay as single) as boolean
- event MouseUp(x as single, y as single, modifierKeys as Integer, button as Integer, clickcount as Integer, MouseChord as Integer) as boolean
- event MouseWheelMoved(modifierKeys as Integer, axis as Integer, delta as Integer) as boolean
- event ProcessCommand(AttributeFlags as Integer, CommandId as Integer, Handle as Integer, Index as Integer) as boolean
- event ServiceCopy(Scrap as CarbonEventsScrapMBS) as boolean
- event ServiceGetTypes(copytypes as CFMutableArrayMBS, pastetypes as CFMutableArrayMBS) as boolean
- event ServicePaste(Scrap as CarbonEventsScrapMBS) as boolean
- event ServicePerform(Scrap as CarbonEventsScrapMBS, MessageName as CFStringMBS, UserData as CFStringMBS) as boolean
- event VolumeMounted(VolumeRefNum as Integer, VolumeRoot as FolderItem)
- event VolumeUnmounted(VolumeRefNum as Integer)
- 14 properties
- property Available as boolean
- property EventCount as Integer
- property Lasterror as Integer
- property MouseButton as Integer
- property MouseChord as Integer
- property MouseClickCount as Integer
- property MouseDeltaX as Single
- property MouseDeltaY as Single
- property MouseModifierKeys as Integer
- property MouseX as Single
- property MouseY as Single
- property Tablet as Boolean
- property TabletPoint as CarbonEventsTabletPointMBS
- property TabletProximity as CarbonEventsTabletProximityMBS
- 2 methods
- method CreateTypeStringWithOSType(ostype as string) as CFStringMBS
- method Listen
This class has no sub classes.
Some examples using this class:
- /MacCF/Carbon Events/Carbon Events Test
- /MacCF/Carbon Events/Display current IP
- /MacCF/Carbon Events/Hotkey Test
- /MacCF/Carbon Events/Tablet App
- /MacCF/Gestures
- /MacCF/Kiosk application
- /MacCocoa/NSStatusItem/StatusItem with CarbonEvents
- /MacOSX/Accessibility services/Active Window Logging
- /MacOSX/Accessibility services/Observer Test
- /MacOSX/DVD/DVD Playback2
Blog Entries
- MBS Plugins updated for Xojo 2019r2
- MBS Xojo Plugins, version 19.4pr1
- MBS Xojo / Real Studio Plugins, version 16.1pr3
- Tip of the day: Carbon events for Cocoa app
- Gestures on Mac OS X
- Dock Menu for Cocoa in Real Studio
- Magic Mouse in REALbasic
Release notes
- Version 19.4
- Deprecated CarbonEventsScrapMBS, CarbonApplicationEventsMBS and CarbonWindowsEventsMBS classes.
The items on this page are in the following plugins: MBS MacCF Plugin.
CAPlayThroughMBS - CarbonEventsIdleTimerMBS