jangwon 4 лет назад
Родитель
Сommit
dd789afd10

+ 30 - 2
Dev/OHV/OHV.Module.Interactivity/PopUp/DriveServoView.xaml

@@ -455,8 +455,36 @@
                 </StackPanel>
             </Grid>
 
-            <TextBlock Text="{DynamicResource SettingView_DriveWarning}" HorizontalAlignment="Left" TextWrapping="Wrap" TextAlignment="Center" Foreground="Red" VerticalAlignment="Top" Margin="0,-140,0,-194" Grid.Row="1" Height="100" Width="1126" FontSize="78" Grid.ColumnSpan="2" Visibility="{c:Binding 'OcsState == OHVCommonShareds:eOcsState.DisConnect'}"/>
-            <TextBlock Text="{DynamicResource SettingView_TCZState}" HorizontalAlignment="Left" TextWrapping="Wrap" TextAlignment="Center" Foreground="Red" VerticalAlignment="Top" Margin="0,526,0,-132" Grid.Row="1" Height="100" Width="1126" FontSize="78" Grid.ColumnSpan="2" Visibility="{c:Binding 'IsTCZ == OHVCommonEvents:TCZEventArgs:eTCZState.TCZ'}"/>
+            <TextBlock x:Name="ocsMessage" Text="{DynamicResource SettingView_DriveWarning}" HorizontalAlignment="Left" TextWrapping="Wrap" TextAlignment="Center" Foreground="Red" VerticalAlignment="Top" Margin="0,-140,0,-194" Grid.Row="1" Height="100" Width="1126" FontSize="78" Grid.ColumnSpan="2" Visibility="{c:Binding 'OcsState == OHVCommonShareds:eOcsState.DisConnect'}">
+                <TextBlock.Triggers>
+                    <EventTrigger RoutedEvent="TextBlock.Loaded">
+                        <BeginStoryboard>
+                            <Storyboard>
+                                <DoubleAnimation
+                                    Storyboard.TargetName="ocsMessage" 
+                                    Storyboard.TargetProperty="(TextBlock.Opacity)"
+                                    From="1.0" To="0.0" Duration="0:0:0.5" 
+                                    AutoReverse="True" RepeatBehavior="Forever" />
+                            </Storyboard>
+                        </BeginStoryboard>
+                    </EventTrigger>
+                </TextBlock.Triggers>
+            </TextBlock>
+            <TextBlock x:Name="tczMessage" Text="{DynamicResource SettingView_TCZState}" HorizontalAlignment="Left" TextWrapping="Wrap" TextAlignment="Center" Foreground="Red" VerticalAlignment="Top" Margin="0,526,0,-132" Grid.Row="1" Height="100" Width="1126" FontSize="78" Grid.ColumnSpan="2" Visibility="{c:Binding 'IsTCZ == OHVCommonEvents:TCZEventArgs:eTCZState.TCZ'}">
+                <TextBlock.Triggers>
+                    <EventTrigger RoutedEvent="TextBlock.Loaded">
+                        <BeginStoryboard>
+                            <Storyboard>
+                                <DoubleAnimation
+                                    Storyboard.TargetName="tczMessage" 
+                                    Storyboard.TargetProperty="(TextBlock.Opacity)"
+                                    From="1.0" To="0.0" Duration="0:0:0.5" 
+                                    AutoReverse="True" RepeatBehavior="Forever" />
+                            </Storyboard>
+                        </BeginStoryboard>
+                    </EventTrigger>
+                </TextBlock.Triggers>
+            </TextBlock>
 
             <!--<xctk:BusyIndicator x:Name="MyProgress" Grid.RowSpan="2" Grid.ColumnSpan="2" IsBusy="{Binding IsBusy, FallbackValue=true}" BusyContent="{Binding BusyText}"/>-->
 

+ 2 - 2
Dev/OHV/OHV.Module.Interactivity/PopUp/DriveServoViewModel.cs

@@ -639,10 +639,10 @@ namespace OHV.Module.Interactivity.PopUp
             switch (state)
             {
                 case HostConnectedEventArgs.eConnectedState.Connected:
-                    this.OcsState = eOcsState.Connect;
+                    this.OcsState = eOcsState.Connect;                 
                     break;
                 case HostConnectedEventArgs.eConnectedState.Disconnected:
-                    this.OcsState = eOcsState.DisConnect;
+                    this.OcsState = eOcsState.DisConnect;                 
                     break;
             }
         }