Move lines to resx

- "Pin to screen"
- "Connect..." and "Disconnect" in OAuthLoopbackControl
This commit is contained in:
L1Q 2023-01-07 20:03:11 +02:00
parent 0e506e7877
commit ae9cb033d7
No known key found for this signature in database
GPG key ID: DABD39A303975F6C
6 changed files with 40 additions and 6 deletions

View file

@ -439,7 +439,7 @@ private void InitializeComponent()
tsmiPinToScreen.Name = "tsmiPinToScreen";
tsmiPinToScreen.ShortcutKeyDisplayString = "Ctrl+P";
tsmiPinToScreen.Size = new Size(127, 22);
tsmiPinToScreen.Text = "Pin to screen"; // TODO: Translate
tsmiPinToScreen.Text = Resources.PinToScreen;
tsmiPinToScreen.Click += tsmiPinToScreen_Click;
//
// tsmiShowMoreInfo

View file

@ -492,6 +492,15 @@ internal class Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Pin to screen.
/// </summary>
internal static string PinToScreen {
get {
return ResourceManager.GetString("PinToScreen", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Process names:.
/// </summary>

View file

@ -265,4 +265,7 @@
<data name="HistoryStats" xml:space="preserve">
<value>History stats</value>
</data>
</root>
<data name="PinToScreen" xml:space="preserve">
<value>Pin to screen</value>
</data>
</root>

View file

@ -79,8 +79,7 @@ private void UpdateStatus()
{
if (Connected)
{
// TODO: Translate
btnConnect.Text = "Disconnect";
btnConnect.Text = Resources.Disconnect;
if (UserInfo != null && !string.IsNullOrEmpty(UserInfo.name))
{
lblStatusValue.Text = string.Format(Resources.LoggedInAs0, UserInfo.name);
@ -93,8 +92,7 @@ private void UpdateStatus()
}
else
{
// TODO: Translate
btnConnect.Text = "Connect...";
btnConnect.Text = Resources.Connect;
lblStatusValue.Text = Resources.OAuthControl_Status_NotLoggedIn;
lblStatusValue.ForeColor = Color.FromArgb(220, 0, 0);
}

View file

@ -139,6 +139,15 @@ internal class Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Connect....
/// </summary>
internal static string Connect {
get {
return ResourceManager.GetString("Connect", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to &quot;File form name&quot; must be configured..
/// </summary>
@ -166,6 +175,15 @@ internal class Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Disconnect.
/// </summary>
internal static string Disconnect {
get {
return ResourceManager.GetString("Disconnect", resourceCulture);
}
}
/// <summary>
/// Looks up a localized resource of type System.Drawing.Bitmap.
/// </summary>

View file

@ -449,4 +449,10 @@ Created folders:</value>
<data name="OAuthCallbackPage" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\resources\oauthcallbackpage.html;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;Windows-1252</value>
</data>
<data name="Disconnect" xml:space="preserve">
<value>Disconnect</value>
</data>
<data name="Connect" xml:space="preserve">
<value>Connect...</value>
</data>
</root>