37 messages in org.kde.kde-core-develRe: Global Shortcuts
FromSent OnAttachments
Michael JansenMar 16, 2008 7:49 pm 
Aaron J. SeigoMar 16, 2008 9:26 pm 
Andreas PakulatMar 17, 2008 2:09 am 
David FaureMar 17, 2008 2:31 am 
Andreas HartmetzMar 17, 2008 5:21 am 
Andreas HartmetzMar 17, 2008 5:29 am 
Anders LundMar 17, 2008 6:37 am 
Michael JansenMar 17, 2008 10:44 am 
Michael JansenMar 17, 2008 10:46 am 
Thiago MacieiraMar 17, 2008 11:03 am 
Andreas PakulatMar 17, 2008 11:04 am 
Eike HeinMar 17, 2008 11:19 am 
Anders LundMar 17, 2008 11:30 am 
Anders LundMar 17, 2008 11:33 am 
Andras MantiaMar 17, 2008 11:45 am 
Michael JansenMar 17, 2008 11:54 am 
Andreas PakulatMar 17, 2008 11:59 am 
Michael JansenMar 17, 2008 12:15 pm 
Michael JansenMar 17, 2008 12:16 pm 
Anders LundMar 17, 2008 12:18 pm 
Andreas PakulatMar 17, 2008 12:33 pm 
Michael JansenMar 17, 2008 12:44 pm 
Anders LundMar 17, 2008 12:58 pm 
Andreas PakulatMar 17, 2008 2:01 pm 
Thiago MacieiraMar 17, 2008 2:02 pm 
Andreas PakulatMar 17, 2008 2:02 pm 
Thiago MacieiraMar 17, 2008 2:04 pm 
Anders LundMar 17, 2008 2:39 pm 
Olivier GoffartMar 17, 2008 3:28 pm 
Andreas HartmetzMar 18, 2008 1:50 am 
Andreas HartmetzMar 18, 2008 1:54 am 
Andreas HartmetzMar 18, 2008 1:59 am 
Michael JansenMar 18, 2008 2:49 am 
Sven BurmeisterMar 18, 2008 7:48 am 
Alex MerryMar 18, 2008 9:15 am 
Christoph CullmannMar 18, 2008 12:44 pm 
Andreas PakulatMar 18, 2008 2:37 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: Global ShortcutsActions...
From:David Faure (fau@kde.org)
Date:Mar 17, 2008 2:31:24 am
List:org.kde.kde-core-devel

On Monday 17 March 2008, Michael Jansen wrote:

1. If a component ( see KComponentData ) registers a shortcut for the first    time. kdedglobalaccel registers the component as inactive. The component    goes on to registers it's global shortcuts but they won't be active. Code    wise i see no changes. Everything could happen behind the scene. ( Where do    not kxmlgui applications store their shortcuts? Not kxmlgui kparts are    impossible? )

KParts is currently based on KXMLGUI. But KDE applications can either use KXMLGUI or not. If they don't, shortcuts are saved into a simple KConfig file -- see the second half of KActionCollection::writeSettings, i.e. the case where
parentGUIClient()->xmlFile() is empty.

I don't think it's a good idea to tie together the "global shortcuts"
functionality and XMLGUI. Before kde-4.0 was out there were talks about replacing xmlgui with something entirely different, and the strong tie between KMainWindow and xmlgui was a big problem (which has been solved with the KXmlGuiWindow split). The rest didn't happen, but let's not make that mistake again, I can already foresee that the aggressions against xmlgui will start again when kde 5 comes along [or possibly even before, with the two technologies alongside each other].

If you really don't like "saving all global shortcuts into one config file" (me,
I don't have a problem with that), then make them saved in the application's config file. More precisely, into the KComponentData::config() file, so that it works for
parts and plugins too.

Yes, normal shortcuts are saved into the xmlgui file (with fallback to kconfig
if not xmlgui), but that's just a way of having to maintain two code paths instead of one. I
can't see a good reason why we don't just always save shortcuts into kconfig.