PowerShell/src/Microsoft.PowerShell.Activities/Xamls/InlineScriptDesigner.xaml
PowerShell Team c748652c34 Copy all mapped files from [SD:725290]
commit 8cec8f150da7583b7af5efbe2853efee0179750c
2016-07-28 23:23:03 -07:00

39 lines
2.1 KiB
XML

<!-- Copyright (c) Microsoft Corporation. All rights reserved. -->
<sap:ActivityDesigner
x:Class="Microsoft.PowerShell.Activities.InlineScriptDesigner"
Collapsible="True"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:s="clr-namespace:System;assembly=mscorlib"
xmlns:conv="clr-namespace:System.Activities.Presentation.Converters;assembly=System.Activities.Presentation"
xmlns:sap="clr-namespace:System.Activities.Presentation;assembly=System.Activities.Presentation"
xmlns:sapv="clr-namespace:System.Activities.Presentation.View;assembly=System.Activities.Presentation"
mc:Ignorable="d"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
d:DesignHeight="128" d:DesignWidth="463">
<sap:ActivityDesigner.Resources>
<DataTemplate x:Key="Collapsed">
<StackPanel>
<TextBlock>This is the collapsed view</TextBlock>
</StackPanel>
</DataTemplate>
<DataTemplate x:Key="Expanded">
<TextBox x:Uid="TextBox_1" Text="{Binding Path=ModelItem.Command, Mode=TwoWay}"
TextWrapping="WrapWithOverflow" AcceptsReturn="True" MinLines="4"
Background="{x:Null}" Margin="3" DockPanel.Dock="Bottom" Height="97" Width="488" />
</DataTemplate>
<Style x:Key="ExpandOrCollapsedStyle" TargetType="{x:Type ContentPresenter}">
<Setter Property="ContentTemplate" Value="{DynamicResource Collapsed}"/>
<Style.Triggers>
<DataTrigger Binding="{Binding Path=ShowExpanded}" Value="true">
<Setter Property="ContentTemplate" Value="{DynamicResource Expanded}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</sap:ActivityDesigner.Resources>
<DockPanel x:Uid="DockPanel_1" LastChildFill="True">
<ContentPresenter Style="{DynamicResource ExpandOrCollapsedStyle}" Content="{Binding}" />
</DockPanel>
</sap:ActivityDesigner>