Skip to content
This repository has been archived by the owner on Dec 20, 2023. It is now read-only.

Commit

Permalink
观看自己的视频时不显示关注按钮 (#332)
Browse files Browse the repository at this point in the history
  • Loading branch information
Richasy authored Sep 28, 2021
1 parent c13e22c commit bd037f8
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -626,7 +626,7 @@
AutomationProperties.Name="{loc:LocaleLocator Name=Subtitle}"
Style="{StaticResource MTCButtonStyle}"
ToolTipService.ToolTip="{loc:LocaleLocator Name=Subtitle}"
Visibility="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=ViewModel.IsShowSubtitleButton}">
Visibility="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=ViewModel.IsShowSubtitleButton, Converter={StaticResource BoolToVisibilityConverter}}">
<Button.Content>
<icons:RegularFluentIcon FontSize="16" Symbol="TextboxAlignBottom20" />
</Button.Content>
Expand Down
2 changes: 1 addition & 1 deletion src/App/Controls/Player/PlayerDescriptor.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
VerticalAlignment="Center"
IsTextSelectionEnabled="True"
Text="{x:Bind ViewModel.Publisher.Name, Mode=OneWay}" />
<Grid HorizontalAlignment="Left">
<Grid HorizontalAlignment="Left" Visibility="{x:Bind ViewModel.Publisher.IsShowFollowButton, Mode=OneWay}">
<Button
x:Name="FollowButton"
Style="{StaticResource AccentButtonStyle}"
Expand Down
2 changes: 1 addition & 1 deletion src/App/Resources/Misc/Question.CHS.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
{
"id": 301,
"title": "播放快捷键",
"answer": "播放/暂停:Ctrl + P\n进入/退出全窗口:F10\n进入/退出全屏:F11\n进入/退出小窗:Ctrl + M\n退出当前播放模式(适用于全窗口/全屏):Esc\n回退:方向左键\n前进:方向右键\n切换清晰度/直播线路:Ctrl + Q"
"answer": "播放/暂停:Ctrl + P\n进入/退出全窗口:F10\n进入/退出全屏:F11\n进入/退出小窗:Ctrl + M\n退出当前播放模式(适用于全窗口/全屏):Esc\n回退:方向左键\n前进:方向右键\n切换清晰度/直播线路:Ctrl + Q\n显示/隐藏弹幕控制器:Ctrl + D\n打开字幕配置:Ctrl + S"
},
{
"id": 302,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ public async Task InitializeSubtitleIndexAsync()
try
{
var index = await Controller.GetSubtitleIndexAsync(aid, cid);
if (index != null && index.Subtitles != null)
if (index != null && index.Subtitles != null && index.Subtitles.Count > 0)
{
IsShowSubtitleButton = true;
index.Subtitles.ForEach(p => SubtitleIndexCollection.Add(new SubtitleIndexItemViewModel(p, false)));
var first = SubtitleIndexCollection.FirstOrDefault();
CurrentSubtitleIndex = first.Data;
if (first != null)
{
CurrentSubtitleIndex = first.Data;
first.IsSelected = true;
await InitializeSubtitleAsync(first.Data);
}
Expand Down

0 comments on commit bd037f8

Please sign in to comment.