Improving tabbar context menus
Andreas Pakulat
apaku at gmx.de
Fri Sep 11 16:38:51 UTC 2009
On 11.09.09 18:20:11, Milian Wolff wrote:
> I've committed something, please review and I'll change it accordingly.
Will try to over the weekend, probably not today.
> Also I might want to introduce some kind of grouping instead of
> adding separators manually. It works for now, but as soon as someone
> else wants to add actions the current behaviour will fail, I'm
> sure...
You might want to look into what the rest of the platform does. See
IPluginController::queryPluginsForContextMenuExtensions(). It supplies
the "context" information (in your case the view, the qpoint and maybe
the tabbar itself) and fetches a list from each plugin of a structure
that describes into which groups each of the actions should go. The
actual widget using this function can then add its own custom actions
and these as well to create a nice context menu.
Not sure wether this complex thing is really needed in the case of
the tabbar..
Partly related: I think this again shows that separating sublime and
shell is not really a good idea.
Andreas
--
You look tired.
More information about the KDevelop-devel
mailing list