|
152 | 152 | <Path Width="8" Height="14" Stretch="Fill" Data="{StaticResource Icons.TriangleRight}"/> |
153 | 153 | </RepeatButton> |
154 | 154 |
|
155 | | - <Button x:Name="PageSelector" Classes="icon_button" Width="16" Height="16" Margin="8,0"> |
156 | | - <Button.Flyout> |
157 | | - <Flyout Opened="OnTabsDropdownOpened" Closed="OnTabsDropdownClosed"> |
158 | | - <Grid RowDefinitions="28,Auto" KeyDown="OnTabsDropdownKeyDown" LostFocus="OnTabsDropdownLostFocus"> |
159 | | - <TextBox Grid.Row="0" |
160 | | - Height="24" |
161 | | - Margin="4,0" |
162 | | - BorderThickness="1" |
163 | | - CornerRadius="12" |
164 | | - Text="{Binding #ThisControl.SearchFilter, Mode=TwoWay}" |
165 | | - BorderBrush="{DynamicResource Brush.Border2}" |
166 | | - VerticalContentAlignment="Center" |
167 | | - KeyDown="OnTabsDropdownSearchBoxKeyDown" |
168 | | - v:AutoFocusBehaviour.IsEnabled="True"> |
169 | | - <TextBox.InnerLeftContent> |
170 | | - <Path Width="14" Height="14" |
171 | | - Margin="6,0,0,0" |
172 | | - Fill="{DynamicResource Brush.FG2}" |
173 | | - Data="{StaticResource Icons.Search}"/> |
174 | | - </TextBox.InnerLeftContent> |
175 | | - |
176 | | - <TextBox.InnerRightContent> |
177 | | - <Button Classes="icon_button" |
178 | | - Width="16" |
179 | | - Margin="0,0,6,0" |
180 | | - Click="OnClearSearchFilter" |
181 | | - IsVisible="{Binding #ThisControl.SearchFilter, Converter={x:Static StringConverters.IsNotNullOrEmpty}}" |
182 | | - HorizontalAlignment="Right"> |
183 | | - <Path Width="14" Height="14" |
184 | | - Margin="0,1,0,0" |
185 | | - Fill="{DynamicResource Brush.FG1}" |
186 | | - Data="{StaticResource Icons.Clear}"/> |
187 | | - </Button> |
188 | | - </TextBox.InnerRightContent> |
189 | | - </TextBox> |
190 | | - |
191 | | - <ListBox Grid.Row="1" |
192 | | - x:Name="TabsDropdownList" |
193 | | - Focusable="True" |
194 | | - Width="200" |
195 | | - MaxHeight="400" |
196 | | - Margin="0,4,0,0" |
197 | | - Background="Transparent" |
198 | | - SelectionMode="Single" |
199 | | - ScrollViewer.HorizontalScrollBarVisibility="Disabled" |
200 | | - ScrollViewer.VerticalScrollBarVisibility="Auto" |
201 | | - ItemsSource="{Binding #ThisControl.SelectablePages}" |
202 | | - SelectedItem="{Binding ActivePage, Mode=OneWay}"> |
203 | | - <ListBox.Styles> |
204 | | - <Style Selector="ListBoxItem"> |
205 | | - <Setter Property="Padding" Value="0"/> |
206 | | - <Setter Property="MinHeight" Value="26"/> |
207 | | - <Setter Property="CornerRadius" Value="4"/> |
208 | | - </Style> |
209 | | - |
210 | | - <Style Selector="ListBox"> |
211 | | - <Setter Property="FocusAdorner"> |
212 | | - <FocusAdornerTemplate> |
213 | | - <Grid/> |
214 | | - </FocusAdornerTemplate> |
215 | | - </Setter> |
216 | | - </Style> |
217 | | - </ListBox.Styles> |
218 | | - |
219 | | - <ListBox.ItemsPanel> |
220 | | - <ItemsPanelTemplate> |
221 | | - <StackPanel Orientation="Vertical"/> |
222 | | - </ItemsPanelTemplate> |
223 | | - </ListBox.ItemsPanel> |
224 | | - |
225 | | - <ListBox.ItemTemplate> |
226 | | - <DataTemplate DataType="vm:LauncherPage"> |
227 | | - <Grid ColumnDefinitions="Auto,*" Background="Transparent" Tapped="OnTabsDropdownItemTapped"> |
228 | | - <Path Grid.Column="0" |
229 | | - Width="12" Height="12" Margin="12,0" |
230 | | - Fill="{Binding Node.Bookmark, Converter={x:Static c:IntConverters.ToBookmarkBrush}}" |
231 | | - Data="{StaticResource Icons.Bookmark}" |
232 | | - IsVisible="{Binding Node.IsRepository}" |
233 | | - IsHitTestVisible="False"/> |
234 | | - <Path Grid.Column="0" |
235 | | - Width="12" Height="12" Margin="12,0" |
236 | | - Fill="{DynamicResource Brush.FG1}" |
237 | | - Data="{StaticResource Icons.Repositories}" |
238 | | - IsVisible="{Binding !Node.IsRepository}" |
239 | | - IsHitTestVisible="False"/> |
240 | | - <TextBlock Grid.Column="1" |
241 | | - Classes="primary" |
242 | | - VerticalAlignment="Center" |
243 | | - Text="{Binding Node.Name}" |
244 | | - IsVisible="{Binding Node.IsRepository}" |
245 | | - IsHitTestVisible="False"/> |
246 | | - <TextBlock Grid.Column="1" |
247 | | - Classes="primary" |
248 | | - VerticalAlignment="Center" |
249 | | - Text="{DynamicResource Text.PageTabBar.Welcome.Title}" |
250 | | - IsVisible="{Binding !Node.IsRepository}" |
251 | | - IsHitTestVisible="False"/> |
252 | | - </Grid> |
253 | | - </DataTemplate> |
254 | | - </ListBox.ItemTemplate> |
255 | | - </ListBox> |
256 | | - </Grid> |
257 | | - </Flyout> |
258 | | - </Button.Flyout> |
259 | | - <Path Width="14" Height="14" Data="{StaticResource Icons.CircleDown}"/> |
260 | | - </Button> |
261 | | - |
262 | 155 | <Button Classes="icon_button" Width="16" Height="16" Command="{Binding AddNewTab}"> |
263 | 156 | <ToolTip.Tip> |
264 | 157 | <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> |
|
0 commit comments