Prepare for kde translations.

This commit is contained in:
Patrick von Reth 2015-08-24 17:48:08 +02:00
parent 58f42b68ee
commit de33e8e913
9 changed files with 18 additions and 862 deletions

View File

@ -24,6 +24,7 @@ include(ECMInstallIcons)
include(ECMMarkNonGuiExecutable)
include(ECMOptionalAddSubdirectory)
include(ECMPackageConfigHelpers)
include(ECMPoQmTools)
include(ECMSetupVersion)
@ -40,25 +41,6 @@ find_package(Qt5Network REQUIRED)
find_package(Qt5Widgets REQUIRED)
find_package(Doxygen QUIET)
set_package_properties(Doxygen PROPERTIES
DESCRIPTION "Doxygen a tool for generating documentation."
URL "http://www.stack.nl/~dimitri/doxygen/"
PURPOSE "Generation of API documentation"
TYPE OPTIONAL)
if(DOXYGEN_FOUND)
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in" "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile" @ONLY)
add_custom_target(doc
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Generating API documentation with Doxygen" VERBATIM
)
endif()
set(LIBSNORE_PLUGIN_PATH ${KDE_INSTALL_PLUGINDIR}/libsnore${SNORE_SUFFIX})
set(SNORE_PLUGIN_INSTALL_PATH LIBRARY DESTINATION ${LIBSNORE_PLUGIN_PATH})
message(STATUS "Installing plugins to ${LIBSNORE_PLUGIN_PATH}")
@ -67,9 +49,12 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin)
add_subdirectory(data)
add_subdirectory(lang)
add_subdirectory(src)
add_subdirectory(autotest)
if (IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/po")
ecm_install_po_files_as_qm(po)
endif()
feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES)

View File

@ -1,25 +0,0 @@
find_package(Qt5LinguistTools QUIET)
set_package_properties(Qt5LinguistTools PROPERTIES
PURPOSE "Support for translations."
TYPE OPTIONAL)
if(Qt5LinguistTools_FOUND)
set(LIBSNORE_LANGS de en)
set(TS_FILES )
set( snore_i18n_content "" )
foreach( lang ${LIBSNORE_LANGS} )
list(APPEND TS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/${lang}.ts)
set( snore_i18n_content "${snore_i18n_content}\n\t\t<file>${lang}.qm</file>" )
endforeach()
QT5_CREATE_TRANSLATION(libsnore_lang ${TS_FILES} ${PROJECT_SOURCE_DIR}/src)
configure_file(snore_i18n.qrc.in snore_i18n.qrc @ONLY)
add_custom_target(libsnore_lang_translation ALL DEPENDS ${libsnore_lang})
set(SNORE_RCS ${SNORE_RCS} ${CMAKE_BINARY_DIR}/lang/snore_i18n.qrc PARENT_SCOPE)
endif()

View File

