Adding additional IOutputViewModel
Andreas Pakulat
apaku at gmx.de
Mon Jun 11 08:37:40 UTC 2007
On 11.06.07 04:04:28, dukju ahn wrote:
> I suggest that we provide model interface such as,
>
> class IOutputViewModel
> {
> void activate(QModelIndex)
> QModelIndex highlightNext()
> QModelIndex highlightPrev()
> Qlist<QMenu> contextMenu(QModelIndex)
> }
> and make the users double-inherit with QAbsItemModel
So the outputview then does some dynamic_casting if he wants to activate
or highlight right?
> 1. think about makebuilders' show next error stuff, which I implemented.
> Although the item can be activated, item cannot be selected in GUI
> because item selection is done in QAbsItemView::setCurrentIndex().
> And it's a bad idea to provides IOutputView::setCurrentIndex() stuff
> because view are hided from outside world.
> By above interface, outputview knows which item to highlight.
I don't see how the above would help here, but maybe I just can't
imagine enough :) Would you please provide a compilable patch for this
part at least.
> Also, we can consolidate many "show next item.." stuffs. For example,
> suppose that grepview, makebuilder both plugs "show next item.."
> into the menubar. It's annoying. Rather we just let only outputview plugs
> "show next item" action.
I agree completely here.
> 2. Context menu is eaily retrieved.
That part is wrong. We already have a way to let the plugins provide
context actions. So if we need a context menu on the outputview (I don't
see any users yet, so there's no need to do it right now, IMHO) we
should create a new Context subclass and go the standard way of
retrieving the context menu.
Andreas
--
You have an unusual understanding of the problems of human relationships.
More information about the KDevelop-devel
mailing list