CloudDriveContent.xaml 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. <UserControl x:Class="PDF_Master.Views.HomePanel.CloudDrive.CloudDriveContent"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:PDF_Master.Views.HomePanel.CloudDrive"
  7. xmlns:prism ="http://prismlibrary.com/"
  8. prism:ViewModelLocator.AutoWireViewModel="True"
  9. mc:Ignorable="d"
  10. d:DesignHeight="450" d:DesignWidth="800">
  11. <Grid Margin="44,38,0,0">
  12. <Grid.RowDefinitions>
  13. <RowDefinition Height="auto"/>
  14. <RowDefinition />
  15. </Grid.RowDefinitions>
  16. <Grid>
  17. <TextBlock Text="Cloud Drive" HorizontalAlignment="Left"/>
  18. <ComboBox x:Name="combCloudDrive" Width="115" Height="32" Background="Wheat" HorizontalAlignment="Right" SelectionChanged="combCloudDrive_SelectionChanged">
  19. <ComboBox.ItemTemplate>
  20. <DataTemplate>
  21. <Border Background="#DBDBDB">
  22. <TextBlock Text="{Binding DriveName}"/>
  23. </Border>
  24. </DataTemplate>
  25. </ComboBox.ItemTemplate>
  26. </ComboBox>
  27. </Grid>
  28. <ListBox x:Name="ListCloudDrive" Background="Transparent" Grid.Row="1" Grid.RowSpan="2" HorizontalAlignment="Left" VerticalAlignment='Top' BorderThickness="0">
  29.  
  30. <ListBox.ItemsPanel>
  31. <ItemsPanelTemplate>
  32. <UniformGrid Columns="4"/>
  33. </ItemsPanelTemplate>
  34. </ListBox.ItemsPanel>
  35. <ListBox.ItemTemplate>
  36. <DataTemplate>
  37. <StackPanel Width="218" Height="192">
  38. <Rectangle Fill="#DBDBDB" Width="218" Height="172"/>
  39. <TextBlock Grid.Row="1" Text="{Binding DriveName}" VerticalAlignment="Bottom" HorizontalAlignment="Center"/>
  40. </StackPanel>
  41. </DataTemplate>
  42. </ListBox.ItemTemplate>
  43. <ListBox.ItemContainerStyle>
  44. <Style TargetType="{x:Type ListBoxItem}">
  45. <Setter Property="Margin" Value="0,0,8,0"/>
  46. <Setter Property="Width" Value="218"/>
  47. <Setter Property="Height" Value="192"/>
  48. <Setter Property="Padding" Value="0"/>
  49. <EventSetter Event="PreviewMouseLeftButtonUp"
  50. Handler="SelectCloudDrive_Click"
  51. />
  52. </Style>
  53. </ListBox.ItemContainerStyle>
  54. </ListBox>
  55. </Grid>
  56. </UserControl>