From kde-core-devel Mon Dec 20 18:51:53 2004 From: Benjamin Meyer Date: Mon, 20 Dec 2004 18:51:53 +0000 To: kde-core-devel Subject: Re: libkonq and kactioncollection Message-Id: <200412201351.54721.ben () meyerhome ! net> X-MARC-Message: https://marc.info/?l=kde-core-devel&m=110356878010332 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Kate also has some KActionCollection fun. Is this change below correct? - -Benjamin Meyer kdetest@debian:~/source/kdebase/kate/app$ cvs diff kateexternaltools.cpp Index: kateexternaltools.cpp =================================================================== RCS file: /home/kde/kdebase/kate/app/kateexternaltools.cpp,v retrieving revision 1.26 diff -u -3 -p -r1.26 kateexternaltools.cpp - --- kateexternaltools.cpp 6 Oct 2004 12:05:02 -0000 1.26 +++ kateexternaltools.cpp 20 Dec 2004 18:48:44 -0000 @@ -292,7 +292,7 @@ KateExternalToolsMenuAction::KateExterna mainwindow( mw ) { - - m_actionCollection = new KActionCollection( this ); + m_actionCollection = new KActionCollection( (QWidget*)this ); connect(KateDocManager::self(),SIGNAL(documentChanged()),this,SLOT(slotDocumentChanged())); @@ -301,7 +301,11 @@ KateExternalToolsMenuAction::KateExterna void KateExternalToolsMenuAction::reload() { - - m_actionCollection->clear (); + KAction *it = m_actionCollection->action(0); + while ( it ){ + m_actionCollection->remove( it ); + it = m_actionCollection->action(0); + } popupMenu()->clear(); - -- aka icefox Public Key: http://www.icefox.net/public_key.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQFBxx9J1rZ3LTw38vIRAp5UAJ9M60/Uko44V5i2sqw0oQ7jtBnG4gCgkSnn Dc2Va9Ztxex5QPt4SK/Jn/w= =O63q -----END PGP SIGNATURE-----