@ -1,382 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="de_CH">
<context>
<name>Default Alert</name>
<message>
<location filename="../src/libsnore/application_p.cpp" line="30"/>
<source>Default</source>
<translation>Standart</translation>
</message>
</context>
<context>
<name>FreedesktopFrontend</name>
<message>
<location filename="../src/plugins/frontends/freedesktop_frontend/freedesktopnotificationfrontend.cpp" line="40"/>
<source>Failed to register dbus object.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/freedesktop_frontend/freedesktopnotificationfrontend.cpp" line="43"/>
<source>Failed to register dbus service.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>GrowlBackend</name>
<message>
<location filename="../src/plugins/backends/growl/growlbackend.cpp" line="70"/>
<source> is not running.</source>
<translation> ist nicht gestartet.</translation>
</message>
</context>
<context>
<name>GrowlSettings</name>
<message>
<location filename="../src/plugins/backends/growl/growlsettings.cpp" line="30"/>
<source>Host:</source>
<translation></translation>
</message>
<message>
<location filename="../src/plugins/backends/growl/growlsettings.cpp" line="31"/>
<source>Password:</source>
<translation>Passwort:</translation>
</message>
</context>
<context>
<name>NotifyMyAndroidSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="29"/>
<source>Api Key:</source>
<translation>Api Schlüssel:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="29"/>
<source>The api key which can be found in your account page at &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt;.</source>
<translation>Der Api Schlüssel welcher auf deiner Account Seite unter &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt; gefunden werden kann.</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="30"/>
<source>If you don&apos;t have an accout yet please register at &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt;.</source>
<translation>Falls du noch keinen Account hast, registriere dich bitte unter &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt;.</translation>
</message>
</context>
<context>
<name>PushoverSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="31"/>
<source>User Key:</source>
<translation>Benutzer Schlüssel:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="31"/>
<source>The user key which can be found on your account page at &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt;.</source>
<translation>Der Benutzerschlüssel den du auf deiner Account Seite unter &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt; finden kannst.</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="32"/>
<source>Sound:</source>
<translation>Klang:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="32"/>
<source>The pushover sound that it played when a notification is recieved.</source>
<translation>Der pushover Klang der beim Erhalten einer Mitteilung abgespielt wird.</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="33"/>
<source>Devices:</source>
<translation>Geräte:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="33"/>
<source>The devices that are to recieve the notifications.</source>
<translation>Die Geräte, die die Mitteilung erhalten werden.</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="36"/>
<source>Email Address:</source>
<translation>Email Adresse:</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="37"/>
<source>Password:</source>
<translation>Passwort:</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="38"/>
<source>Device Name:</source>
<translation>Geräte Name:</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="40"/>
<source>Status</source>
<translation></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="42"/>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="34"/>
<source>If you don&apos;t have an accout yet please register at &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt;</source>
<translation>Wenn Sie noch keinen Account haben, registireren Sie sich bitte unter &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt;</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="88"/>
<source>Log out</source>
<translation>Abmelden</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="89"/>
<source>Logged in.</source>
<translation>Angemeldet.</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="95"/>
<source>Log in</source>
<translation>Anmelden</translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="97"/>
<source>Logged out.</source>
<translation>Abgemeldet.</translation>
</message>
</context>
<context>
<name>SettingsDialog</name>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="14"/>
<source>Settings</source>
<translation>Einstellungen</translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="34"/>
<source>General</source>
<translation>Allgemein</translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="45"/>
<source>Primary Backend:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="55"/>
<source>Timeout:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="62"/>
<source>s</source>
<translation></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="69"/>
<source>Disable Notification Sound:</source>
<translation>Mitteilungs Klang Deaktivieren:</translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="79"/>
<source>Error:</source>
<translation>Fehler:</translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="96"/>
<source>Primary Backends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="106"/>
<source>Secondary Bckends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="116"/>
<source>Frontends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="126"/>
<source>Plugins</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="139"/>
<source>Display Test Notification</source>
<translation>Zeige eine Testmitteilung an</translation>
</message>
</context>
<context>
<name>SettingsWindow</name>
<message>
<location filename="../src/settings/settingswindow.ui" line="14"/>
<source>Snore Settings</source>
<translation>Snore Einstellungen</translation>
</message>
<message>
<location filename="../src/settings/settingswindow.ui" line="27"/>
<source>Application</source>
<translation>Anwendungen</translation>
</message>
</context>
<context>
<name>SnarlBackend</name>
<message>
<location filename="../src/plugins/backends/snarl/snarl.cpp" line="150"/>
<source> is not running.</source>
<translation> ist nicht gestartet.</translation>
</message>
</context>
<context>
<name>SnarlNetworkFrontend</name>
<message>
<location filename="../src/plugins/frontends/snarlnetwork/snarlnetwork.cpp" line="37"/>
<source>The port is already used by a different application.</source>
<translation>Der Port wird bereits von einer anderen Anwendung verwendet.</translation>
</message>
</context>
<context>
<name>SnarlSettings</name>
<message>
<location filename="../src/plugins/backends/snarl/snarlsettings.cpp" line="29"/>
<source>Password:</source>
<translation>Passwort:</translation>
</message>
</context>
<context>
<name>Snore::PluginSettingsWidget</name>
<message>
<location filename="../src/libsnore/plugins/pluginsettingswidget.cpp" line="36"/>
<source>Enabled:</source>
<translation>Aktiv:</translation>
</message>
</context>
<context>
<name>Snore::SnoreCore</name>
<message>
<location filename="../src/libsnore/snore.cpp" line="255"/>
<source>This is </source>
<translation>Dies ist </translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="256"/>
<source>Everything is awesome!</source>
<translation>Alles ist super!</translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="260"/>
<source>Hello There!</source>
<translation>Hallo da!</translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="261"/>
<source>Awesome Action!</source>
<translation>Super Aktion!</translation>
</message>
</context>
<context>
<name>SnoreNotifierSettings</name>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="30"/>
<source>TopLeftCorner</source>
<translation>ObereLinkeEcke</translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="31"/>
<source>TopRightCorner</source>
<translation>ObereRechteEcke</translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="32"/>
<source>BottomLeftCorner</source>
<translation>UntereLinkeEcke</translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="33"/>
<source>BottomRightCorner</source>
<translation>UntereRechteEcke</translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="34"/>
<source>Position:</source>
<translation></translation>
</message>
</context>
<context>
<name>SnoreSend</name>
<message>
<location filename="../src/snoresend/main.cpp" line="138"/>
<source>Bring to Front</source>
<translation>Nach vorne bringen</translation>
</message>
</context>
<context>
<name>SnoreToast</name>
<message>
<location filename="../src/plugins/backends/snoretoast/snoretoast.cpp" line="20"/>
<source> needs at least Windows 8 to run.</source>
<translation> benötigt mindestens Windows 8, um ausgeführt zu werden.</translation>
</message>
</context>
<context>
<name>SoundSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="34"/>
<source>Volume:</source>
<translation>Lautstärke:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="36"/>
<source>Audio file:</source>
<translation>Audio Datei:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="36"/>
<source>The sound played when a notifications is recieved.</source>
<translation>Der Klang der abgespielt wird, wenn eine Mitteilung erhalten wird.</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="37"/>
<source>Select a audio file</source>
<translation>Wähle eine Audio Datei</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="40"/>
<source>All Audio files</source>
<translation>Alle Audio Dateien</translation>
</message>
</context>
<context>
<name>ToastySettings</name>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="29"/>
<source>Device ID:</source>
<translation>Geräte ID:</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="29"/>
<source>The device id which can be foun in the toasty app.</source>
<translation>Die Geräte ID, die in der Toasty App gefunden werden kann.</translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="30"/>
<source>&lt;a href=&quot;http://supertoasty.com/&quot;&gt;Supertoasty.com&lt;/a&gt;</source>
<translation></translation>
</message>
</context>
<context>
<name>TrayIcon</name>
<message>
<location filename="../src/daemon/trayicon.cpp" line="77"/>
<source>Display Test Notification</source>
<translation>Zeige eine Testmitteilung an</translation>
</message>
<message>
<location filename="../src/daemon/trayicon.cpp" line="79"/>
<source>Settings</source>
<translation>Einstellungen</translation>
</message>
<message>
<location filename="../src/daemon/trayicon.cpp" line="81"/>
<source>Exit</source>
<translation>Beenden</translation>
</message>
</context>
</TS>

