Fixing i18n + global shortcuts

Andreas Hartmetz ahartmetz at gmail.com
Mon Mar 3 17:59:33 GMT 2008


Hi all!

I've been hacking on this on and off for some time and it's quite close to 
ready so I want to make it known to avoid having to repeat answers to 
questions on IRC.
This is also a request for comments but I don't expect many if at all :)
The idea is that actions with global shortcuts will internally have "friendly" 
names which might [should] be translated and unique names like those used in 
KActionCollection::addAction(). The objectName() will be used for that 
purpose, similar to KActionCollection().
Other notable changes are:
-KAction::globalShortcutAllowed() will be deprecated and replaced with 
globalShortcutEnabled() according to the patch.
-somewhat better documentation
-default shortcuts will be saved too to facilitate the work of the global 
shortcuts KCM (there is and should be no other user I know of).
-for the time being, there will be no way to "forget" an action. I would like 
to add explicit API to do this instead of doing it using magic parameter 
values [i.e. KShortcut(), NoAutoloading] to KAction::setGlobalShortcut().

There is still room for improvement but overall the new code should be better 
than the old already. Please see the attachment for the largish patch.

Cheers,
Andreas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix-globalshortcuts-i18n.patch
Type: text/x-diff
Size: 41229 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080303/634f82de/attachment.patch>


More information about the kde-core-devel mailing list