Browse files

Merge pull request #646 from Montellese/localizations

Move some hardcoded strings to the english strings.xml
  • Loading branch information...
2 parents 463b784 + 98d103a commit e9bcfd077911853565a6fa68e27245c11f2a5f69 @mkortstiege mkortstiege committed Jan 21, 2012
View
14 language/English/strings.xml
@@ -2009,7 +2009,9 @@
<string id="21451">Internet connection required.</string>
<string id="21452">Get More...</string>
<string id="21453">Root filesystem</string>
-
+ <string id="21454">Cache full</string>
+ <string id="21455">Cache filled before reaching required amount for continous playback</string>
+
<string id="21460">Subtitle location</string>
<string id="21461">Fixed</string>
<string id="21462">Bottom of video</string>
@@ -2328,6 +2330,8 @@
<string id="33101">Webserver</string>
<string id="33102">Event Server</string>
<string id="33103">Remote communication server</string>
+
+ <string id="33200">Detected New Connection</string>
<!-- translators: no need to add these to your language files -->
<string id="34000">Lame</string>
@@ -2352,6 +2356,14 @@
<string id="34201">Can't find a next item to play</string>
<string id="34202">Can't find a previous item to play</string>
+
+ <string id="34300">Failed to start zeroconf</string>
+ <string id="34301">Is Apple's Bonjour Service installed? See log for more info.</string>
+
+ <string id="34400">Video Rendering</string>
+ <string id="34401">Failed to init video filters/scalers, falling back to bilinear scaling</string>
+ <string id="34402">Failed to initialize audio device</string>
+ <string id="34403">Check your audiosettings</string>
<string id="35000">Peripherals</string>
View
3 xbmc/cores/AudioRenderers/NullDirectSound.cpp
@@ -22,6 +22,7 @@
#include "threads/SystemClock.h"
#include "NullDirectSound.h"
#include "guilib/AudioContext.h"
+#include "guilib/LocalizeStrings.h"
#include "utils/log.h"
#include "utils/TimeUtils.h"
#include "dialogs/GUIDialogKaiToast.h"
@@ -52,7 +53,7 @@ bool CNullDirectSound::Initialize(IAudioCallback* pCallback, const CStdString& d
g_audioContext.SetupSpeakerConfig(iChannels, bAudioOnAllSpeakers, bIsMusic);
g_audioContext.SetActiveDevice(CAudioContext::DIRECTSOUND_DEVICE);
- CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, "Failed to initialize audio device", "Check your audiosettings", TOAST_DISPLAY_TIME, false);
+ CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, g_localizeStrings.Get(34402), g_localizeStrings.Get(34403), TOAST_DISPLAY_TIME, false);
m_timePerPacket = 1.0f / (float)(iChannels*(uiBitsPerSample/8) * uiSamplesPerSec);
m_packetsSent = 0;
m_paused = 0;
View
3 xbmc/cores/VideoRenderers/LinuxRendererGL.cpp
@@ -37,6 +37,7 @@
#include "windowing/WindowingFactory.h"
#include "dialogs/GUIDialogKaiToast.h"
#include "guilib/Texture.h"
+#include "guilib/LocalizeStrings.h"
#include "threads/SingleLock.h"
#include "DllSwScale.h"
#include "utils/log.h"
@@ -871,7 +872,7 @@ void CLinuxRendererGL::UpdateVideoFilter()
break;
}
- CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, "Video Renderering", "Failed to init video filters/scalers, falling back to bilinear scaling");
+ CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, g_localizeStrings.Get(34400), g_localizeStrings.Get(34401));
CLog::Log(LOGERROR, "GL: Falling back to bilinear due to failure to init scaler");
if (m_pVideoFilterShader)
{
View
2 xbmc/cores/VideoRenderers/WinRenderer.cpp
@@ -558,7 +558,7 @@ void CWinRenderer::UpdatePSVideoFilter()
if (!m_scalerShader->Create(m_scalingMethod))
{
SAFE_DELETE(m_scalerShader);
- CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, "Video Renderering", "Failed to init video scaler, falling back to bilinear scaling.");
+ CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, g_localizeStrings.Get(34400), g_localizeStrings.Get(34401));
m_bUseHQScaler = false;
}
}
View
2 xbmc/cores/dvdplayer/DVDPlayer.cpp
@@ -1393,7 +1393,7 @@ void CDVDPlayer::HandlePlaySpeed()
{
if(level < 0.0)
{
- CGUIDialogKaiToast::QueueNotification("Cache full", "Cache filled before reaching required amount for continous playback");
+ CGUIDialogKaiToast::QueueNotification(g_localizeStrings.Get(21454), g_localizeStrings.Get(21455));
caching = CACHESTATE_INIT;
}
if(level >= 1.0)
View
5 xbmc/network/EventClient.cpp
@@ -35,6 +35,7 @@
#include "utils/TimeUtils.h"
#include "dialogs/GUIDialogKaiToast.h"
#include "guilib/GraphicContext.h"
+#include "guilib/LocalizeStrings.h"
using namespace EVENTCLIENT;
using namespace EVENTPACKET;
@@ -335,13 +336,13 @@ bool CEventClient::OnPacketHELO(CEventPacket *packet)
m_bGreeted = true;
if (m_eLogoType == LT_NONE)
{
- CGUIDialogKaiToast::QueueNotification("Detected New Connection",
+ CGUIDialogKaiToast::QueueNotification(g_localizeStrings.Get(33200),
m_deviceName.c_str());
}
else
{
CGUIDialogKaiToast::QueueNotification(iconfile.c_str(),
- "Detected New Connection",
+ g_localizeStrings.Get(33200),
m_deviceName.c_str());
}
return true;
View
3 xbmc/network/windows/ZeroconfWIN.cpp
@@ -26,6 +26,7 @@
#include <threads/SingleLock.h>
#include <utils/log.h>
#include "dialogs/GUIDialogKaiToast.h"
+#include "guilib/LocalizeStrings.h"
#pragma comment(lib, "dnssd.lib")
@@ -46,7 +47,7 @@ bool CZeroconfWIN::IsZCdaemonRunning()
if(err != kDNSServiceErr_NoError)
{
CLog::Log(LOGERROR, "ZeroconfWIN: Zeroconf can't be started probably because Apple's Bonjour Service isn't installed. You can get it by either installing Itunes or Apple's Bonjour Print Service for Windows (http://support.apple.com/kb/DL999)");
- CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, "Failed to start zeroconf", "Is Apple's Bonjour Service installed? See log for more info.", 10000, true);
+ CGUIDialogKaiToast::QueueNotification(CGUIDialogKaiToast::Error, g_localizeStrings.Get(34300), g_localizeStrings.Get(34301), 10000, true);
return false;
}
CLog::Log(LOGDEBUG, "ZeroconfWIN:Bonjour version is %d.%d", version / 10000, version / 100 % 100);

3 comments on commit e9bcfd0

@alanwww1
Team Kodi member

Will this going to be backported to Eden ? Just as an info for the translators if they ask me.
Thanks.

@Montellese
Team Kodi member

See vdrfan's comment on the PR: #646
So basically, yes. If a language doesn't have it it will fall back to english so it won't be worse than when it was hardcoded.

@alanwww1
Team Kodi member

Thanks Montellese. It is always good to get rid of hardcoded strings. Cheers

Please sign in to comment.