diff --git a/FoxTube/Controls/Chat.xaml b/FoxTube/Controls/Chat.xaml
index 02df719..293d84a 100644
--- a/FoxTube/Controls/Chat.xaml
+++ b/FoxTube/Controls/Chat.xaml
@@ -36,6 +36,7 @@
+
@@ -45,7 +46,7 @@
-
+
diff --git a/FoxTube/Controls/Chat.xaml.cs b/FoxTube/Controls/Chat.xaml.cs
index 15af172..f8f5992 100644
--- a/FoxTube/Controls/Chat.xaml.cs
+++ b/FoxTube/Controls/Chat.xaml.cs
@@ -10,35 +10,28 @@ namespace FoxTube.Controls
{
public class ChatMessage
{
- public string Author
+ public string Author => message.AuthorDetails.DisplayName;
+ public TextBlock Message
{
- get { return message.AuthorDetails.DisplayName; }
- }
- public string Message
- {
- get { return message.Snippet.DisplayMessage; }
- }
- public string ChannelId
- {
- get { return message.AuthorDetails.ChannelId; }
+ get
+ {
+ TextBlock block = new TextBlock()
+ {
+ IsTextSelectionEnabled = true,
+ VerticalAlignment = VerticalAlignment.Top,
+ TextWrapping = TextWrapping.WrapWholeWords
+ };
+ Methods.FormatText(ref block, message.Snippet.DisplayMessage);
+ return block;
+ }
}
+ public string ChannelId => message.AuthorDetails.ChannelId;
+ public string Avatar => message.AuthorDetails.ProfileImageUrl;
- public Visibility IsVerified
- {
- get { return message.AuthorDetails.IsVerified.Value? Visibility.Visible : Visibility.Collapsed; }
- }
- public Visibility IsOwner
- {
- get { return message.AuthorDetails.IsChatOwner.Value ? Visibility.Visible : Visibility.Collapsed; }
- }
- public Visibility IsSponsor
- {
- get { return message.AuthorDetails.IsChatSponsor.Value ? Visibility.Visible : Visibility.Collapsed; }
- }
- public Visibility IsModerator
- {
- get { return message.AuthorDetails.IsChatModerator.Value ? Visibility.Visible : Visibility.Collapsed; }
- }
+ public Visibility IsVerified => message.AuthorDetails.IsVerified.Value ? Visibility.Visible : Visibility.Collapsed;
+ public Visibility IsOwner => message.AuthorDetails.IsChatOwner.Value ? Visibility.Visible : Visibility.Collapsed;
+ public Visibility IsSponsor => message.AuthorDetails.IsChatSponsor.Value ? Visibility.Visible : Visibility.Collapsed;
+ public Visibility IsModerator => message.AuthorDetails.IsChatModerator.Value ? Visibility.Visible : Visibility.Collapsed;
public Brush Background
{
diff --git a/FoxTube/Controls/VideoPlayer.xaml b/FoxTube/Controls/VideoPlayer.xaml
index fb00dd9..d804422 100644
--- a/FoxTube/Controls/VideoPlayer.xaml
+++ b/FoxTube/Controls/VideoPlayer.xaml
@@ -99,7 +99,7 @@
@@ -114,7 +114,7 @@
-
+
@@ -132,7 +132,7 @@
-