DocumentSwitcherPluging are broken by workingsets

Andreas Pakulat apaku at gmx.de
Thu Jun 25 19:57:29 UTC 2009


On 25.06.09 21:41:11, David Nolden wrote:
> Am Donnerstag 25 Juni 2009 21:33:48 schrieb Andreas Pakulat:
> > It seems that the introduction of workingsets breaks some of the
> > assumption that the documentswitcherplugin has (at least thats the only
> > way I can see that view->document() returns a broken pointer). At least
> > it seems that the list of views it keeps isn't properly updated when a
> > workingset hides itself.
> >
> > As I have absolutely 0 idea how the workingset stuff is implemented, I'm
> > going to need some help to fix that one. Currently the plugin is
> > notified when a new mainwindow is added and on each mainwindow it
> > connects to these signals:
> >
> > areaChanged
> > activeViewChanged
> > viewAdded
> > aboutToRemoveView
> >
> > so its notified whenever the current view changes and when the area
> > changes. I'm guessing that I'll need a new signal to connect to when the
> > workingset is changed, which one?
> >
> > Also what consequences does disabling a workingset have, i.e. does it
> > close all connected documents? Does it just remove all views? If the
> > latter why is aboutToRemoveView never emitted.
> >
> > Andreas
> While switching working-sets, the areas are switched temporarily for 
> implementation reasons(So the working-sets don't update each other recursively 
> due to changes, and so the main-window is not updated while applying the 
> changes). However the main-window only emits aboutToRemoveView for views that 
> are part of the current area, and since whole switching working-sets all the 
> changes happen while the main-window is disconnected from the area, the 
> document-switcher did not notice the changes.
> 
> I've just committed a fix proposal.

I can imagine other plugins breaking because they don't get to see this
either, so we probably need some changes in shell/sublime or a new
signal when workingsets are switched.

Andreas

-- 
You will soon forget this.




More information about the KDevelop-devel mailing list