AvaloniaUI / Avalonia.Xaml.Behaviors

Port of Windows UWP Xaml Behaviors for Avalonia Xaml.
MIT License
385 stars 46 forks source link

It's impossible to press button or choice combobox item when I'm using draggable class for ListBox A11-Preview-4 #114

Closed Kozlov-AE closed 6 months ago

Kozlov-AE commented 1 year ago

изображение Just replase your code for List box tab in your sample https://github.com/wieslawsoltes/AvaloniaBehaviors/tree/master/samples/DraggableDemo

    <TabItem Header="ListBox">
      <ListBox Classes="draggable">
        <ListBox.Styles>
          <Style Selector="ListBoxItem > TextBlock">
            <Setter Property="HorizontalAlignment" Value="Left" />
          </Style>
          <Style Selector="ListBoxItem:not(:dragging)">
            <Setter Property="Transitions">
              <Setter.Value>
                <Transitions>
                  <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.1" />
                </Transitions>
              </Setter.Value>
            </Setter>
          </Style>
        </ListBox.Styles>
        <ListBoxItem>
          <TextBlock Text="Item1" />
        </ListBoxItem>
        <ListBoxItem>
          <TextBlock Text="Item2" />
        </ListBoxItem>
        <ListBoxItem>
          <TextBlock Text="Item3" />
        </ListBoxItem>
        <ListBoxItem>
          <ComboBox>
            <ComboBoxItem>1</ComboBoxItem>
            <ComboBoxItem>2</ComboBoxItem>
            <ComboBoxItem>3</ComboBoxItem>
          </ComboBox>
        </ListBoxItem>
        <ListBoxItem>
          <Button>Hello!</Button>
        </ListBoxItem>
      </ListBox>
    </TabItem>
TimB-rain commented 1 year ago

image With the same items in the listbox in version 11.0.0-preview5, I could move each item only one time.