[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: [kdelibs/frameworks] tier1/kconfig: Get kconfig_compiler to use QCoreApplication::translate
From: Kevin Ottens <ervin+bluesystems () kde ! org>
Date: 2013-08-20 15:07:17
Message-ID: E1VBnWf-0005lq-PS () scm ! kde ! org
[Download RAW message or body]
Git commit 72801f0049a7115e304e05e99acff2b8584c8880 by Kevin Ottens.
Committed on 20/08/2013 at 13:31.
Pushed by ervin into branch 'frameworks'.
Get kconfig_compiler to use QCoreApplication::translate
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test1.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test10.h.ref
M +28 -28 tier1/kconfig/autotests/kconfig_compiler/test11.cpp.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test11.h.ref
M +27 -27 tier1/kconfig/autotests/kconfig_compiler/test11a.cpp.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test11a.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test12.h.ref
M +16 -16 tier1/kconfig/autotests/kconfig_compiler/test2.cpp.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test2.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test3.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test3a.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test4.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test5.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test6.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test7.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test8a.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test8b.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test9.h.ref
M +16 -16 tier1/kconfig/autotests/kconfig_compiler/test_dpointer.cpp.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test_dpointer.h.ref
M +1 -0 tier1/kconfig/autotests/kconfig_compiler/test_signal.h.ref
M +4 -2 tier1/kconfig/src/kconfig_compiler/kconfig_compiler.cpp
http://commits.kde.org/kdelibs/72801f0049a7115e304e05e99acff2b8584c8880
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test1.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test1.h.ref index \
db19069..57fa4bf 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test1.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test1.h.ref
@@ -4,6 +4,7 @@
#define TEST1_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
#include <qdir.h>
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test10.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test10.h.ref index \
8f6f26a..f3f441d 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test10.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test10.h.ref
@@ -4,6 +4,7 @@
#define TEST10_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test10 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test11.cpp.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test11.cpp.ref index \
a9cabe3..5a1f5b9 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test11.cpp.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test11.cpp.ref
@@ -9,17 +9,17 @@ Test11::Test11( )
setCurrentGroup( QLatin1String( "General" ) );
mAutoSaveItem = new MyPrefs::ItemBool( currentGroup(), QLatin1String( \
"Auto Save" ), mAutoSave, false );
- mAutoSaveItem->setLabel( QObject::tr("Enable automatic saving of \
calendar") );
- mAutoSaveItem->setWhatsThis( QObject::tr("WhatsThis text for AutoSave \
option") ); + mAutoSaveItem->setLabel( \
QCoreApplication::translate("Test11", "Enable automatic saving of \
calendar") ); + mAutoSaveItem->setWhatsThis( \
QCoreApplication::translate("Test11", "WhatsThis text for AutoSave option") \
); addItem( mAutoSaveItem, QLatin1String( "AutoSave" ) );
mAutoSaveIntervalItem = new MyPrefs::ItemInt( currentGroup(), \
QLatin1String( "Auto Save Interval" ), mAutoSaveInterval, \
10 );
- mAutoSaveIntervalItem->setLabel( QObject::tr("Auto Save Interval") );
+ mAutoSaveIntervalItem->setLabel( QCoreApplication::translate("Test11", \
"Auto Save Interval") ); addItem( mAutoSaveIntervalItem, QLatin1String( \
"AutoSaveInterval" ) ); mConfirmItem = new MyPrefs::ItemBool( \
currentGroup(), QLatin1String( "Confirm Deletes" ), \
mConfirm, true );
- mConfirmItem->setLabel( QObject::tr("Confirm deletes") );
+ mConfirmItem->setLabel( QCoreApplication::translate("Test11", "Confirm \
deletes") ); addItem( mConfirmItem, QLatin1String( "Confirm" ) );
mArchiveFileItem = new MyPrefs::ItemString( currentGroup(), \
QLatin1String( "Archive File" ), mArchiveFile );
- mArchiveFileItem->setLabel( QObject::tr("Archive File") );
+ mArchiveFileItem->setLabel( QCoreApplication::translate("Test11", \
"Archive File") ); addItem( mArchiveFileItem, QLatin1String( "ArchiveFile" \
) ); QList<MyPrefs::ItemEnum::Choice> valuesDestination;
{
@@ -35,33 +35,33 @@ Test11::Test11( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl1");
- choice.label = QObject::tr("Argl1 Label");
+ choice.label = QCoreApplication::translate("Test11", "Argl1 Label");
valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl2");
- choice.whatsThis = QObject::tr("Argl2 Whatsthis");
+ choice.whatsThis = QCoreApplication::translate("Test11", "Argl2 \
Whatsthis"); valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl3");
- choice.label = QObject::tr("Argl3 Label");
- choice.whatsThis = QObject::tr("Argl3 Whatsthis");
+ choice.label = QCoreApplication::translate("Test11", "Argl3 Label");
+ choice.whatsThis = QCoreApplication::translate("Test11", "Argl3 \
Whatsthis"); valuesDestination.append( choice );
}
mDestinationItem = new MyPrefs::ItemEnum( currentGroup(), QLatin1String( \
"Destination" ), mDestination, valuesDestination, \
EnumDestination::standardDestination );
- mDestinationItem->setLabel( QObject::tr("New Events/Todos Should") );
+ mDestinationItem->setLabel( QCoreApplication::translate("Test11", "New \
Events/Todos Should") ); addItem( mDestinationItem, QLatin1String( \
"Destination" ) );
setCurrentGroup( QLatin1String( "Views" ) );
mHourSizeItem = new MyPrefs::ItemInt( currentGroup(), QLatin1String( \
"Hour Size" ), mHourSize, 10 );
- mHourSizeItem->setLabel( QObject::tr("Hour Size") );
+ mHourSizeItem->setLabel( QCoreApplication::translate("Test11", "Hour \
Size") ); addItem( mHourSizeItem, QLatin1String( "HourSize" ) );
mSelectionStartsEditorItem = new MyPrefs::ItemBool( currentGroup(), \
QLatin1String( "SelectionStartsEditor" ), \
mSelectionStartsEditor, false );
- mSelectionStartsEditorItem->setLabel( QObject::tr("Time range selection \
in agenda view starts event editor") ); + \
mSelectionStartsEditorItem->setLabel( QCoreApplication::translate("Test11", \
"Time range selection in agenda view starts event editor") ); addItem( \
mSelectionStartsEditorItem, QLatin1String( "SelectionStartsEditor" ) );
setCurrentGroup( QLatin1String( "KOrganizer Plugins" ) );
@@ -71,22 +71,22 @@ Test11::Test11( )
defaultSelectedPlugins.append( QString::fromUtf8( "webexport" ) );
mSelectedPluginsItem = new MyPrefs::ItemStringList( currentGroup(), \
QLatin1String( "SelectedPlugins" ), mSelectedPlugins, \
defaultSelectedPlugins );
- mSelectedPluginsItem->setLabel( QObject::tr("SelectedPlugins") );
+ mSelectedPluginsItem->setLabel( QCoreApplication::translate("Test11", \
"SelectedPlugins") ); addItem( mSelectedPluginsItem, QLatin1String( \
"SelectedPlugins" ) );
setCurrentGroup( QLatin1String( "Colors" ) );
mHighlightColorItem = new MyPrefs::ItemColor( currentGroup(), \
QLatin1String( "Highlight Color" ), mHighlightColor, QColor( 100, 100, 255 \
) );
- mHighlightColorItem->setLabel( QObject::tr("Highlight color") );
+ mHighlightColorItem->setLabel( QCoreApplication::translate("Test11", \
"Highlight color") ); addItem( mHighlightColorItem, QLatin1String( \
"HighlightColor" ) ); mAgendaBgColorItem = new MyPrefs::ItemColor( \
currentGroup(), QLatin1String( "Agenda Background Color" ), mAgendaBgColor, \
QColor( 255, 255, 255 ) );
- mAgendaBgColorItem->setLabel( QObject::tr("Agenda view background \
color") ); + mAgendaBgColorItem->setLabel( \
QCoreApplication::translate("Test11", "Agenda view background color") ); \
addItem( mAgendaBgColorItem, QLatin1String( "AgendaBgColor" ) );
setCurrentGroup( QLatin1String( "Fonts" ) );
mTimeBarFontItem = new MyPrefs::ItemFont( currentGroup(), QLatin1String( \
"TimeBar Font" ), mTimeBarFont );
- mTimeBarFontItem->setLabel( QObject::tr("Time bar") );
+ mTimeBarFontItem->setLabel( QCoreApplication::translate("Test11", "Time \
bar") ); addItem( mTimeBarFontItem, QLatin1String( "TimeBarFont" ) );
setCurrentGroup( QLatin1String( "Email" ) );
@@ -95,18 +95,18 @@ Test11::Test11( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("sendmail");
- choice.label = /*: @option */ QObject::tr("Sendmail");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11", \
"Sendmail"); valuesEmailClient.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("kmail");
- choice.label = /*: @option */ QObject::tr("KMail");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11", \
"KMail"); valuesEmailClient.append( choice );
}
mEmailClientItem = new MyPrefs::ItemEnum( currentGroup(), QLatin1String( \
"EmailClient" ), mEmailClient, valuesEmailClient, kmail );
- mEmailClientItem->setLabel( /*: @label */ QObject::tr("Email client") );
- mEmailClientItem->setWhatsThis( /*: @info:whatsthis */ \
QObject::tr("<para>How to send email when an email alarm is \
triggered.<list><item>KMail: The email is sent automatically via \
<application>KMail</application>. <application>KMail</application> is \
started first if necessary.</item><item>Sendmail: The email is sent \
automatically. This option will only work if your system is configured to \
use <application>sendmail</application> or a sendmail compatible mail \
transport agent.</item></list></para>") ); + mEmailClientItem->setLabel( \
/*: @label */ QCoreApplication::translate("Test11", "Email client") ); + \
mEmailClientItem->setWhatsThis( /*: @info:whatsthis */ \
QCoreApplication::translate("Test11", "<para>How to send email when an \
email alarm is triggered.<list><item>KMail: The email is sent automatically \
via <application>KMail</application>. <application>KMail</application> is \
started first if necessary.</item><item>Sendmail: The email is sent \
automatically. This option will only work if your system is configured to \
use <application>sendmail</application> or a sendmail compatible mail \
transport agent.</item></list></para>") ); addItem( mEmailClientItem, \
QLatin1String( "EmailClient" ) ); QList<MyPrefs::ItemEnum::Choice> \
valuesDefaultReminderUnits; {
@@ -117,13 +117,13 @@ Test11::Test11( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("HoursMinutes");
- choice.label = /*: @option */ QObject::tr("Hours/Minutes");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11", \
"Hours/Minutes"); valuesDefaultReminderUnits.append( choice );
}
mDefaultReminderUnitsItem = new MyPrefs::ItemEnum( currentGroup(), \
QLatin1String( "RemindUnits" ), mDefaultReminderUnits, \
valuesDefaultReminderUnits, TimePeriod::HoursMinutes );
- mDefaultReminderUnitsItem->setLabel( /*: @label */ QObject::tr("Reminder \
units") );
- mDefaultReminderUnitsItem->setToolTip( /*: @info:tooltip */ \
QObject::tr("Default reminder time units in the alarm edit \
dialog.") );
- mDefaultReminderUnitsItem->setWhatsThis( /*: @info:whatsthis */ \
QObject::tr("Default reminder time units in the alarm edit dialog.") ); + \
mDefaultReminderUnitsItem->setLabel( /*: @label */ \
QCoreApplication::translate("Test11", "Reminder units") ); + \
mDefaultReminderUnitsItem->setToolTip( /*: @info:tooltip */ \
QCoreApplication::translate("Test11", "Default reminder time units in the \
alarm edit dialog.") ); + mDefaultReminderUnitsItem->setWhatsThis( /*: \
@info:whatsthis */ QCoreApplication::translate("Test11", "Default reminder \
time units in the alarm edit dialog.") ); addItem( \
mDefaultReminderUnitsItem, QLatin1String( "DefaultReminderUnits" ) );
setCurrentGroup( QLatin1String( "QueueRates" ) );
@@ -151,16 +151,16 @@ Test11::Test11( )
QList<int> defaultqueueRate;
mQueueRateItem[0] = new MyPrefs::ItemIntList( currentGroup(), \
QLatin1String( "EmptyingRate 0" ), mQueueRate[0], \
defaultRate[0] );
- mQueueRateItem[0]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[0]->setLabel( \
QCoreApplication::translate("Test11", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[0], QLatin1String( \
"queueRate0" ) ); mQueueRateItem[1] = new MyPrefs::ItemIntList( \
currentGroup(), QLatin1String( "EmptyingRate 1" ), mQueueRate[1], \
defaultqueueRate );
- mQueueRateItem[1]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[1]->setLabel( \
QCoreApplication::translate("Test11", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[1], QLatin1String( \
"queueRate1" ) ); mQueueRateItem[2] = new MyPrefs::ItemIntList( \
currentGroup(), QLatin1String( "EmptyingRate 2" ), mQueueRate[2], \
defaultRate[2] );
- mQueueRateItem[2]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[2]->setLabel( \
QCoreApplication::translate("Test11", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[2], QLatin1String( \
"queueRate2" ) ); mShowQueueTunerItem = new MyPrefs::ItemBool( \
currentGroup(), QLatin1String( "ShowQueueTuner" ), mShowQueueTuner, false \
);
- mShowQueueTunerItem->setLabel( QObject::tr("ShowQueueTuner") );
+ mShowQueueTunerItem->setLabel( QCoreApplication::translate("Test11", \
"ShowQueueTuner") ); addItem( mShowQueueTunerItem, QLatin1String( \
"ShowQueueTuner" ) ); }
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test11.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test11.h.ref index \
11a4a29..b5eeb74 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test11.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test11.h.ref
@@ -7,6 +7,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
#include "test11_types.h"
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test11a.cpp.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test11a.cpp.ref index \
03c9c13..f826fc1 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test11a.cpp.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test11a.cpp.ref
@@ -9,17 +9,17 @@ Test11a::Test11a( )
setCurrentGroup( QLatin1String( "General" ) );
mAutoSaveItem = new MyPrefs::ItemBool( currentGroup(), QLatin1String( \
"Auto Save" ), mAutoSave, false );
- mAutoSaveItem->setLabel( QObject::tr("Enable automatic saving of \
calendar") );
- mAutoSaveItem->setWhatsThis( QObject::tr("WhatsThis text for AutoSave \
option") ); + mAutoSaveItem->setLabel( \
QCoreApplication::translate("Test11a", "Enable automatic saving of \
calendar") ); + mAutoSaveItem->setWhatsThis( \
QCoreApplication::translate("Test11a", "WhatsThis text for AutoSave \
option") ); addItem( mAutoSaveItem, QLatin1String( "AutoSave" ) );
mAutoSaveIntervalItem = new MyPrefs::ItemInt( currentGroup(), \
QLatin1String( "Auto Save Interval" ), mAutoSaveInterval, \
10 );
- mAutoSaveIntervalItem->setLabel( QObject::tr("Auto Save Interval") );
+ mAutoSaveIntervalItem->setLabel( QCoreApplication::translate("Test11a", \
"Auto Save Interval") ); addItem( mAutoSaveIntervalItem, QLatin1String( \
"AutoSaveInterval" ) ); mConfirmItem = new MyPrefs::ItemBool( \
currentGroup(), QLatin1String( "Confirm Deletes" ), \
mConfirm, true );
- mConfirmItem->setLabel( QObject::tr("Confirm deletes") );
+ mConfirmItem->setLabel( QCoreApplication::translate("Test11a", "Confirm \
deletes") ); addItem( mConfirmItem, QLatin1String( "Confirm" ) );
mArchiveFileItem = new MyPrefs::ItemString( currentGroup(), \
QLatin1String( "Archive File" ), mArchiveFile );
- mArchiveFileItem->setLabel( QObject::tr("Archive File") );
+ mArchiveFileItem->setLabel( QCoreApplication::translate("Test11a", \
"Archive File") ); addItem( mArchiveFileItem, QLatin1String( "ArchiveFile" \
) ); QList<MyPrefs::ItemEnum::Choice> valuesDestination;
{
@@ -35,33 +35,33 @@ Test11a::Test11a( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl1");
- choice.label = QObject::tr("Argl1 Label");
+ choice.label = QCoreApplication::translate("Test11a", "Argl1 Label");
valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl2");
- choice.whatsThis = QObject::tr("Argl2 Whatsthis");
+ choice.whatsThis = QCoreApplication::translate("Test11a", "Argl2 \
Whatsthis"); valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl3");
- choice.label = QObject::tr("Argl3 Label");
- choice.whatsThis = QObject::tr("Argl3 Whatsthis");
+ choice.label = QCoreApplication::translate("Test11a", "Argl3 Label");
+ choice.whatsThis = QCoreApplication::translate("Test11a", "Argl3 \
Whatsthis"); valuesDestination.append( choice );
}
mDestinationItem = new MyPrefs::ItemEnum( currentGroup(), QLatin1String( \
"Destination" ), mDestination, valuesDestination, \
EnumDestination::standardDestination );
- mDestinationItem->setLabel( QObject::tr("New Events/Todos Should") );
+ mDestinationItem->setLabel( QCoreApplication::translate("Test11a", "New \
Events/Todos Should") ); addItem( mDestinationItem, QLatin1String( \
"Destination" ) );
setCurrentGroup( QLatin1String( "Views" ) );
mHourSizeItem = new MyPrefs::ItemInt( currentGroup(), QLatin1String( \
"Hour Size" ), mHourSize, 10 );
- mHourSizeItem->setLabel( QObject::tr("Hour Size") );
+ mHourSizeItem->setLabel( QCoreApplication::translate("Test11a", "Hour \
Size") ); addItem( mHourSizeItem, QLatin1String( "HourSize" ) );
mSelectionStartsEditorItem = new MyPrefs::ItemBool( currentGroup(), \
QLatin1String( "SelectionStartsEditor" ), \
mSelectionStartsEditor, false );
- mSelectionStartsEditorItem->setLabel( QObject::tr("Time range selection \
in agenda view starts event editor") ); + \
mSelectionStartsEditorItem->setLabel( \
QCoreApplication::translate("Test11a", "Time range selection in agenda view \
starts event editor") ); addItem( mSelectionStartsEditorItem, \
QLatin1String( "SelectionStartsEditor" ) );
setCurrentGroup( QLatin1String( "KOrganizer Plugins" ) );
@@ -71,22 +71,22 @@ Test11a::Test11a( )
defaultSelectedPlugins.append( QString::fromUtf8( "webexport" ) );
mSelectedPluginsItem = new MyPrefs::ItemStringList( currentGroup(), \
QLatin1String( "SelectedPlugins" ), mSelectedPlugins, \
defaultSelectedPlugins );
- mSelectedPluginsItem->setLabel( QObject::tr("SelectedPlugins") );
+ mSelectedPluginsItem->setLabel( QCoreApplication::translate("Test11a", \
"SelectedPlugins") ); addItem( mSelectedPluginsItem, QLatin1String( \
"SelectedPlugins" ) );
setCurrentGroup( QLatin1String( "Colors" ) );
mHighlightColorItem = new MyPrefs::ItemColor( currentGroup(), \
QLatin1String( "Highlight Color" ), mHighlightColor, QColor( 100, 100, 255 \
) );
- mHighlightColorItem->setLabel( QObject::tr("Highlight color") );
+ mHighlightColorItem->setLabel( QCoreApplication::translate("Test11a", \
"Highlight color") ); addItem( mHighlightColorItem, QLatin1String( \
"HighlightColor" ) ); mAgendaBgColorItem = new MyPrefs::ItemColor( \
currentGroup(), QLatin1String( "Agenda Background Color" ), mAgendaBgColor, \
QColor( 255, 255, 255 ) );
- mAgendaBgColorItem->setLabel( QObject::tr("Agenda view background \
color") ); + mAgendaBgColorItem->setLabel( \
QCoreApplication::translate("Test11a", "Agenda view background color") ); \
addItem( mAgendaBgColorItem, QLatin1String( "AgendaBgColor" ) );
setCurrentGroup( QLatin1String( "Fonts" ) );
mTimeBarFontItem = new MyPrefs::ItemFont( currentGroup(), QLatin1String( \
"TimeBar Font" ), mTimeBarFont );
- mTimeBarFontItem->setLabel( QObject::tr("Time bar") );
+ mTimeBarFontItem->setLabel( QCoreApplication::translate("Test11a", "Time \
bar") ); addItem( mTimeBarFontItem, QLatin1String( "TimeBarFont" ) );
setCurrentGroup( QLatin1String( "Email" ) );
@@ -95,18 +95,18 @@ Test11a::Test11a( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("sendmail");
- choice.label = /*: @option */ QObject::tr("Sendmail");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11a", \
"Sendmail"); valuesEmailClient.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("kmail");
- choice.label = /*: @option */ QObject::tr("KMail");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11a", \
"KMail"); valuesEmailClient.append( choice );
}
mEmailClientItem = new MyPrefs::ItemEnum( currentGroup(), QLatin1String( \
"EmailClient" ), mEmailClient, valuesEmailClient, kmail );
- mEmailClientItem->setLabel( /*: @label */ QObject::tr("Email client") );
- mEmailClientItem->setWhatsThis( /*: @info:whatsthis */ \
QObject::tr("<para>How to send email when an email alarm is \
triggered.<list><item>KMail: The email is sent automatically via \
<application>KMail</application>. <application>KMail</application> is \
started first if necessary.</item><item>Sendmail: The email is sent \
automatically. This option will only work if your system is configured to \
use <application>sendmail</application> or a sendmail compatible mail \
transport agent.</item></list></para>") ); + mEmailClientItem->setLabel( \
/*: @label */ QCoreApplication::translate("Test11a", "Email client") ); + \
mEmailClientItem->setWhatsThis( /*: @info:whatsthis */ \
QCoreApplication::translate("Test11a", "<para>How to send email when an \
email alarm is triggered.<list><item>KMail: The email is sent automatically \
via <application>KMail</application>. <application>KMail</application> is \
started first if necessary.</item><item>Sendmail: The email is sent \
automatically. This option will only work if your system is configured to \
use <application>sendmail</application> or a sendmail compatible mail \
transport agent.</item></list></para>") ); addItem( mEmailClientItem, \
QLatin1String( "EmailClient" ) ); QList<MyPrefs::ItemEnum::Choice> \
valuesDefaultReminderUnits; {
@@ -117,12 +117,12 @@ Test11a::Test11a( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("HoursMinutes");
- choice.label = /*: @option */ QObject::tr("Hours/Minutes");
+ choice.label = /*: @option */ QCoreApplication::translate("Test11a", \
"Hours/Minutes"); valuesDefaultReminderUnits.append( choice );
}
mDefaultReminderUnitsItem = new MyPrefs::ItemEnum( currentGroup(), \
QLatin1String( "RemindUnits" ), mDefaultReminderUnits, \
valuesDefaultReminderUnits, TimePeriod::HoursMinutes );
- mDefaultReminderUnitsItem->setLabel( /*: @label */ QObject::tr("Reminder \
units") );
- mDefaultReminderUnitsItem->setWhatsThis( /*: @info:whatsthis */ \
QObject::tr("Default reminder time units in the alarm edit dialog.") ); + \
mDefaultReminderUnitsItem->setLabel( /*: @label */ \
QCoreApplication::translate("Test11a", "Reminder units") ); + \
mDefaultReminderUnitsItem->setWhatsThis( /*: @info:whatsthis */ \
QCoreApplication::translate("Test11a", "Default reminder time units in the \
alarm edit dialog.") ); addItem( mDefaultReminderUnitsItem, QLatin1String( \
"DefaultReminderUnits" ) );
setCurrentGroup( QLatin1String( "QueueRates" ) );
@@ -150,16 +150,16 @@ Test11a::Test11a( )
QList<int> defaultqueueRate;
mQueueRateItem[0] = new MyPrefs::ItemIntList( currentGroup(), \
QLatin1String( "EmptyingRate 0" ), mQueueRate[0], \
defaultRate[0] );
- mQueueRateItem[0]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[0]->setLabel( \
QCoreApplication::translate("Test11a", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[0], QLatin1String( \
"queueRate0" ) ); mQueueRateItem[1] = new MyPrefs::ItemIntList( \
currentGroup(), QLatin1String( "EmptyingRate 1" ), mQueueRate[1], \
defaultqueueRate );
- mQueueRateItem[1]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[1]->setLabel( \
QCoreApplication::translate("Test11a", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[1], QLatin1String( \
"queueRate1" ) ); mQueueRateItem[2] = new MyPrefs::ItemIntList( \
currentGroup(), QLatin1String( "EmptyingRate 2" ), mQueueRate[2], \
defaultRate[2] );
- mQueueRateItem[2]->setLabel( QObject::tr("EmptyingRate \
queueRate$(QueueIndex)") ); + mQueueRateItem[2]->setLabel( \
QCoreApplication::translate("Test11a", "EmptyingRate \
queueRate$(QueueIndex)") ); addItem( mQueueRateItem[2], QLatin1String( \
"queueRate2" ) ); mShowQueueTunerItem = new MyPrefs::ItemBool( \
currentGroup(), QLatin1String( "ShowQueueTuner" ), mShowQueueTuner, false \
);
- mShowQueueTunerItem->setLabel( QObject::tr("ShowQueueTuner") );
+ mShowQueueTunerItem->setLabel( QCoreApplication::translate("Test11a", \
"ShowQueueTuner") ); addItem( mShowQueueTunerItem, QLatin1String( \
"ShowQueueTuner" ) ); }
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test11a.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test11a.h.ref index \
14ac4c3..4410ce2 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test11a.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test11a.h.ref
@@ -7,6 +7,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
#include "test11_types.h"
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test12.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test12.h.ref index \
c2006f7..74f7ead 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test12.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test12.h.ref
@@ -5,6 +5,7 @@
#include <kglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test12 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test2.cpp.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test2.cpp.ref index \
705a78b..476b34c 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test2.cpp.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test2.cpp.ref
@@ -9,17 +9,17 @@ Test2::Test2( )
setCurrentGroup( QLatin1String( "General" ) );
mAutoSaveItem = new MyPrefs::ItemBool( currentGroup(), QLatin1String( \
"Auto Save" ), mAutoSave, false );
- mAutoSaveItem->setLabel( QObject::tr("Enable automatic saving of \
calendar") );
- mAutoSaveItem->setWhatsThis( QObject::tr("WhatsThis text for AutoSave \
option") ); + mAutoSaveItem->setLabel( \
QCoreApplication::translate("Test2", "Enable automatic saving of calendar") \
); + mAutoSaveItem->setWhatsThis( QCoreApplication::translate("Test2", \
"WhatsThis text for AutoSave option") ); addItem( mAutoSaveItem, \
QLatin1String( "AutoSave" ) ); mAutoSaveIntervalItem = new \
MyPrefs::ItemInt( currentGroup(), QLatin1String( "Auto Save Interval" ), \
mAutoSaveInterval, 10 );
- mAutoSaveIntervalItem->setLabel( QObject::tr("Auto Save Interval") );
+ mAutoSaveIntervalItem->setLabel( QCoreApplication::translate("Test2", \
"Auto Save Interval") ); addItem( mAutoSaveIntervalItem, QLatin1String( \
"AutoSaveInterval" ) ); mConfirmItem = new MyPrefs::ItemBool( \
currentGroup(), QLatin1String( "Confirm Deletes" ), \
mConfirm, true );
- mConfirmItem->setLabel( QObject::tr("Confirm deletes") );
+ mConfirmItem->setLabel( QCoreApplication::translate("Test2", "Confirm \
deletes") ); addItem( mConfirmItem, QLatin1String( "Confirm" ) );
mArchiveFileItem = new MyPrefs::ItemString( currentGroup(), \
QLatin1String( "Archive File" ), mArchiveFile );
- mArchiveFileItem->setLabel( QObject::tr("Archive File") );
+ mArchiveFileItem->setLabel( QCoreApplication::translate("Test2", \
"Archive File") ); addItem( mArchiveFileItem, QLatin1String( "ArchiveFile" \
) ); QList<MyPrefs::ItemEnum::Choice> valuesDestination;
{
@@ -35,33 +35,33 @@ Test2::Test2( )
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl1");
- choice.label = QObject::tr("Argl1 Label");
+ choice.label = QCoreApplication::translate("Test2", "Argl1 Label");
valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl2");
- choice.whatsThis = QObject::tr("Argl2 Whatsthis");
+ choice.whatsThis = QCoreApplication::translate("Test2", "Argl2 \
Whatsthis"); valuesDestination.append( choice );
}
{
MyPrefs::ItemEnum::Choice choice;
choice.name = QLatin1String("argl3");
- choice.label = QObject::tr("Argl3 Label");
- choice.whatsThis = QObject::tr("Argl3 Whatsthis");
+ choice.label = QCoreApplication::translate("Test2", "Argl3 Label");
+ choice.whatsThis = QCoreApplication::translate("Test2", "Argl3 \
Whatsthis"); valuesDestination.append( choice );
}
mDestinationItem = new MyPrefs::ItemEnum( currentGroup(), QLatin1String( \
"Destination" ), mDestination, valuesDestination, \
standardDestination );
- mDestinationItem->setLabel( QObject::tr("New Events/Todos Should") );
+ mDestinationItem->setLabel( QCoreApplication::translate("Test2", "New \
Events/Todos Should") ); addItem( mDestinationItem, QLatin1String( \
"Destination" ) );
setCurrentGroup( QLatin1String( "Views" ) );
mHourSizeItem = new MyPrefs::ItemInt( currentGroup(), QLatin1String( \
"Hour Size" ), mHourSize, 10 );
- mHourSizeItem->setLabel( QObject::tr("Hour Size") );
+ mHourSizeItem->setLabel( QCoreApplication::translate("Test2", "Hour \
Size") ); addItem( mHourSizeItem, QLatin1String( "HourSize" ) );
mSelectionStartsEditorItem = new MyPrefs::ItemBool( currentGroup(), \
QLatin1String( "SelectionStartsEditor" ), \
mSelectionStartsEditor, false );
- mSelectionStartsEditorItem->setLabel( QObject::tr("Time range selection \
in agenda view starts event editor") ); + \
mSelectionStartsEditorItem->setLabel( QCoreApplication::translate("Test2", \
"Time range selection in agenda view starts event editor") ); addItem( \
mSelectionStartsEditorItem, QLatin1String( "SelectionStartsEditor" ) );
setCurrentGroup( QLatin1String( "KOrganizer Plugins" ) );
@@ -71,22 +71,22 @@ Test2::Test2( )
defaultSelectedPlugins.append( QString::fromUtf8( "webexport" ) );
mSelectedPluginsItem = new MyPrefs::ItemStringList( currentGroup(), \
QLatin1String( "SelectedPlugins" ), mSelectedPlugins, \
defaultSelectedPlugins );
- mSelectedPluginsItem->setLabel( QObject::tr("SelectedPlugins") );
+ mSelectedPluginsItem->setLabel( QCoreApplication::translate("Test2", \
"SelectedPlugins") ); addItem( mSelectedPluginsItem, QLatin1String( \
"SelectedPlugins" ) );
setCurrentGroup( QLatin1String( "Colors" ) );
mHighlightColorItem = new MyPrefs::ItemColor( currentGroup(), \
QLatin1String( "Highlight Color" ), mHighlightColor, QColor( 100, 100, 255 \
) );
- mHighlightColorItem->setLabel( QObject::tr("Highlight color") );
+ mHighlightColorItem->setLabel( QCoreApplication::translate("Test2", \
"Highlight color") ); addItem( mHighlightColorItem, QLatin1String( \
"HighlightColor" ) ); mAgendaBgColorItem = new MyPrefs::ItemColor( \
currentGroup(), QLatin1String( "Agenda Background Color" ), mAgendaBgColor, \
QColor( 255, 255, 255 ) );
- mAgendaBgColorItem->setLabel( QObject::tr("Agenda view background \
color") ); + mAgendaBgColorItem->setLabel( \
QCoreApplication::translate("Test2", "Agenda view background color") ); \
addItem( mAgendaBgColorItem, QLatin1String( "AgendaBgColor" ) );
setCurrentGroup( QLatin1String( "Fonts" ) );
mTimeBarFontItem = new MyPrefs::ItemFont( currentGroup(), QLatin1String( \
"TimeBar Font" ), mTimeBarFont );
- mTimeBarFontItem->setLabel( QObject::tr("Time bar") );
+ mTimeBarFontItem->setLabel( QCoreApplication::translate("Test2", "Time \
bar") ); addItem( mTimeBarFontItem, QLatin1String( "TimeBarFont" ) );
}
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test2.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test2.h.ref index \
cb59d66..49af161 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test2.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test2.h.ref
@@ -7,6 +7,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test2 : public MyPrefs
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test3.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test3.h.ref index \
25f49b9..931e2e2 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test3.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test3.h.ref
@@ -5,6 +5,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
namespace TestNameSpace {
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test3a.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test3a.h.ref index \
4a52cc6..56d672a 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test3a.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test3a.h.ref
@@ -5,6 +5,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
namespace TestNameSpace {
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test4.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test4.h.ref index \
a8c503e..991a4f7 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test4.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test4.h.ref
@@ -4,6 +4,7 @@
#define TEST4_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test4 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test5.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test5.h.ref index \
619597a..46a591c 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test5.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test5.h.ref
@@ -4,6 +4,7 @@
#define TEST5_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test5 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test6.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test6.h.ref index \
498f158..f1fb59f 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test6.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test6.h.ref
@@ -4,6 +4,7 @@
#define TEST6_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test6 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test7.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test7.h.ref index \
f0e8147..417c75a 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test7.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test7.h.ref
@@ -4,6 +4,7 @@
#define TEST7_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test7 : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test8a.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test8a.h.ref index \
48983f5..fd1b364 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test8a.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test8a.h.ref
@@ -5,6 +5,7 @@
#include <qglobal.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test8a : public KConfigSkeleton
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test8b.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test8b.h.ref index \
aef0e73..140bbb9 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test8b.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test8b.h.ref
@@ -6,6 +6,7 @@
#include <test8a.h>
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class Test8b : public Test8a
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test9.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test9.h.ref index \
7785981..02b3d47 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test9.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test9.h.ref
@@ -4,6 +4,7 @@
#define TEST9_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
#include <qdir.h>
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.cpp.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.cpp.ref index \
bca229d..ffe931e 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.cpp.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.cpp.ref
@@ -72,17 +72,17 @@ TestDPointer::TestDPointer( )
setCurrentGroup( QLatin1String( "General" ) );
d->autoSaveItem = new KConfigSkeleton::ItemBool( currentGroup(), \
QLatin1String( "Auto Save" ), d->autoSave, false );
- d->autoSaveItem->setLabel( QObject::tr("Enable automatic saving of \
calendar") );
- d->autoSaveItem->setWhatsThis( QObject::tr("WhatsThis text for AutoSave \
option") ); + d->autoSaveItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Enable automatic saving of \
calendar") ); + d->autoSaveItem->setWhatsThis( \
QCoreApplication::translate("TestDPointer", "WhatsThis text for AutoSave \
option") ); addItem( d->autoSaveItem, QLatin1String( "AutoSave" ) );
d->autoSaveIntervalItem = new KConfigSkeleton::ItemInt( currentGroup(), \
QLatin1String( "Auto Save Interval" ), d->autoSaveInterval, \
10 );
- d->autoSaveIntervalItem->setLabel( QObject::tr("Auto Save Interval") );
+ d->autoSaveIntervalItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Auto Save Interval") ); \
addItem( d->autoSaveIntervalItem, QLatin1String( "AutoSaveInterval" ) ); \
d->confirmItem = new KConfigSkeleton::ItemBool( currentGroup(), \
QLatin1String( "Confirm Deletes" ), d->confirm, true );
- d->confirmItem->setLabel( QObject::tr("Confirm deletes") );
+ d->confirmItem->setLabel( QCoreApplication::translate("TestDPointer", \
"Confirm deletes") ); addItem( d->confirmItem, QLatin1String( "Confirm" ) \
); d->archiveFileItem = new KConfigSkeleton::ItemString( currentGroup(), \
QLatin1String( "Archive File" ), d->archiveFile );
- d->archiveFileItem->setLabel( QObject::tr("Archive File") );
+ d->archiveFileItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Archive File") ); addItem( \
d->archiveFileItem, QLatin1String( "ArchiveFile" ) ); \
QList<KConfigSkeleton::ItemEnum::Choice> valuesDestination; {
@@ -98,33 +98,33 @@ TestDPointer::TestDPointer( )
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QLatin1String("argl1");
- choice.label = QObject::tr("Argl1 Label");
+ choice.label = QCoreApplication::translate("TestDPointer", "Argl1 \
Label"); valuesDestination.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QLatin1String("argl2");
- choice.whatsThis = QObject::tr("Argl2 Whatsthis");
+ choice.whatsThis = QCoreApplication::translate("TestDPointer", "Argl2 \
Whatsthis"); valuesDestination.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QLatin1String("argl3");
- choice.label = QObject::tr("Argl3 Label");
- choice.whatsThis = QObject::tr("Argl3 Whatsthis");
+ choice.label = QCoreApplication::translate("TestDPointer", "Argl3 \
Label"); + choice.whatsThis = \
QCoreApplication::translate("TestDPointer", "Argl3 Whatsthis"); \
valuesDestination.append( choice ); }
d->destinationItem = new KConfigSkeleton::ItemEnum( currentGroup(), \
QLatin1String( "Destination" ), d->destination, valuesDestination, \
EnumDestination::standardDestination );
- d->destinationItem->setLabel( QObject::tr("New Events/Todos Should") );
+ d->destinationItem->setLabel( \
QCoreApplication::translate("TestDPointer", "New Events/Todos Should") ); \
addItem( d->destinationItem, QLatin1String( "Destination" ) );
setCurrentGroup( QLatin1String( "Views" ) );
d->hourSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), \
QLatin1String( "Hour Size" ), d->hourSize, 10 );
- d->hourSizeItem->setLabel( QObject::tr("Hour Size") );
+ d->hourSizeItem->setLabel( QCoreApplication::translate("TestDPointer", \
"Hour Size") ); addItem( d->hourSizeItem, QLatin1String( "HourSize" ) );
d->selectionStartsEditorItem = new KConfigSkeleton::ItemBool( \
currentGroup(), QLatin1String( "SelectionStartsEditor" ), \
d->selectionStartsEditor, false );
- d->selectionStartsEditorItem->setLabel( QObject::tr("Time range \
selection in agenda view starts event editor") ); + \
d->selectionStartsEditorItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Time range selection in agenda \
view starts event editor") ); addItem( d->selectionStartsEditorItem, \
QLatin1String( "SelectionStartsEditor" ) );
setCurrentGroup( QLatin1String( "KOrganizer Plugins" ) );
@@ -134,22 +134,22 @@ TestDPointer::TestDPointer( )
defaultSelectedPlugins.append( QString::fromUtf8( "webexport" ) );
d->selectedPluginsItem = new KConfigSkeleton::ItemStringList( \
currentGroup(), QLatin1String( "SelectedPlugins" ), d->selectedPlugins, \
defaultSelectedPlugins );
- d->selectedPluginsItem->setLabel( QObject::tr("SelectedPlugins") );
+ d->selectedPluginsItem->setLabel( \
QCoreApplication::translate("TestDPointer", "SelectedPlugins") ); addItem( \
d->selectedPluginsItem, QLatin1String( "SelectedPlugins" ) );
setCurrentGroup( QLatin1String( "Colors" ) );
d->highlightColorItem = new KConfigSkeleton::ItemColor( currentGroup(), \
QLatin1String( "Highlight Color" ), d->highlightColor, QColor( 100, 100, \
255 ) );
- d->highlightColorItem->setLabel( QObject::tr("Highlight color") );
+ d->highlightColorItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Highlight color") ); addItem( \
d->highlightColorItem, QLatin1String( "HighlightColor" ) ); \
d->agendaBgColorItem = new KConfigSkeleton::ItemColor( currentGroup(), \
QLatin1String( "Agenda Background Color" ), d->agendaBgColor, QColor( 255, \
255, 255 ) );
- d->agendaBgColorItem->setLabel( QObject::tr("Agenda view background \
color") ); + d->agendaBgColorItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Agenda view background color") \
); addItem( d->agendaBgColorItem, QLatin1String( "AgendaBgColor" ) );
setCurrentGroup( QLatin1String( "Fonts" ) );
d->timeBarFontItem = new KConfigSkeleton::ItemFont( currentGroup(), \
QLatin1String( "TimeBar Font" ), d->timeBarFont );
- d->timeBarFontItem->setLabel( QObject::tr("Time bar") );
+ d->timeBarFontItem->setLabel( \
QCoreApplication::translate("TestDPointer", "Time bar") ); addItem( \
d->timeBarFontItem, QLatin1String( "TimeBarFont" ) ); }
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.h.ref index \
12af86d..e10c8c7 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test_dpointer.h.ref
@@ -4,6 +4,7 @@
#define TESTDPOINTER_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class TestDPointerPrivate;
diff --git a/tier1/kconfig/autotests/kconfig_compiler/test_signal.h.ref \
b/tier1/kconfig/autotests/kconfig_compiler/test_signal.h.ref index \
1c0d443..801ff92 100644
--- a/tier1/kconfig/autotests/kconfig_compiler/test_signal.h.ref
+++ b/tier1/kconfig/autotests/kconfig_compiler/test_signal.h.ref
@@ -4,6 +4,7 @@
#define TESTSIGNAL_H
#include <kconfigskeleton.h>
+#include <QCoreApplication>
#include <QDebug>
class TestSignal : public KConfigSkeleton
diff --git a/tier1/kconfig/src/kconfig_compiler/kconfig_compiler.cpp \
b/tier1/kconfig/src/kconfig_compiler/kconfig_compiler.cpp index \
e6b4e9a..ae192ee 100644
--- a/tier1/kconfig/src/kconfig_compiler/kconfig_compiler.cpp
+++ b/tier1/kconfig/src/kconfig_compiler/kconfig_compiler.cpp
@@ -1122,10 +1122,11 @@ QString translatedString(const CfgConfig &cfg, \
const QString &string, const QStr switch (cfg.translationSystem) {
case CfgConfig::QtTranslation:
if (!context.isEmpty()) {
- result+= "/*: " + context + " */ QObject::tr(";
+ result+= "/*: " + context + " */ \
QCoreApplication::translate(\""; } else {
- result+= "QObject::tr(";
+ result+= "QCoreApplication::translate(\"";
}
+ result+= cfg.className + "\", ";
break;
case CfgConfig::KdeTranslation:
@@ -1545,6 +1546,7 @@ int main( int argc, char **argv )
h << "#include <kconfigskeleton.h>" << endl;
}
+ h << "#include <QCoreApplication>" << endl;
h << "#include <QDebug>" << endl << endl;
// Includes
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic