From kde-core-devel Mon Jan 14 21:38:01 2002 From: Waldo Bastian Date: Mon, 14 Jan 2002 21:38:01 +0000 To: kde-core-devel Subject: Re: KXMLGUIClient X-MARC-Message: https://marc.info/?l=kde-core-devel&m=101104433620739 On Tuesday 01 January 2002 05:57 pm, Ellis Whitehead wrote: > On Tuesday 01 January 2002 07:31 pm, Waldo Bastian wrote: > > On Tuesday 01 January 2002 03:16 pm, Ellis Whitehead wrote: > > > Hi guys, > > > > > > I believe I've figured out an elegant solution to the KAccel proble= ms > > > I've been having with KAction -- but it would require that > > > KXMLGUIClient know which QWidget* it's a part of, so that it can pa= ss > > > that pointer to "new KActionCollection()", so that actions created = on > > > that collection are not all placed in one single monolithic > > > top-level-window KAccel object full of key conflicts. > > > > I think the reason for lumping them together is that otherwise > > keybindings don't work when e.g. the menubar isn't visible. > > > > Of course, the accels for a file-open dialog shouldn't end up in e.g. > > kedit's mainwindow, but should be collected in the mainwindow of the > > file-dialog itself. Could that be what is going wrong? > > Yes, that's exactly what's going wrong. This causes a number of proble= ms. > One of which is that the KApplication-KAccel object is the first create= d, > and is thus the last queried for shortcut keys. So when a new window p= ops > up, but puts its shortcuts into the bottom-level accelerator collection= , it > may be blocked by a QAccel object created after the original KAccel obj= ect, > by a QPopupMenu object for example. Has this been fixed already? David suggested a patch for this to prevent = that=20 accels end up in the wrong window. Also when starting e.g. konsole I get a bunch of warnings like these: kdecore (KAccel): WARNING: KAction::plugAccel( kacc =3D 0x8114448 ): KAcc= el=20 object already contains an action name "unnamed" Which somehow seems to be related. Cheers, Waldo --=20 bastian@kde.org | SuSE Labs KDE Developer | bastian@suse.com