R
Robert Schneider
I'm creating an application that has should have a style like VS.NET.
What I would like to know is what is the best way to handle menus, tool bars
and context menus. How can this be done? The menus are dynamic so they have
to be determined with each click. But how does it work?
Let's take VS itself: If I single-click in the project view on a file node
some things happens. I.e. the properties view is refreshed. But also the
menu and the tool bars. If I even right click on the node a context menu
appears. What do you think how this works?
Is there a selection event that is received by the 'main app' which then
determines which menu and tool bar items to show? Or are those items
provided by the project view which gets merged into the main menu and tool
bars somehow?
And where is the logic which determines which items has to be enabled or
checked or visualized? Is there one intelligent class or package that
controls that for the whole application? Conside that I select a file node,
a project node and a folder at the same time. Who or what determines the
available commands?
Consider also that I would like to establis a MVC architecture. So I have
commands somewhere (with which I'm confused as well, how to organize them)
and I have the graphical representation of those. As menu entries, tool bar
items or context menu items.
Thanks in advance,
Robert
What I would like to know is what is the best way to handle menus, tool bars
and context menus. How can this be done? The menus are dynamic so they have
to be determined with each click. But how does it work?
Let's take VS itself: If I single-click in the project view on a file node
some things happens. I.e. the properties view is refreshed. But also the
menu and the tool bars. If I even right click on the node a context menu
appears. What do you think how this works?
Is there a selection event that is received by the 'main app' which then
determines which menu and tool bar items to show? Or are those items
provided by the project view which gets merged into the main menu and tool
bars somehow?
And where is the logic which determines which items has to be enabled or
checked or visualized? Is there one intelligent class or package that
controls that for the whole application? Conside that I select a file node,
a project node and a folder at the same time. Who or what determines the
available commands?
Consider also that I would like to establis a MVC architecture. So I have
commands somewhere (with which I'm confused as well, how to organize them)
and I have the graphical representation of those. As menu entries, tool bar
items or context menu items.
Thanks in advance,
Robert