|
12 | 12 | <vm:MainViewModel />
|
13 | 13 | </Design.DataContext>
|
14 | 14 | <UserControl.Styles>
|
15 |
| - <Style Selector="TabControl WrapPanel"> |
16 |
| - <Setter Property="MaxHeight" Value="32"/> |
17 |
| - <Setter Property="Margin" Value="0, 0, 0, 5"/> |
18 |
| - </Style> |
19 |
| - <Style Selector="TabControl > TextBlock"> |
20 |
| - <Setter Property="FontSize" Value="12"/> |
21 |
| - </Style> |
22 |
| - <Style Selector="Label"> |
23 |
| - <Setter Property="VerticalAlignment" Value="Center"/> |
24 |
| - </Style> |
| 15 | + |
25 | 16 | </UserControl.Styles>
|
26 | 17 |
|
27 | 18 | <Grid Margin="5">
|
28 | 19 | <Grid.RowDefinitions>
|
| 20 | + <RowDefinition Height="Auto"/> |
29 | 21 | <RowDefinition Height="Auto"/>
|
30 | 22 | <RowDefinition Height="10"/>
|
31 | 23 | <RowDefinition Height="*"/>
|
|
38 | 30 | <ColumnDefinition Width="Auto"/>
|
39 | 31 | <ColumnDefinition Width="Auto"/>
|
40 | 32 | </Grid.ColumnDefinitions>
|
41 |
| - <Label Grid.Column="0" |
| 33 | + <Label Grid.Column="0" |
42 | 34 | Margin="2, 2, 5, 2">Input file: </Label>
|
43 | 35 | <TextBox Grid.Column="1"
|
44 | 36 | Height="24"
|
|
52 | 44 | Command="{Binding HideFilesCommand}"
|
53 | 45 | Margin="5, 0">Hide Files</Button>
|
54 | 46 | </Grid>
|
55 |
| - <ProgressBar Grid.Row="1" |
| 47 | + <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="0, 5"> |
| 48 | + <Label Grid.Column="0" |
| 49 | + Margin="0, 0, 5, 0">Compression Level: </Label> |
| 50 | + <ComboBox Grid.Column="1" |
| 51 | + Name="CompressionLevelComboBox" |
| 52 | + ItemsSource="{Binding CompressionLevels}" |
| 53 | + SelectedItem="{Binding SelectedCompressionLevel}"/> |
| 54 | + </StackPanel> |
| 55 | + <ProgressBar Grid.Row="2" |
56 | 56 | Margin="5"
|
57 | 57 | Value="{Binding PercentDone}"
|
58 | 58 | IsVisible="{Binding IsRunning}"/>
|
59 |
| - <TabControl Grid.Row="2"> |
60 |
| - <TabItem Name="FilesList" Header="File View"> |
61 |
| - <Grid> |
62 |
| - <Grid.RowDefinitions> |
63 |
| - <RowDefinition Height="48"/> |
64 |
| - <RowDefinition Height="Auto"/> |
65 |
| - </Grid.RowDefinitions> |
66 |
| - <Grid Grid.Row="0"> |
67 |
| - <Grid.ColumnDefinitions> |
68 |
| - <ColumnDefinition/> |
69 |
| - <ColumnDefinition/> |
70 |
| - </Grid.ColumnDefinitions> |
71 |
| - <StackPanel Grid.Column="0" |
72 |
| - Orientation="Horizontal" |
73 |
| - Margin="0, 5"> |
74 |
| - <Button Command="{Binding AddFilesCommand}" |
75 |
| - Margin="5, 0">Add files</Button> |
76 |
| - <Button Command="{Binding AddDirCommand}" |
77 |
| - Margin="5, 0">Add folder</Button> |
78 |
| - <Button Command="{Binding RemoveCommand}" |
79 |
| - Margin="5, 0">Remove</Button> |
80 |
| - <Button Command="{Binding RemoveAllCommand}" |
81 |
| - Margin="5, 0">Remove All</Button> |
82 |
| - <Button Command="{Binding BackCommand}" |
83 |
| - Margin="5, 0">Back</Button> |
84 |
| - </StackPanel> |
85 |
| - <StackPanel Grid.Column="1" |
86 |
| - Orientation="Horizontal" |
87 |
| - FlowDirection="RightToLeft"> |
88 |
| - </StackPanel> |
89 |
| - </Grid> |
90 |
| - <ListBox Grid.Row="1" |
91 |
| - Name="FilesListBox" |
92 |
| - ItemsSource="{Binding Files.CurrentDirectory.Children}" |
93 |
| - SelectedItem="{Binding SelectedItem}" |
94 |
| - DoubleTapped="FilesList_DoubleTap"> |
95 |
| - <ListBox.ItemTemplate> |
96 |
| - <DataTemplate> |
97 |
| - <TextBlock Text="{Binding Name}"/> |
98 |
| - </DataTemplate> |
99 |
| - </ListBox.ItemTemplate> |
100 |
| - </ListBox> |
101 |
| - </Grid> |
102 |
| - </TabItem> |
103 |
| - <TabItem Name="Options" Header="Options"> |
104 |
| - <StackPanel Margin="5, 15, 5, 5" HorizontalAlignment="Center" VerticalAlignment="Center"> |
105 |
| - <!--To-do: implement password protection--> |
106 |
| - <!--<Grid> |
107 |
| - <Grid.ColumnDefinitions> |
108 |
| - <ColumnDefinition Width="48"/> |
109 |
| - <ColumnDefinition Width="120"/> |
110 |
| - <ColumnDefinition/> |
111 |
| - </Grid.ColumnDefinitions> |
112 |
| - <CheckBox Grid.Column="0" |
113 |
| - Name="IsEnabledCheckBox" |
114 |
| - IsChecked="{Binding Options.IsPasswordProtected}"/> |
115 |
| - <Label Grid.Column="1">Password: </Label> |
116 |
| - <TextBox Grid.Column="2" |
117 |
| - Text="{Binding Options.Password}" |
118 |
| - IsEnabled="{Binding Options.IsPasswordProtected}"/> |
119 |
| - </Grid>--> |
120 |
| - <Grid> |
121 |
| - <Grid.ColumnDefinitions> |
122 |
| - <ColumnDefinition/> |
123 |
| - <ColumnDefinition/> |
124 |
| - </Grid.ColumnDefinitions> |
125 |
| - <Label Grid.Column="0" |
126 |
| - Margin="0, 0, 5, 0">Compression Level: </Label> |
127 |
| - <ComboBox Grid.Column="1" |
128 |
| - Name="CompressionLevelComboBox" |
129 |
| - ItemsSource="{Binding CompressionLevels}" |
130 |
| - SelectedItem="{Binding SelectedCompressionLevel}"/> |
131 |
| - </Grid> |
| 59 | + <Grid Grid.Row="2"> |
| 60 | + <Grid.RowDefinitions> |
| 61 | + <RowDefinition Height="48"/> |
| 62 | + <RowDefinition Height="Auto"/> |
| 63 | + </Grid.RowDefinitions> |
| 64 | + <Grid Grid.Row="0"> |
| 65 | + <Grid.ColumnDefinitions> |
| 66 | + <ColumnDefinition/> |
| 67 | + <ColumnDefinition/> |
| 68 | + </Grid.ColumnDefinitions> |
| 69 | + <StackPanel Grid.Column="0" |
| 70 | + Orientation="Horizontal" |
| 71 | + Margin="0, 5"> |
| 72 | + <Button Command="{Binding AddFilesCommand}" |
| 73 | + Margin="5, 0">Add files</Button> |
| 74 | + <Button Command="{Binding AddDirCommand}" |
| 75 | + Margin="5, 0">Add folder</Button> |
| 76 | + <Button Command="{Binding RemoveCommand}" |
| 77 | + Margin="5, 0">Remove</Button> |
| 78 | + <Button Command="{Binding RemoveAllCommand}" |
| 79 | + Margin="5, 0">Remove All</Button> |
| 80 | + <Button Command="{Binding BackCommand}" |
| 81 | + Margin="5, 0">Back</Button> |
132 | 82 | </StackPanel>
|
133 |
| - </TabItem> |
134 |
| - </TabControl> |
135 |
| - |
| 83 | + <StackPanel Grid.Column="1" |
| 84 | + Orientation="Horizontal" |
| 85 | + FlowDirection="RightToLeft"> |
| 86 | + </StackPanel> |
| 87 | + </Grid> |
| 88 | + <ListBox Grid.Row="1" |
| 89 | + Name="FilesListBox" |
| 90 | + ItemsSource="{Binding Files.CurrentDirectory.Children}" |
| 91 | + SelectedItem="{Binding SelectedItem}" |
| 92 | + DoubleTapped="FilesList_DoubleTap"> |
| 93 | + <ListBox.ItemTemplate> |
| 94 | + <DataTemplate> |
| 95 | + <TextBlock Text="{Binding Name}"/> |
| 96 | + </DataTemplate> |
| 97 | + </ListBox.ItemTemplate> |
| 98 | + </ListBox> |
| 99 | + </Grid> |
136 | 100 | </Grid>
|
137 | 101 | </UserControl>
|
0 commit comments