Skip to content

Commit

Permalink
Update translations
Browse files Browse the repository at this point in the history
  • Loading branch information
ScrubN committed Apr 22, 2024
1 parent 9f65d93 commit 3b75286
Show file tree
Hide file tree
Showing 18 changed files with 137 additions and 11 deletions.
4 changes: 2 additions & 2 deletions TwitchDownloaderWPF/PageChatDownload.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ private async Task GetVideoInfo()
currentVideoTime = Settings.Default.UTCVideoTime ? videoTime : videoTime.ToLocalTime();
streamerId = int.Parse(videoInfo.data.video.owner.id);
viewCount = videoInfo.data.video.viewCount;
game = videoInfo.data.video.game?.displayName ?? "Unknown";
game = videoInfo.data.video.game?.displayName ?? Translations.Strings.UnknownGame;
var urlTimeCodeMatch = TwitchRegex.UrlTimeCode.Match(textUrl.Text);
if (urlTimeCodeMatch.Success)
{
Expand Down Expand Up @@ -172,7 +172,7 @@ private async Task GetVideoInfo()
imgThumbnail.Source = image;

TimeSpan clipLength = TimeSpan.FromSeconds(clipInfo.data.clip.durationSeconds);
textStreamer.Text = clipInfo.data.clip.broadcaster?.displayName ?? "Unknown User";
textStreamer.Text = clipInfo.data.clip.broadcaster?.displayName ?? Translations.Strings.UnknownUser;
var clipCreatedAt = clipInfo.data.clip.createdAt;
textCreatedAt.Text = Settings.Default.UTCVideoTime ? clipCreatedAt.ToString(CultureInfo.CurrentCulture) : clipCreatedAt.ToLocalTime().ToString(CultureInfo.CurrentCulture);
currentVideoTime = Settings.Default.UTCVideoTime ? clipCreatedAt : clipCreatedAt.ToLocalTime();
Expand Down
4 changes: 2 additions & 2 deletions TwitchDownloaderWPF/PageChatUpdate.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,11 +107,11 @@ private async void btnBrowse_Click(object sender, RoutedEventArgs e)
VideoLength = TimeSpan.FromSeconds(double.IsNegative(ChatJsonInfo.video.length) ? 0.0 : ChatJsonInfo.video.length);
labelLength.Text = VideoLength.Seconds > 0
? VideoLength.ToString("c")
: Translations.Strings.Unknown;
: Translations.Strings.UnknownVideoLength;

VideoId = ChatJsonInfo.video.id ?? ChatJsonInfo.comments.FirstOrDefault()?.content_id ?? "-1";
ViewCount = ChatJsonInfo.video.viewCount;
Game = ChatJsonInfo.video.game ?? ChatJsonInfo.video.chapters.FirstOrDefault()?.gameDisplayName ?? "Unknown";
Game = ChatJsonInfo.video.game ?? ChatJsonInfo.video.chapters.FirstOrDefault()?.gameDisplayName ?? Translations.Strings.UnknownGame;

try
{
Expand Down
4 changes: 2 additions & 2 deletions TwitchDownloaderWPF/PageClipDownload.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,14 @@ private async Task GetClipInfo()
imgThumbnail.Source = image;

clipLength = TimeSpan.FromSeconds(taskClipInfo.Result.data.clip.durationSeconds);
textStreamer.Text = clipData.data.clip.broadcaster?.displayName ?? "Unknown User";
textStreamer.Text = clipData.data.clip.broadcaster?.displayName ?? Translations.Strings.UnknownUser;
var clipCreatedAt = clipData.data.clip.createdAt;
textCreatedAt.Text = Settings.Default.UTCVideoTime ? clipCreatedAt.ToString(CultureInfo.CurrentCulture) : clipCreatedAt.ToLocalTime().ToString(CultureInfo.CurrentCulture);
currentVideoTime = Settings.Default.UTCVideoTime ? clipCreatedAt : clipCreatedAt.ToLocalTime();
textTitle.Text = clipData.data.clip.title;
labelLength.Text = clipLength.ToString("c");
viewCount = taskClipInfo.Result.data.clip.viewCount;
game = taskClipInfo.Result.data.clip.game?.displayName ?? "Unknown";
game = taskClipInfo.Result.data.clip.game?.displayName ?? Translations.Strings.UnknownGame;

foreach (var quality in taskLinks.Result.data.clip.videoQualities)
{
Expand Down
2 changes: 1 addition & 1 deletion TwitchDownloaderWPF/PageVodDownload.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ private async Task GetVideoInfo()
numEndSecond.Value = vodLength.Seconds;
labelLength.Text = vodLength.ToString("c");
viewCount = taskVideoInfo.Result.data.video.viewCount;
game = taskVideoInfo.Result.data.video.game?.displayName ?? "Unknown";
game = taskVideoInfo.Result.data.video.game?.displayName ?? Translations.Strings.UnknownGame;

UpdateVideoSizeEstimates();

Expand Down
27 changes: 27 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.es.resx
Original file line number Diff line number Diff line change
Expand Up @@ -862,4 +862,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.fr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -861,4 +861,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.it.resx
Original file line number Diff line number Diff line change
Expand Up @@ -862,4 +862,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.ja.resx
Original file line number Diff line number Diff line change
Expand Up @@ -860,4 +860,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>フォルダを開く</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.pl.resx
Original file line number Diff line number Diff line change
Expand Up @@ -861,4 +861,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.pt-br.resx
Original file line number Diff line number Diff line change
Expand Up @@ -860,4 +860,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -860,4 +860,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.ru.resx
Original file line number Diff line number Diff line change
Expand Up @@ -861,4 +861,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.tr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -862,4 +862,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.uk.resx
Original file line number Diff line number Diff line change
Expand Up @@ -861,4 +861,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
9 changes: 9 additions & 0 deletions TwitchDownloaderWPF/Translations/Strings.zh.resx
Original file line number Diff line number Diff line change
Expand Up @@ -860,4 +860,13 @@
<data name="ContextMenuOpenFolder" xml:space="preserve">
<value>Open folder</value>
</data>
<data name="UnknownUser" xml:space="preserve">
<value>Unknown User</value>
</data>
<data name="UnknownGame" xml:space="preserve">
<value>Unknown Game</value>
</data>
<data name="UnknownVideoLength" xml:space="preserve">
<value>Unknown</value>
</data>
</root>
4 changes: 2 additions & 2 deletions TwitchDownloaderWPF/WindowMassDownload.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ private async Task UpdateList()
Time = Settings.Default.UTCVideoTime ? video.node.createdAt : video.node.createdAt.ToLocalTime(),
Views = video.node.viewCount,
Streamer = currentChannel,
Game = video.node.game?.displayName ?? "Unknown",
Game = video.node.game?.displayName ?? Translations.Strings.UnknownGame,
Thumbnail = thumbnail
});
}
Expand Down Expand Up @@ -145,7 +145,7 @@ private async Task UpdateList()
Time = Settings.Default.UTCVideoTime ? clip.node.createdAt : clip.node.createdAt.ToLocalTime(),
Views = clip.node.viewCount,
Streamer = currentChannel,
Game = clip.node.game?.displayName ?? "Unknown",
Game = clip.node.game?.displayName ?? Translations.Strings.UnknownGame,
Thumbnail = thumbnail
});
}
Expand Down
4 changes: 2 additions & 2 deletions TwitchDownloaderWPF/WindowUrlList.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ private async void btnQueue_Click(object sender, RoutedEventArgs e)
Streamer = videoInfo.owner.displayName,
Time = Settings.Default.UTCVideoTime ? videoInfo.createdAt : videoInfo.createdAt.ToLocalTime(),
Views = videoInfo.viewCount,
Game = videoInfo.game?.displayName ?? "Unknown",
Game = videoInfo.game?.displayName ?? Translations.Strings.UnknownGame,
Length = videoInfo.lengthSeconds
});
}
Expand Down Expand Up @@ -139,7 +139,7 @@ private async void btnQueue_Click(object sender, RoutedEventArgs e)
Streamer = clipInfo.broadcaster.displayName,
Time = Settings.Default.UTCVideoTime ? clipInfo.createdAt : clipInfo.createdAt.ToLocalTime(),
Views = clipInfo.viewCount,
Game = clipInfo.game?.displayName ?? "Unknown",
Game = clipInfo.game?.displayName ?? Translations.Strings.UnknownGame,
Length = clipInfo.durationSeconds
});
}
Expand Down

0 comments on commit 3b75286

Please sign in to comment.