On Thu, 2012-08-30 at 11:12 +0200, Francesco M. wrote: > I'm trying to understand how the menu bar works. I would like to > understand how menus are "taken" from applications and rendered in > Unity. > > In PanelMenuView's constructor there is a reference to a variable > named "layout_". Where is that variable defined? In the header file > there is a (unused?) "_menu_layout". > The first line of the constructor says to render menu items aligned > from the left to the right. Where is the layout definition? > > And could someone tell me where happens the population of this layout > with menu items?
Hello Francesco, The way that the panel works is that it is basically the host for a series of indicators. The menus are no different in that regard. So the code that you're probably looking for is in indicator-appmenu: http://launchpad.net/indicator-appmenu The application loads a module that parses the menus in memory and creates a representation of them on DBus. Then indicator-appmenu finds that representation and displays it in the panel when the application has focus. Hope that helps! --Ted
signature.asc
Description: This is a digitally signed message part
-- Mailing list: https://launchpad.net/~unity-dev Post to : [email protected] Unsubscribe : https://launchpad.net/~unity-dev More help : https://help.launchpad.net/ListHelp

