Added IHostV30.ChangeCurrentUserLanguage method.
This commit is contained in:
parent
1d819c137f
commit
58915b4fd8
5 changed files with 19 additions and 3 deletions
|
@ -16,5 +16,5 @@ using System.Reflection;
|
||||||
//
|
//
|
||||||
// You can specify all the values or you can default the Revision and Build Numbers
|
// You can specify all the values or you can default the Revision and Build Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
[assembly: AssemblyVersion("3.0.0.345")]
|
[assembly: AssemblyVersion("3.0.0.346")]
|
||||||
[assembly: AssemblyFileVersion("3.0.0.345")]
|
[assembly: AssemblyFileVersion("3.0.0.346")]
|
||||||
|
|
10
Core/Host.cs
10
Core/Host.cs
|
@ -619,6 +619,16 @@ namespace ScrewTurn.Wiki {
|
||||||
Log.LogEntry(message, t, name);
|
Log.LogEntry(message, t, name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Changes the language of the current user.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="language">The language code.</param>
|
||||||
|
public void ChangeCurrentUserLanguage(string language) {
|
||||||
|
int timezone = Preferences.LoadTimezoneFromCookie() ?? Settings.DefaultTimezone;
|
||||||
|
if(SessionFacade.LoginKey == null) Preferences.SavePreferencesInCookie(language, timezone);
|
||||||
|
else Preferences.SavePreferencesInUserData(language, timezone);
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Aligns a Date and Time object to the User's Time Zone preferences.
|
/// Aligns a Date and Time object to the User's Time Zone preferences.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
<CppCommentsFixup>False</CppCommentsFixup>
|
<CppCommentsFixup>False</CppCommentsFixup>
|
||||||
<FrameworkVersion>2.0.50727</FrameworkVersion>
|
<FrameworkVersion>2.0.50727</FrameworkVersion>
|
||||||
<IndentHtml>False</IndentHtml>
|
<IndentHtml>False</IndentHtml>
|
||||||
<Preliminary>True</Preliminary>
|
<Preliminary>False</Preliminary>
|
||||||
<RootNamespaceContainer>False</RootNamespaceContainer>
|
<RootNamespaceContainer>False</RootNamespaceContainer>
|
||||||
<RootNamespaceTitle />
|
<RootNamespaceTitle />
|
||||||
<HelpTitle>ScrewTurn Wiki Developer's Documentation</HelpTitle>
|
<HelpTitle>ScrewTurn Wiki Developer's Documentation</HelpTitle>
|
||||||
|
|
Binary file not shown.
|
@ -282,6 +282,12 @@ namespace ScrewTurn.Wiki.PluginFramework {
|
||||||
/// <exception cref="ArgumentException">If <paramref name="message"/> is empty.</exception>
|
/// <exception cref="ArgumentException">If <paramref name="message"/> is empty.</exception>
|
||||||
void LogEntry(string message, LogEntryType entryType, string user, object caller);
|
void LogEntry(string message, LogEntryType entryType, string user, object caller);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Changes the language of the current user.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="language">The language code.</param>
|
||||||
|
void ChangeCurrentUserLanguage(string language);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Aligns a Date and Time object to the User's Time Zone preferences.
|
/// Aligns a Date and Time object to the User's Time Zone preferences.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue