Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
KAlarm
Commits
67f60a89
Commit
67f60a89
authored
Oct 23, 2011
by
David Jarvie
Browse files
Load library's message catalog
parent
20c8731a
Changes
1
Hide whitespace changes
Inline
Side-by-side
kacalendar.cpp
View file @
67f60a89
...
...
@@ -39,7 +39,6 @@
#include <kcal/calendarlocal.h>
#endif
#include <kglobal.h>
#include <klocale.h>
#include <kdebug.h>
...
...
@@ -56,6 +55,8 @@ using namespace KCal;
#endif
static
const
KCatalogLoader
loader
(
"libkalarmcal"
);
namespace
KAlarmCal
{
...
...
@@ -79,14 +80,11 @@ class Private
#else
static
int
readKAlarmVersion
(
CalendarLocal
&
,
const
QString
&
localFile
,
QString
&
subVersion
,
QString
&
versionString
);
#endif
static
void
insertKAlarmCatalog
();
static
QByteArray
mIcalProductId
;
static
bool
mHaveKAlarmCatalog
;
};
QByteArray
Private
::
mIcalProductId
;
bool
Private
::
mHaveKAlarmCatalog
=
false
;
namespace
KACalendar
...
...
@@ -246,7 +244,6 @@ int Private::readKAlarmVersion(CalendarLocal& calendar, const QString& localFile
{
// Older versions used KAlarm's translated name in the product ID, which
// could have created problems using a calendar in different locales.
Private
::
insertKAlarmCatalog
();
progname
=
QString
(
" "
)
+
i18n
(
"KAlarm"
)
+
' '
;
i
=
prodid
.
indexOf
(
progname
,
0
,
Qt
::
CaseInsensitive
);
if
(
i
<
0
)
...
...
@@ -271,18 +268,6 @@ int Private::readKAlarmVersion(CalendarLocal& calendar, const QString& localFile
return
KAlarmCal
::
getVersionNumber
(
versionString
,
&
subVersion
);
}
/******************************************************************************
* Access the KAlarm message translation catalog.
*/
void
Private
::
insertKAlarmCatalog
()
{
if
(
!
mHaveKAlarmCatalog
)
{
KGlobal
::
locale
()
->
insertCatalog
(
"kalarm"
);
mHaveKAlarmCatalog
=
true
;
}
}
/******************************************************************************
* Check whether the calendar file has its times stored as UTC times,
* indicating that it was written by the KDE 3.0.0 version of KAlarm 0.5.7.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment