JavaScript resizeTo bug

Andras Mantia amantia at kde.org
Mon Oct 27 14:59:16 GMT 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Monday 27 October 2003 11:33, David Faure wrote:
> On Monday 27 October 2003 00:55, Andras Mantia wrote:
> > David Faure wrote:
> > 
> > > On Sunday 26 October 2003 22:04, Andras Mantia wrote:
> > >> OK, found the reason: if the tabs are visible it doesn't work.
> > > Ah. Hmm, it's arguable what should happen in such a case. The needs of 
the
> > > various websites in the different tabs, are different.
> > Well, yes, but it was missleading. Especially since it fails to resize 
even if
> > tabbed brwosing are enabled, only one page is opened and the tabs are
> > visible.
> OK that's definitely a bug then. Of course it only happens to those who have
> activated that option :)

Patch if fine, you may apply it. :-)

Andras

> 
> Please test.
>  
> --- konq_view.cc        17 Oct 2003 12:07:14 -0000      1.348
> +++ konq_view.cc        27 Oct 2003 09:28:02 -0000
> @@ -25,6 +25,7 @@
>  #include "konq_run.h"
>  #include "konq_events.h"
>  #include "konq_viewmgr.h"
> +#include "konq_tabs.h"
>  #include "konq_browseriface.h"
>  #include <kparts/statusbarextension.h>
>  #include <kparts/browserextension.h>
> @@ -467,13 +468,18 @@ void KonqView::slotEnableAction( const c
> 
>  void KonqView::slotMoveTopLevelWidget( int x, int y )
>  {
> -  if 
( m_pMainWindow->currentView()->frame()->parentContainer()->frameType() != 
"Tabs" )
> +  KonqFrameContainerBase* container = frame()->parentContainer();
> +  // If tabs are shown, only accept to move the whole window if there's 
only one tab.
> +  if ( container->frameType() != "Tabs" || 
static_cast<KonqFrameTabs*>(container)->count() == 1 )
>      m_pMainWindow->move( x, y );
>  }
> 
>  void KonqView::slotResizeTopLevelWidget( int w, int h )
>  {
> -  if 
( m_pMainWindow->currentView()->frame()->parentContainer()->frameType() != 
"Tabs" )
> +  KonqFrameContainerBase* container = frame()->parentContainer();
> +  // If tabs are shown, only accept to resize the whole window if there's 
only one tab.
> +  // ### Maybe we could store the size requested by each tab and resize the 
window to the biggest one.
> +  if ( container->frameType() != "Tabs" || 
static_cast<KonqFrameTabs*>(container)->count() == 1 )
>      m_pMainWindow->resize( w, h );
>  }
> 
> -- 
> David Faure -- faure at kde.org, dfaure at klaralvdalens-datakonsult.se
> Qt/KDE/KOffice developer
> Klarälvdalens Datakonsult AB, Platform-independent software solutions
> 
> 
> 
> 
> 
> 

- -- 
Quanta Plus developer - http://quanta.sourceforge.net
K Desktop Environment - http://www.kde.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2-rc1-SuSE (GNU/Linux)

iD8DBQE/nTLETQdfac6L/08RAlU3AJ9JlpN+hq//ZQpD1ZrxeHoOkYUSWgCePlVb
dCmiYaszdaJ9exgMOzRsWxI=
=mx5S
-----END PGP SIGNATURE-----




More information about the kfm-devel mailing list