sciter-sdk / go-sciter

Golang bindings of Sciter: the Embeddable HTML/CSS/script engine for modern UI development
https://sciter.com
2.58k stars 268 forks source link

AddQuitMenu #232

Closed mchampaneri closed 4 years ago

mchampaneri commented 4 years ago

AddQuitMenu: darwin AddQuitMenu function added | stubs for windows and linux added | sample added in examples\demoes\09

pravic commented 4 years ago

Thanks!

I have a question: does your menu work? I've tried on Catalina (10.15.4) and it doesn't show any menu. Also I've tried this code and it doesn't work either.

P.S. Could you remove those .DS_Store files? Also, it's better to ignore them completely via .gitignore

mchampaneri commented 4 years ago

@pravic

I have a question: does your menu work? I've tried on Catalina (10.15.4) and it doesn't show any menu. Also I've tried this code and it doesn't work either.

When you application is executing outside Contents/MacOS folder menu does not get attached on application load.

In MacOs menu is only get attached on launch if your application is running from inside Contents/MacOS folder.

Try this https://github.com/mchampaneri/go-sciter/blob/AddQuitMenu/examples/demoes/09/Contents/MacOS/09

Updated the sample as well.

While development to see menu, first click outside window and then re-select the application window. and your menu will work normally . [ It somehow loads menu on re-selection of application but does not attaching it on launch, If application is not launched from Contents/MacOS folder.

pravic commented 4 years ago

@mchampaneri No, sorry for misunderstanding - I intend to close this PR and merge #233 instead.