[Libreoffice] Trouble of showing LibreOffice/OpenOffice toolbar back
michael.meeks at suse.com
Mon Oct 24 05:47:13 PDT 2011
Hi Noel & co.
I'll CC the public dev list on this since it may be of wider interest.
On Mon, 2011-10-24 at 11:24 +0100, Noel Power wrote:
> something like this should work ( although doesn't on master or 3.4
> but... does appear to work on 3.3 :-/ ) seems like this really is a
Carlos - reading the code, it looks like 'setVisible' is what you want
to be calling - it -looks- (on a first glance) as if it doesn't save the
state in this case - so it should be something we can call and will not
alter the other documents (but perhaps I'm mistaken).
> sub togglefind
> layoutManager = thisComponent.currentController.frame.layoutManager
> findbarUrl = "private:resource/toolbar/findbar"
> bVis = layoutmanager.iselementvisible( "private:resource/toolbar/findbar" )
> msgbox "Findbar currently IsVisible? " & bVis
> if bVis then
> layoutmanager.hideElement( findbarUrl )
> layoutmanager.showelement( findbarUrl )
> end sub
I'm personally suspicious of:
Author: Carsten Driesner <cd at openoffice.org>
Date: Mon Nov 1 13:29:26 2010 +0100
dockingwindows: #i112595# Fixed problem related to changes for
better layouting. Further code rework
Which does the:
- if ( pWindow && pIter->m_bFloating )
- pWindow->Show(bVisible & bToolbarVisible, SHOW_NOFOCUSCHANGE | SHOW_NOACTIVATE );
+ if ( pWindow )
+ bool bSetVisible( pIter->m_bVisible & bVisible );
+ if ( !bSetVisible )
+ if ( pIter->m_bFloating )
+ pWindow->Show(true, SHOW_NOFOCUSCHANGE | SHOW_NOACTIVATE );
Which (at first glance) doesn't seem to hide non-floating windows ( or
perhaps I'm missing how the dirty notification propagates somehow ).
michael.meeks at suse.com <><, Pseudo Engineer, itinerant idiot
More information about the LibreOffice