View File

@ -1,382 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1">
<context>
<name>Default Alert</name>
<message>
<location filename="../src/libsnore/application_p.cpp" line="30"/>
<source>Default</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FreedesktopFrontend</name>
<message>
<location filename="../src/plugins/frontends/freedesktop_frontend/freedesktopnotificationfrontend.cpp" line="40"/>
<source>Failed to register dbus object.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/freedesktop_frontend/freedesktopnotificationfrontend.cpp" line="43"/>
<source>Failed to register dbus service.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>GrowlBackend</name>
<message>
<location filename="../src/plugins/backends/growl/growlbackend.cpp" line="70"/>
<source> is not running.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>GrowlSettings</name>
<message>
<location filename="../src/plugins/backends/growl/growlsettings.cpp" line="30"/>
<source>Host:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/backends/growl/growlsettings.cpp" line="31"/>
<source>Password:</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>NotifyMyAndroidSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="29"/>
<source>Api Key:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="29"/>
<source>The api key which can be found in your account page at &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt;.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/nma/nmasettings.cpp" line="30"/>
<source>If you don&apos;t have an accout yet please register at &lt;a href=&quot;http://notifymyandroid.com/&quot;&gt;Notifymyandroid.com&lt;/a&gt;.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>PushoverSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="31"/>
<source>User Key:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="31"/>
<source>The user key which can be found on your account page at &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt;.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="32"/>
<source>Sound:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="32"/>
<source>The pushover sound that it played when a notification is recieved.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="33"/>
<source>Devices:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="33"/>
<source>The devices that are to recieve the notifications.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="36"/>
<source>Email Address:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="37"/>
<source>Password:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="38"/>
<source>Device Name:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="40"/>
<source>Status</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="42"/>
<location filename="../src/plugins/secondary_backends/pushover_backend/pushoversettings.cpp" line="34"/>
<source>If you don&apos;t have an accout yet please register at &lt;a href=&quot;https://pushover.net&quot;&gt;Pushover.net&lt;/a&gt;</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="88"/>
<source>Log out</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="89"/>
<source>Logged in.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="95"/>
<source>Log in</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/frontends/pushover_frontend/pushoversettings.cpp" line="97"/>
<source>Logged out.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SettingsDialog</name>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="14"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="34"/>
<source>General</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="45"/>
<source>Primary Backend:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="55"/>
<source>Timeout:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="62"/>
<source>s</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="69"/>
<source>Disable Notification Sound:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="79"/>
<source>Error:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="96"/>
<source>Primary Backends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="106"/>
<source>Secondary Bckends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="116"/>
<source>Frontends</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="126"/>
<source>Plugins</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/settingsdialog.ui" line="139"/>
<source>Display Test Notification</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SettingsWindow</name>
<message>
<location filename="../src/settings/settingswindow.ui" line="14"/>
<source>Snore Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/settings/settingswindow.ui" line="27"/>
<source>Application</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnarlBackend</name>
<message>
<location filename="../src/plugins/backends/snarl/snarl.cpp" line="150"/>
<source> is not running.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnarlNetworkFrontend</name>
<message>
<location filename="../src/plugins/frontends/snarlnetwork/snarlnetwork.cpp" line="37"/>
<source>The port is already used by a different application.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnarlSettings</name>
<message>
<location filename="../src/plugins/backends/snarl/snarlsettings.cpp" line="29"/>
<source>Password:</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Snore::PluginSettingsWidget</name>
<message>
<location filename="../src/libsnore/plugins/pluginsettingswidget.cpp" line="36"/>
<source>Enabled:</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Snore::SnoreCore</name>
<message>
<location filename="../src/libsnore/snore.cpp" line="255"/>
<source>This is </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="256"/>
<source>Everything is awesome!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="260"/>
<source>Hello There!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/libsnore/snore.cpp" line="261"/>
<source>Awesome Action!</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnoreNotifierSettings</name>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="30"/>
<source>TopLeftCorner</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="31"/>
<source>TopRightCorner</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="32"/>
<source>BottomLeftCorner</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="33"/>
<source>BottomRightCorner</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/backends/snore/snorenotifiersettings.cpp" line="34"/>
<source>Position:</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnoreSend</name>
<message>
<location filename="../src/snoresend/main.cpp" line="138"/>
<source>Bring to Front</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SnoreToast</name>
<message>
<location filename="../src/plugins/backends/snoretoast/snoretoast.cpp" line="20"/>
<source> needs at least Windows 8 to run.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SoundSettings</name>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="34"/>
<source>Volume:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="36"/>
<source>Audio file:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="36"/>
<source>The sound played when a notifications is recieved.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="37"/>
<source>Select a audio file</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/sound/soundsettings.cpp" line="40"/>
<source>All Audio files</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ToastySettings</name>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="29"/>
<source>Device ID:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="29"/>
<source>The device id which can be foun in the toasty app.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/plugins/secondary_backends/toasty/toastysettings.cpp" line="30"/>
<source>&lt;a href=&quot;http://supertoasty.com/&quot;&gt;Supertoasty.com&lt;/a&gt;</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrayIcon</name>
<message>
<location filename="../src/daemon/trayicon.cpp" line="77"/>
<source>Display Test Notification</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/daemon/trayicon.cpp" line="79"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/daemon/trayicon.cpp" line="81"/>
<source>Exit</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

