Sebastian, NSPopover needs some major re-writing. I am going to get to this once I get done with the changes to NSBrowser.
GC On Mon, Nov 4, 2024 at 4:24 PM Sebastian Reitenbach < [email protected]> wrote: > Hi, > > I'm trying since two days, to create a NSPopover under a NSTextField, when > I start typing, to show me list of items matching what I type. > > However, whenever it tries to show the NSPopover, or more specifically > when I assigng the ViewController to the popover.contentViewController, I > get an NSInternalInconsistencyException. > > 2024-11-04 21:38:40.983 Test-PopoverTest[36432:7926294758536] Problem > posting <GSNotification: 0x735c115d278> Name: > NSApplicationDidFinishLaunchingNotification Object: <NSApplication: > 0x736056cf0e8> Info: (null): <NSException: 0x735c1158a28> > NAME:NSInternalInconsistencyException REASON:Could not load controller > NSViewController INFO:(null) > > Removing all the complexities, I ended up with this little test app here: > https://github.com/buzzdeee/Test-PopoverTest > > Just a button, where the NSPopover should appear when the button is > pressed. > > When I comment out the last line in the applicationDidFinishLaunching: > method: > self.popover.contentViewController = popoverContentVC; > > then the Exception won't happen, but also the NSPopover not shown. > Do I have to subclass NSViewController and add something special to it? > I'm out of ideas ;) > > Any hint to make the NSPopover show up is highly appreciated. > > thanks > Sebastian > > > -- Gregory Casamento GNUstep Lead Developer / Black Lotus, Principal Consultant http://www.gnustep.org - http://heronsperch.blogspot.com https://www.patreon.com/bePatron?u=352392 - Become a Patron https://www.openhub.net/languages/objective_c https://www.gofundme.com/f/cacao-linux-a-gnustep-reference-implementation
