forked from AuroraMiddleware/gtk
fdc66af5ce
When running on quartz, it is no longer expected for applications to provide their own application menu. Instead, they should simply ensure that they provide "app.about", "app.preferences" and "app.quit" actions (which many apps are already doing). A default menu will be shown that looks like the one presented by all other Mac OS applications, containing menu items for the above actions, as well as the typical "Hide app", "Hide Others and "Show All" items and the "Services" submenu. If an application does explicitly set an application menu (via gtk_application_set_app_menu()) then it will be respected, as before. https://bugzilla.gnome.org/show_bug.cgi?id=720552
55 lines
2.2 KiB
XML
55 lines
2.2 KiB
XML
<interface>
|
|
<menu id='app-menu'>
|
|
<section>
|
|
<item>
|
|
<!-- used for the application menu on MacOS. %s is replaced with the application name. -->
|
|
<attribute name='label' translatable='yes'>About %s</attribute>
|
|
<attribute name='action'>app.about</attribute>
|
|
<attribute name='x-gtk-private-special'>replace-appname</attribute>
|
|
</item>
|
|
</section>
|
|
<section>
|
|
<item>
|
|
<!-- used for the application menu on MacOS -->
|
|
<attribute name='label' translatable='yes'>Preferences</attribute>
|
|
<attribute name='action'>app.preferences</attribute>
|
|
</item>
|
|
</section>
|
|
<section>
|
|
<item>
|
|
<!-- used for the application menu on MacOS -->
|
|
<attribute name='label' translatable='yes'>Services</attribute>
|
|
<attribute name='x-gtk-private-special'>services-submenu</attribute>
|
|
</item>
|
|
</section>
|
|
<section>
|
|
<item>
|
|
<!-- used for the application menu on MacOS. %s is replaced with the application name. -->
|
|
<attribute name='label' translatable='yes'>Hide %s</attribute>
|
|
<attribute name='x-gtk-private-special'>hide-this</attribute>
|
|
<attribute name='action'>gtkinternal.hide</attribute>
|
|
</item>
|
|
<item>
|
|
<!-- used for the application menu on MacOS -->
|
|
<attribute name='label' translatable='yes'>Hide Others</attribute>
|
|
<attribute name='x-gtk-private-special'>hide-others</attribute>
|
|
<attribute name='action'>gtkinternal.hide-others</attribute>
|
|
</item>
|
|
<item>
|
|
<!-- used for the application menu on MacOS -->
|
|
<attribute name='label' translatable='yes'>Show All</attribute>
|
|
<attribute name='x-gtk-private-special'>show-all</attribute>
|
|
<attribute name='action'>gtkinternal.show-all</attribute>
|
|
</item>
|
|
</section>
|
|
<section>
|
|
<item>
|
|
<!-- used for the application menu on MacOS. %s is replaced with the application name. -->
|
|
<attribute name='label' translatable='yes'>Quit %s</attribute>
|
|
<attribute name='action'>app.quit</attribute>
|
|
<attribute name='x-gtk-private-special'>replace-appname</attribute>
|
|
</item>
|
|
</section>
|
|
</menu>
|
|
</interface>
|