View File

@ -1,5 +0,0 @@
<!DOCTYPE RCC><RCC version="1.0">
<qresource prefix="/lang/libsnore">
@snore_i18n_content@
</qresource>
</RCC>

6
src/Messages.sh Normal file
View File

@ -0,0 +1,6 @@
#!/bin/sh
# Extract strings from all source files.
# EXTRACT_TR_STRINGS extracts strings with lupdate and convert them to .pot with
# lconvert.
$EXTRACT_TR_STRINGS `find . -name \*.cpp -o -name \*.h -o -name \*.ui -o -name \*.qml` -o $podir/snorenotify-qt5_qt.pot

View File

@ -10,6 +10,8 @@ set(LIBSNORE_INCLUDE_DIR ${KDE_INSTALL_INCLUDEDIR}/libsnore)
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/version.cpp.in" "${CMAKE_CURRENT_BINARY_DIR}/version.cpp")
ecm_create_qm_loader(SnoreNotify_QM_LOADER snorenotify${SNORE_SUFFIX}_qt)
QT5_ADD_RESOURCES(SNORENOTIFY_RCS ${SNORE_RCS})
add_subdirectory(notification)
@ -49,7 +51,7 @@ list(APPEND SnoreNotify_HDR
)
add_library( libsnore SHARED ${SnoreNotify_SRCS})
add_library( libsnore SHARED ${SnoreNotify_SRCS} ${SnoreNotify_QM_LOADER})
set_target_properties( libsnore PROPERTIES
OUTPUT_NAME "snore${SNORE_SUFFIX}"
VERSION "${SNORE_VERSION_MAJOR}.${SNORE_VERSION_MINOR}.${SNORE_VERSION_PATCH}.${SNORE_VERSION_SUFFIX}"

View File

@ -48,6 +48,10 @@ SnoreCore &SnoreCore::instance()
{
static SnoreCore *instance = nullptr;
if (!instance) {
qRegisterMetaType<Notification>();
qRegisterMetaType<Application>();
qRegisterMetaType<SnorePlugin::PluginTypes>();
qRegisterMetaTypeStreamOperators<SnorePlugin::PluginTypes>();
instance = new SnoreCore(qApp);
SnoreCorePrivate::instance()->init();
}

View File

@ -28,7 +28,6 @@
#include <QApplication>
#include <QSettings>
#include <QTemporaryDir>
#include <QTranslator>
using namespace Snore;
@ -267,49 +266,3 @@ void SnoreCorePrivate::startNotificationTimeoutTimer(Notification notification)
timer->start();
}
///Startup code
static void loadTranslator()
{
auto installTranslator = [](const QString & locale) {
snoreDebug(SNORE_DEBUG) << locale;
if (locale != QLatin1String("C")) {
QTranslator *translator = new QTranslator(qApp->instance());
if (translator->load(locale, QLatin1String(":/lang/libsnore/"))) {
snoreDebug(SNORE_DEBUG) << "Using system locale:" << locale;
snoreDebug(SNORE_DEBUG) << qApp->installTranslator(translator);
} else {
translator->deleteLater();
QString fileName = QLatin1String(":/lang/libsnore/") + locale + QLatin1String(".qm");
snoreDebug(SNORE_DEBUG) << "Failed to load translations for:" << locale << fileName << QFile::exists(fileName) ;
return false;
}
}
return true;
};
installTranslator(QLatin1String("en"));
QLocale locale = QLocale::system();
if (locale.name() != QLatin1String("en")) {
if (!installTranslator(locale.name())) {
installTranslator(locale.bcp47Name());
}
}
}
static void registerMetaTypes()
{
qRegisterMetaType<Notification>();
qRegisterMetaType<Application>();
qRegisterMetaType<SnorePlugin::PluginTypes>();
qRegisterMetaTypeStreamOperators<SnorePlugin::PluginTypes>();
}
static void snoreStartup()
{
loadTranslator();
registerMetaTypes();
}
Q_COREAPP_STARTUP_FUNCTION(snoreStartup)