DragAndDropPage.xaml 1014 B

123456789101112131415161718192021
  1. <UserControl xmlns="https://github.com/avaloniaui"
  2. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  3. x:Class="ControlCatalog.Pages.DragAndDropPage">
  4. <StackPanel Orientation="Vertical" Spacing="4">
  5. <TextBlock Classes="h1">Drag+Drop</TextBlock>
  6. <TextBlock Classes="h2">Example of Drag+Drop capabilities</TextBlock>
  7. <StackPanel Orientation="Horizontal"
  8. Margin="0,16,0,0"
  9. HorizontalAlignment="Center"
  10. Spacing="16">
  11. <Border BorderBrush="{DynamicResource ThemeAccentBrush}" BorderThickness="2" Padding="16" Name="DragMe">
  12. <TextBlock Name="DragState">Drag Me</TextBlock>
  13. </Border>
  14. <Border Background="{DynamicResource ThemeAccentBrush2}" Padding="16"
  15. DragDrop.AllowDrop="True">
  16. <TextBlock Name="DropState">Drop some text or files here</TextBlock>
  17. </Border>
  18. </StackPanel>
  19. </StackPanel>
  20. </UserControl>