--===============1156945218== Content-Type: multipart/signed; boundary="nextPart1311271.oLMKzOe0pP"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart1311271.oLMKzOe0pP Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Wednesday 12 July 2006 11:38, Jason Harris wrote: > Hi, > > I'm trying to implement editable toolbars for KStars. I've got: > > void KStars::slotConfigureToolbars() { > saveMainWindowSettings( KGlobal::config(), "MainWindow" ); > KEditToolbar ket =3D new KEditToolbar(actionCollection()); > connect(ket,SIGNAL(newToolbarConfig()),this,SLOT(slotApplyToolbarConfig(= )) >); > > //ket.exec(); > //DEBUG > if ( ket.exec() =3D=3D QDialog::Accepted ) { > kDebug() << "KEditToolbar dialog returned Accepted" << endl; > } > } > > void KStars::slotApplyToolbarConfig() { > //DEBUG > kDebug() << "Recreating GUI..." << endl; > > createGUI(); > applyMainWindowSettings( KGlobal::config(), "MainWindow" ); > } > > ...and slotConfigureToolbars() is connected to > KStdAction::configureToolbars(). This is basically straight from the > KEditToolbar API dox. > > The KEditToolbars dialog opens and behaves just fine, but on pressing App= ly > or Ok, the toolbar does not get updated to reflect the changes I made, and > I never see my "Recreating GUI" debug message (so it's never getting to > slotApplyToolbarConfig() ). I do get the "KEditToolbar dialog returned > Accepted" debug message. > > Another weirdness is that after pressing "Apply", the "Apply" button does > not get disabled. Looking at kedittoolbar.cpp, slotApply() both disables > the Apply button and emits the newToolbarConfig() Signal, so it seems this > slot is never being reached. Indeed, there's no connect() statement > involving slotApply() in kedittoolbar.cpp. > > Anyone have a clue about this? Hmm, sounds like edit toolbars might be broken. I wasn't aware that it's=20 broken though. However, should LiveUI make it past the design/implementation/acceptance=20 stage, the whole edittoolbars class will be rewritten, so unless someone=20 volunteers to fix edittoolbars (which is likely to be fairly pointless) I'd= =20 recommend waiting for now. Cheers, Hamish. --nextPart1311271.oLMKzOe0pP Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) iD8DBQBEtRCXH8BtnSmIlUYRAkDzAJ0W97rmb+lMUyn2JLRpIcLeNXt+fQCeMVpp trScKyT1JZNogPIWGMNRMw8= =3M0/ -----END PGP SIGNATURE----- --nextPart1311271.oLMKzOe0pP-- --===============1156945218== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe << --===============1156945218==--