Mac Cocoa |
Author |
Message |
Ike Kapetan
Joined: 17 Jun 2006 Posts: 3136 Location: Europe
|
Posted: Fri Nov 28, 2008 9:56 pm Post subject: Menus |
|
|
sonsothunder.com - Creating a Standalone StatusItem Menu
"This tutorial will show you how to create a StatusItem menu that will be
available to all applications in the menu bar.
When you are done, you will have a simple menu that will appear on its own
in the menubar as a "universal" background application, and will contain two
menu items that let you enter a string into the Console and Quit itself." |
|
Back to top |
|
|
delovski
Joined: 14 Jun 2006 Posts: 3524 Location: Zagreb
|
Posted: Sat Jun 27, 2020 4:01 pm Post subject: |
|
|
wwdc - Build with iOS pickers, menus and actions
"Build iPhone and iPad apps with fluid interfaces and easily-accessible
contextual information. We'll show you how to integrate the latest UIKit
controls into your app to best take advantage of menus, date pickers,
page controls, and segmented controllers. Learn how to adopt Menus
throughly your user interface, and explore how UIAction can help unify
your event handling. Once you've learned about these new controls,
watch 'Design with iOS pickers, menus and actions' to discover how to
design great interfaces with these tools and APIs." |
|
Back to top |
|
|
delovski
Joined: 14 Jun 2006 Posts: 3524 Location: Zagreb
|
Posted: Tue Sep 15, 2020 5:27 pm Post subject: |
|
|
so - Is there an equivalent technique in Cocoa for the synchronous TrackPopupMenu in Windows?
"It appears that popUpContextMenu is already synchronous. Since I didn't see
a way to use NSMenu without having it send a notification to an NSView I came
up with a scheme that instantiates a temporary NSView. The goal is to display
a popup menu and return the selected item in the context of a single function
call."
Code: | NSEvent* event = [NSEvent otherEventWithType:NSApplicationDefined
location:wp
modifierFlags:NSApplicationDefined
timestamp: (NSTimeInterval) 0
windowNumber: windowNumber
context: [NSGraphicsContext currentContext]
subtype:0
data1: 0
data2: 0];
|
|
|
Back to top |
|
|
delovski
Joined: 14 Jun 2006 Posts: 3524 Location: Zagreb
|
|
Back to top |
|
|
Ike Kapetan
Joined: 17 Jun 2006 Posts: 3136 Location: Europe
|
Posted: Mon Sep 02, 2024 10:26 pm Post subject: |
|
|
ADC - AppKit Release Notes for macOS 14
"In macOS 14, menus have been reimplemented from the ground up to fully
use AppKit." |
|
Back to top |
|
|
|