aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher.UI/MainWindow.xaml
blob: cd23547c2087696b51ca0ccc5ce7b20015ad09c5 (plain)
1
2
3
4pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.highlight .gr { color: #aa0000 } /* Generic.Error */
.highlight .gh { color: #333333 } /* Generic.Heading */
.highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
.highlight .go { color: #888888 } /* Generic.Output */
.highlight .gp { color: #555555 } /* Generic.Prompt */
.highlight .gs { font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #666666 } /* Generic.Subheading */
.highlight .gt { color: #aa0000 } /* Generic.Traceback */
.highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */
.highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */
.highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */
.highlight .kp { color: #008800 } /* Keyword.Pseudo */
.highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */
.highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */
.highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */
.highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */
.highlight .na { color: #336699 } /* Name.Attribute */
.highlight .nb { color: #003388 } /* Name.Builtin */
.highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */
.highlight .no { color: #003366; font-weight: bold } /* Name.Constant */
.highlight .nd { color: #555555 } /* Name.Decorator */
.highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */
.highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */
.highlight .nl { color: #336699; font-style: italic } /* Name.Label */
.highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */
.highlight .py { color: #336699; font-weight: bold } /* Name.Property */
.highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */
.highlight .nv { color: #336699 } /* Name.Variable */
.highlight .ow { color: #008800 } /* Operator.Word */
.highlight .w { color: #bbbbbb } /* Text.Whitespace */
.highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */
.highlight .mf { color: #0000DD; font-weight:
<Window x:Class="Tango.MachineStudio.Publisher.UI.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:Tango.MachineStudio.Publisher.UI"
        xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
        xmlns:web="clr-namespace:Tango.Web;assembly=Tango.Web"
        mc:Ignorable="d"
        Title="Machine Studio Publisher" Height="620" Width="700" WindowStartupLocation="CenterScreen" WindowStyle="ToolWindow" ResizeMode="NoResize" Foreground="#202020" d:DataContext="{d:DesignInstance Type=local:MainWindowVM, IsDesignTimeCreatable=False}">

    <Window.Resources>
        <converters:EnumToItemsSourceConverter x:Key="EnumToItemsSourceConverter" />
    </Window.Resources>

    <Window.Style>
        <Style TargetType="Window">
            <Setter Property="Cursor" Value="Arrow"></Setter>
            <Style.Triggers>
                <DataTrigger Binding="{Binding IsBusy}" Value="True">
                    <Setter Property="Cursor" Value="Wait"></Setter>
                </DataTrigger>
            </Style.Triggers>
        </Style>
    </Window.Style>

    <Border BorderThickness="1" BorderBrush="#0288D1">
        <Grid>
            <Grid.RowDefinitions>
                <RowDefinition Height="60"/>
                <RowDefinition Height="156*"/>
            </Grid.RowDefinitions>

            <Grid Background="#0288D1">
                <Grid.Effect>
                    <DropShadowEffect BlurRadius="10" ShadowDepth="5" Direction="270" Opacity="0.5" />
                </Grid.Effect>

                <StackPanel Orientation="Horizontal" Margin="8" HorizontalAlignment="Center">
                    <Image Source="/Images/machine-trans.png" RenderOptions.BitmapScalingMode="Fant"></Image>
                    <TextBlock Foreground="White" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="23">MACHINE STUDIO</TextBlock>
                </StackPanel>
            </Grid>

            <Grid Grid.Row="1" Margin="10" IsEnabled="{Binding IsFree}">
                <DockPanel>
                    <StackPanel DockPanel.Dock="Top" HorizontalAlignment="Left" Margin="0 20 0 0" x:Name="stackDetails">
                        <TextBlock FontSize="16">
                            <Run>Remote Version:</Run>
                            <Run Text="{Binding RemoteVersion}" FontStyle="Italic" FontWeight="SemiBold"></Run>
                        </TextBlock>
                        <TextBlock Margin="0 10 0 0" FontSize="16" >
                            <Run>Local Version:</Run>
                            <Run Text="{Binding LocalVersion}" FontStyle="Italic" FontWeight="SemiBold"></Run>
                        </TextBlock>

                        <ComboBox Width="200" Margin="0 10 0 0" HorizontalAlignment="Left" ItemsSource="{Binding Source={x:Type web:DeploymentSlot},Converter={StaticResource EnumToItemsSourceConverter}}" SelectedValue="{Binding Options.Environment}" SelectedValuePath="Value" DisplayMemberPath="DisplayName"></ComboBox>


                        <StackPanel Margin="0 20 0 0" Orientation="Horizontal">
                            <TextBlock FontSize="16">Email:</TextBlock>
                            <TextBox Margin="5 0 0 0" Width="230" BorderThickness="0 0 0 1" Text="{Binding Options.Email,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></TextBox>
                        </StackPanel>

                        <StackPanel Margin="0 10 0 0" Orientation="Horizontal">
                            <TextBlock FontSize="16">Password:</TextBlock>
                            <TextBox Margin="5 0 0 0" Width="200" BorderThickness="0 0 0 1" Text="{Binding Options.Password,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></TextBox>
                        </StackPanel>

                        <StackPanel Margin="0 10 0 0" Orientation="Horizontal">
                            <TextBlock FontSize="16">Installer Project:</TextBlock>
                            <TextBox Margin="5 0 0 0" Width="500" BorderThickness="0 0 0 1" Text="{Binding Options.InstallerProject,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></TextBox>
                        </StackPanel>

                        <StackPanel Margin="0 10 0 0" Orientation="Horizontal">
                            <TextBlock FontSize="16">Installer Output Folder:</TextBlock>
                            <TextBox Margin="5 0 0 0" Width="500" BorderThickness="0 0 0 1" Text="{Binding Options.InstallerOutputFolder,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></TextBox>
                        </StackPanel>

                        <TextBlock FontSize="16" Margin="0 20 0 0">Comments</TextBlock>
                        <TextBox HorizontalAlignment="Left" Height="70" Margin="0 5 0 0" Width="500" AcceptsReturn="True" TextWrapping="Wrap" Text="{Binding Options.Comments,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></TextBox>

                        <StackPanel Margin="0 20 0 0">
                            <CheckBox x:Name="chkCreateTag" IsChecked="{Binding Options.CreateTag}">Create Tag On Repository</CheckBox>
                            <CheckBox Margin="0 5 0 0" IsChecked="{Binding Options.AutoCommitAndPush}">Auto Commit &amp; Push</CheckBox>
                            <TextBlock Margin="0 10 0 0">Personal Access Token</TextBlock>
                            <TextBox BorderThickness="0 0 0 1" IsEnabled="{Binding ElementName=chkCreateTag,Path=IsChecked}" Margin="0 5 0 0" Text="{Binding Options.PersonalAccessToken}"></TextBox>
                        </StackPanel>
                    </StackPanel>

                    <Grid DockPanel.Dock="Bottom">
                        <DockPanel>
                            <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" DockPanel.Dock="Right">
                                <Button Background="#0288D1" BorderThickness="0" Height="30" MinWidth="140" Foreground="White" FontWeight="SemiBold" Command="{Binding PublishCommand}">PUBLISH</Button>
                            </StackPanel>

                            <StackPanel HorizontalAlignment="Left">
                                <TextBlock Text="{Binding PublishArgs.Message}" Foreground="Gray"></TextBlock>
                                <ProgressBar Width="500" Height="10" Margin="0 5 0 0" Maximum="{Binding PublishArgs.Total}" Value="{Binding PublishArgs.Progress}" Foreground="#0288D1"></ProgressBar>
                            </StackPanel>
                        </DockPanel>
                    </Grid>

                    <Grid>

                    </Grid>

                </DockPanel>
            </Grid>
        </Grid>
    </Border>
</Window>