mirror of
https://github.com/greenshot/greenshot
synced 2025-07-30 19:50:11 -07:00
Cleaning HEAD, to replace it with the branch
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@1281 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
3514fc0a29
commit
174f653a5a
506 changed files with 0 additions and 76725 deletions
|
@ -1,39 +0,0 @@
|
|||
|
||||
using System;
|
||||
using System.Resources;
|
||||
using System.Globalization;
|
||||
using System.Threading;
|
||||
using Greenshot.Configuration;
|
||||
using System.Diagnostics;
|
||||
|
||||
|
||||
namespace Greenshot
|
||||
{
|
||||
/// <summary>
|
||||
/// Description of Language.
|
||||
/// </summary>
|
||||
public class Language
|
||||
{
|
||||
private ResourceManager rm;
|
||||
private static Language uniqueInstance;
|
||||
private Language() {
|
||||
rm = new ResourceManager("Greenshot.UI", System.Reflection.Assembly.GetExecutingAssembly());
|
||||
SetLanguage(AppConfig.GetInstance().Ui_Language);
|
||||
}
|
||||
|
||||
public static Language GetInstance() {
|
||||
if(uniqueInstance == null) {
|
||||
uniqueInstance = new Language();
|
||||
}
|
||||
return uniqueInstance;
|
||||
|
||||
}
|
||||
public void SetLanguage(string cultureInfo) {
|
||||
Thread.CurrentThread.CurrentUICulture = new CultureInfo(cultureInfo);
|
||||
}
|
||||
public string GetString(string id) {
|
||||
string s = rm.GetString(id);
|
||||
return (s != null) ? s : "string ###"+id+"### not found";
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue