Recent

Author Topic: Problem occuring in Cocoa menus  (Read 2795 times)

MISV

  • Hero Member
  • *****
  • Posts: 783
Problem occuring in Cocoa menus
« on: June 23, 2018, 03:57:32 pm »
When my TMainMenu "View" menu shows/opens (either by clicking it or hovering over all my top menus) I get the follow error in Lazarus/Cocoa/1.9.0/Trunk/20thjune2018

RunError(216) in cocoa/cocoawsmenus.pas line 340

Code: Pascal  [Select][+][-]
  1. procedure TCocoaMenuItem.menuNeedsUpdate(AMenu: NSMenu);
  2. begin
  3.   menuItemCallback.ItemSelected;
  4. end;

I am currently researching the problem to see if I can make a formal bug report with a simple test case - but if anyone else can chip in please do :)

The only difference I can tell is that my "View" menu contains a menu item with "Down" set.

Otherwise my other working menus also contains images (not shown though) and submenus and checked
« Last Edit: June 23, 2018, 04:08:50 pm by MISV »

ChrisR

  • Full Member
  • ***
  • Posts: 247
Re: Problem occuring in Cocoa menus
« Reply #1 on: June 24, 2018, 12:37:17 pm »
Does your program work if you rename the "View" menu to have the caption "Display". MacOS automatically appends the menu item "Enter Full Screen" to any menu named "View" (it also adds "Start Dictation" and "Emoji & Symbols" to your Edit menu).

MISV

  • Hero Member
  • *****
  • Posts: 783
Re: Problem occuring in Cocoa menus
« Reply #2 on: June 25, 2018, 11:16:00 am »
That seems to solve the issue. Thank you!

I have reported it here:
https://bugs.freepascal.org/view.php?id=33906


Another menu bug
If you have a menu called "help" macOS adds a search box. Typing anything into it makes software crash.

I have reported it here:
https://bugs.freepascal.org/view.php?id=33907
« Last Edit: June 25, 2018, 11:24:55 am by MISV »

 

TinyPortal © 2005-2018