aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.Common
diff options
context:
space:
mode:
authorAvi Levkovich <avi@twine-s.com>2018-07-25 15:44:00 +0300
committerAvi Levkovich <avi@twine-s.com>2018-07-25 15:44:00 +0300
commit76fb3f86bfaceb75220752cd5ef792eb3be464cc (patch)
tree76755bbae2bbe4ece5f474a11424a918dbf33b5b /Software/Visual_Studio/PPC/Tango.PPC.Common
parentcaf4be8968eed6738fdaa2486fa08ba601c45be4 (diff)
parentd5a855a3980a835460befab0acc36caa7f0230b7 (diff)
downloadTango-76fb3f86bfaceb75220752cd5ef792eb3be464cc.tar.gz
Tango-76fb3f86bfaceb75220752cd5ef792eb3be464cc.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/_git/Tango
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.Common')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItem.cs22
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItemView.xaml20
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.Common/Properties/AssemblyInfo.cs2
3 files changed, 28 insertions, 16 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItem.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItem.cs
index 5e120ab8c..b7f206e7c 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItem.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItem.cs
@@ -23,6 +23,13 @@ namespace Tango.PPC.Common.Notifications.NotificationItems
set { _message = value; RaisePropertyChangedAuto(); }
}
+ private String _expandedMessage;
+ public String ExpandedMessage
+ {
+ get { return _expandedMessage; }
+ set { _expandedMessage = value; RaisePropertyChangedAuto(); }
+ }
+
private MessageNotificationItemTypes _messageType;
public MessageNotificationItemTypes MessageType
@@ -41,14 +48,25 @@ namespace Tango.PPC.Common.Notifications.NotificationItems
}
- public MessageNotificationItem(String message, MessageNotificationItemTypes type, Action pressed) : this()
+ public MessageNotificationItem(String message, String expandedMessage, MessageNotificationItemTypes type, Action pressed) : this()
{
Message = message;
+ ExpandedMessage = expandedMessage;
MessageType = type;
Pressed += (_, __) => pressed?.Invoke();
}
- public MessageNotificationItem(String message, MessageNotificationItemTypes type) : this(message, type, null)
+ public MessageNotificationItem(String message, MessageNotificationItemTypes type, Action pressed) : this(message, null, type, pressed)
+ {
+
+ }
+
+ public MessageNotificationItem(String message, String expandedMessage, MessageNotificationItemTypes type) : this(message, expandedMessage, type, null)
+ {
+
+ }
+
+ public MessageNotificationItem(String message, MessageNotificationItemTypes type) : this(message, null, type)
{
}
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItemView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItemView.xaml
index 057e86a13..9b583a117 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItemView.xaml
+++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Notifications/NotificationItems/MessageNotificationItemView.xaml
@@ -7,7 +7,7 @@
xmlns:local="clr-namespace:Tango.PPC.Common.Notifications.NotificationItems"
mc:Ignorable="d"
d:DesignHeight="60" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:MessageNotificationItem, IsDesignTimeCreatable=False}" MinHeight="60" Height="60" MaxHeight="150">
-
+
<ContentControl>
<ContentControl.Style>
<Style TargetType="ContentControl">
@@ -50,18 +50,12 @@
</Style>
</touch:TouchIcon.Style>
</touch:TouchIcon>
- <TextBlock VerticalAlignment="Center" Margin="10 0 0 0" Text="{Binding Message}" TextTrimming="CharacterEllipsis">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="TextWrapping" Value="NoWrap"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsExpanded}" Value="True">
- <Setter Property="TextWrapping" Value="Wrap"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
+
+ <StackPanel Margin="10 0 0 0" VerticalAlignment="Center">
+ <TextBlock Text="{Binding Message}" TextTrimming="CharacterEllipsis" TextWrapping="Wrap"></TextBlock>
+
+ <TextBlock Margin="0 20 0 0" Text="{Binding ExpandedMessage}" TextWrapping="Wrap" Visibility="{Binding IsExpanded,Converter={StaticResource BooleanToVisibilityConverter}}"></TextBlock>
+ </StackPanel>
</DockPanel>
</ContentControl>
</UserControl>
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Properties/AssemblyInfo.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/Properties/AssemblyInfo.cs
index 254e25c85..3f5a630f6 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Properties/AssemblyInfo.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Properties/AssemblyInfo.cs
@@ -8,7 +8,7 @@ using System.Windows;
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Tango Panel PC Common Library")]
-[assembly: AssemblyVersion("2.0.3.1536")]
+[assembly: AssemblyVersion("2.0.4.1407")]
[assembly:ThemeInfo(
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located