|
6 | 6 | xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
7 | 7 | xmlns:controls="using:Microsoft.Toolkit.Uwp.UI.Controls"
|
8 | 8 | xmlns:list="using:Locations"
|
9 |
| - mc:Ignorable="d"> |
| 9 | + xmlns:local="using:Files" |
| 10 | + mc:Ignorable="d" NavigationCacheMode="Disabled"> |
10 | 11 | <Page.Resources>
|
11 | 12 | <RevealBackgroundBrush x:Key="CardHoverBackground" TargetTheme="Dark" />
|
12 | 13 | <Style x:Key="CardStyle" TargetType="Button">
|
|
380 | 381 | </Style>
|
381 | 382 |
|
382 | 383 | </Page.Resources>
|
383 |
| - |
| 384 | + <ScrollViewer> |
384 | 385 | <Grid Padding="24,35,24,0" Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
|
385 | 386 |
|
386 | 387 | <Grid.RowDefinitions>
|
|
420 | 421 |
|
421 | 422 | </controls:AdaptiveGridView>
|
422 | 423 |
|
423 |
| - <Grid VerticalAlignment="Stretch" Grid.Row="2" HorizontalAlignment="Stretch"> |
424 |
| - <StackPanel> |
425 |
| - <TextBlock Margin="0,24,0,0" FontFamily="Segoe UI" FontWeight="Bold" FontSize="30" Text="Recent Items"/> |
426 |
| - <ScrollViewer HorizontalScrollMode="Disabled" HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Auto" VerticalScrollMode="Auto" > |
427 |
| - <ListView Name="RecentsView" MinHeight="400" HorizontalAlignment="Stretch" Padding="0,50,0,0" > |
428 |
| - <ListView.Header> |
429 |
| - <TextBlock Text="No recent files" HorizontalAlignment="Center" FontSize="24"/> |
430 |
| - </ListView.Header> |
| 424 | + <Grid VerticalAlignment="Stretch" Grid.Row="2" HorizontalAlignment="Stretch"> |
| 425 | + <StackPanel> |
| 426 | + <TextBlock Margin="0,24,0,0" FontFamily="Segoe UI" FontWeight="Bold" FontSize="30" Text="Recent Items"/> |
| 427 | + <TextBlock Visibility="{x:Bind local:YourHome.Empty.Visibility, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Margin="0,50,0,0" Text="No recent items" HorizontalAlignment="Center" FontSize="20"/> |
| 428 | + <ListView IsItemClickEnabled="True" IsRightTapEnabled="True" RightTapped="RecentsView_RightTapped" ItemClick="RecentsView_ItemClick" ItemsSource="{x:Bind local:YourHome.recentItemsCollection}" Name="RecentsView" MinHeight="400" HorizontalAlignment="Stretch" Padding="0,5,0,0" > |
| 429 | + <ListView.ContextFlyout> |
| 430 | + <MenuFlyout> |
| 431 | + <MenuFlyoutItem Click="MenuFlyoutItem_Click" Icon="Delete" Text="Clear all items"/> |
| 432 | + </MenuFlyout> |
| 433 | + </ListView.ContextFlyout> |
| 434 | + <ListView.ItemTemplate> |
| 435 | + <DataTemplate> |
| 436 | + <Grid Padding="10" VerticalAlignment="Center"> |
| 437 | + <StackPanel VerticalAlignment="Center" Orientation="Horizontal" Spacing="10"> |
| 438 | + <Grid VerticalAlignment="Center" Margin="0, 0, 0, 0"> |
| 439 | + <FontIcon Visibility="{Binding FolderImg}" FontSize="30" Glyph="" FontFamily="Segoe MDL2 Assets" Foreground="#ffe793"/> |
| 440 | + <FontIcon Visibility="{Binding EmptyImgVis}" FontSize="30" Glyph="" FontFamily="Segoe MDL2 Assets"/> |
| 441 | + <Image Visibility="{Binding FileIconVis}" Height="30" Width="30" Source="{Binding FileImg}" Stretch="UniformToFill" /> |
| 442 | + </Grid> |
| 443 | + <StackPanel VerticalAlignment="Center" HorizontalAlignment="Center" Orientation="Horizontal"> |
| 444 | + <TextBlock Width="400" TextWrapping="NoWrap" Text="{Binding name}"/> |
| 445 | + <TextBlock Margin="100,0,0,0" TextWrapping="NoWrap" Text="{Binding path}"/> |
| 446 | + </StackPanel> |
| 447 | + </StackPanel> |
| 448 | + </Grid> |
| 449 | + </DataTemplate> |
| 450 | + </ListView.ItemTemplate> |
431 | 451 | </ListView>
|
432 |
| - </ScrollViewer> |
433 |
| - </StackPanel> |
| 452 | + </StackPanel> |
| 453 | + </Grid> |
434 | 454 | </Grid>
|
435 |
| - |
436 |
| - |
437 |
| - |
438 |
| - |
439 |
| - |
440 |
| - </Grid> |
| 455 | + </ScrollViewer> |
441 | 456 | </Page>
|
0 commit comments