diff --git a/Beutl.slnx b/Beutl.slnx
index 7bf6d0fbc..31c8227d1 100644
--- a/Beutl.slnx
+++ b/Beutl.slnx
@@ -30,7 +30,6 @@
-
diff --git a/Directory.Packages.props b/Directory.Packages.props
index 5fb8b89ec..03068b574 100644
--- a/Directory.Packages.props
+++ b/Directory.Packages.props
@@ -4,13 +4,13 @@
-
-
-
-
-
-
-
+
+
+
+
+
+
+
@@ -22,10 +22,10 @@
-
-
-
-
+
+
+
+
@@ -34,14 +34,14 @@
-
-
+
+
-
-
+
+
@@ -66,9 +66,9 @@
-
-
-
+
+
+
@@ -77,9 +77,9 @@
-
-
-
+
+
+
@@ -89,4 +89,4 @@
-
+
\ No newline at end of file
diff --git a/src/Beutl.Controls/BcTabItem/BcTabItem.cs b/src/Beutl.Controls/BcTabItem/BcTabItem.cs
deleted file mode 100644
index 63ce91374..000000000
--- a/src/Beutl.Controls/BcTabItem/BcTabItem.cs
+++ /dev/null
@@ -1,110 +0,0 @@
-using Avalonia;
-using Avalonia.Controls;
-using Avalonia.Controls.Metadata;
-using Avalonia.Controls.Primitives;
-using Avalonia.Interactivity;
-using Avalonia.Layout;
-
-using Beutl.Controls.Behaviors;
-using Beutl.Controls.Extensions;
-
-namespace Beutl.Controls;
-
-[PseudoClasses(":dragging", ":lockdrag")]
-public partial class BcTabItem : TabItem
-{
- private readonly ItemDragBehavior _dragBehavior;
- private Button _closeButton;
-
- public BcTabItem()
- {
- Closing += OnClosing;
- _dragBehavior = new ItemDragBehavior();
- _dragBehavior.Attach(this);
- }
-
- static BcTabItem()
- {
- TabStripPlacementProperty.Changed.AddClassHandler((x, _) => x.OnTabStripPlacementChanged());
- CanBeDraggedProperty.Changed.AddClassHandler((x, e) => x.OnCanDraggablePropertyChanged(x, e));
- IsSelectedProperty.Changed.AddClassHandler((x, _) => UpdatePseudoClass(x));
- IsClosableProperty.Changed.Subscribe(e =>
- {
- if (e.Sender is BcTabItem a && a._closeButton != null)
- {
- a._closeButton.IsVisible = a.IsClosable;
- }
- });
- }
-
- private void OnTabStripPlacementChanged()
- {
- _dragBehavior.Orientation = TabStripPlacement is Dock.Top or Dock.Bottom
- ? Orientation.Horizontal
- : Orientation.Vertical;
- }
-
- private static void UpdatePseudoClass(BcTabItem item)
- {
- if (!item.IsSelected)
- {
- item.PseudoClasses.Remove(":dragging");
- }
- }
-
- internal bool CloseCore()
- {
- if (Parent is TabControl x)
- {
- try
- {
- x.CloseTab(this);
- return true;
- }
- catch
- {
- return false;
- }
- }
- return false;
- }
-
- public bool Close()
- {
- RaiseEvent(new RoutedEventArgs(ClosingEvent));
- return CloseCore();
- }
-
- protected void OnCanDraggablePropertyChanged(object sender, AvaloniaPropertyChangedEventArgs e)
- {
- if (CanBeDragged)
- {
- PseudoClasses.Add(":lockdrag");
- }
- else
- {
- PseudoClasses.Remove(":lockdrag");
- }
- }
-
- protected override void OnApplyTemplate(TemplateAppliedEventArgs e)
- {
- base.OnApplyTemplate(e);
-
- _closeButton = e.NameScope.Find
@@ -102,7 +102,7 @@
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Theme="{StaticResource FlyoutAcceptDismiss}">
-
+
@@ -144,16 +144,16 @@
VerticalAlignment="Center"
Text="{TemplateBinding DrawableName}" />
-
+
@@ -247,7 +247,7 @@
-
@@ -263,7 +263,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/ColorEditor.axaml b/src/Beutl.Controls/Styling/PropertyEditors/ColorEditor.axaml
index 64c5bcd2e..f495a542e 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/ColorEditor.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/ColorEditor.axaml
@@ -48,11 +48,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
@@ -107,11 +107,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
@@ -162,11 +162,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/DraggablePickerFlyoutPresenter.axaml b/src/Beutl.Controls/Styling/PropertyEditors/DraggablePickerFlyoutPresenter.axaml
index 1ff54bb48..8c903606a 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/DraggablePickerFlyoutPresenter.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/DraggablePickerFlyoutPresenter.axaml
@@ -58,7 +58,7 @@
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Theme="{StaticResource TransparentButton}">
-
+
@@ -75,7 +75,7 @@
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Theme="{StaticResource FlyoutAcceptDismiss}">
-
+
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/ExpressionEditorFlyoutPresenter.axaml b/src/Beutl.Controls/Styling/PropertyEditors/ExpressionEditorFlyoutPresenter.axaml
index 34324f534..c1defb1b9 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/ExpressionEditorFlyoutPresenter.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/ExpressionEditorFlyoutPresenter.axaml
@@ -37,11 +37,11 @@
-
+
-
+
@@ -55,7 +55,7 @@
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Theme="{StaticResource TransparentButton}">
-
+
@@ -72,7 +72,7 @@
MinHeight="100"
MaxHeight="200"
TextWrapping="Wrap"
- Watermark="Sin(Time * 2 * PI) * 100"
+ PlaceholderText="Sin(Time * 2 * PI) * 100"
Text="{TemplateBinding ExpressionText, Mode=TwoWay}"
VerticalContentAlignment="Top" />
-
+
@@ -189,7 +189,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/GradingColorEditor.axaml b/src/Beutl.Controls/Styling/PropertyEditors/GradingColorEditor.axaml
index 7c2320563..06282eb61 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/GradingColorEditor.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/GradingColorEditor.axaml
@@ -48,11 +48,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
@@ -107,11 +107,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
@@ -162,11 +162,11 @@
BorderThickness="1"
CornerRadius="{DynamicResource ControlCornerRadius}" />
-
+
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/GradingColorPicker.axaml b/src/Beutl.Controls/Styling/PropertyEditors/GradingColorPicker.axaml
index 34d25002b..bc0d933e7 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/GradingColorPicker.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/GradingColorPicker.axaml
@@ -83,7 +83,7 @@
Orientation="Horizontal"
Spacing="4">
-
+
@@ -111,7 +111,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/LibraryItemPickerFlyoutPresenter.axaml b/src/Beutl.Controls/Styling/PropertyEditors/LibraryItemPickerFlyoutPresenter.axaml
index 2284217bf..5720cb3cc 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/LibraryItemPickerFlyoutPresenter.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/LibraryItemPickerFlyoutPresenter.axaml
@@ -50,12 +50,12 @@
-
+
-
+
-
+
-
+
@@ -208,7 +208,7 @@
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Theme="{StaticResource TransparentButton}">
-
+
@@ -225,7 +225,7 @@
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Theme="{StaticResource FlyoutAcceptDismiss}">
-
+
@@ -246,7 +246,7 @@
Classes="clearButton"
IsVisible="False"
Text="{TemplateBinding SearchText, Mode=TwoWay}"
- Watermark="{x:Static lang:Strings.Search}" />
+ PlaceholderText="{x:Static lang:Strings.Search}" />
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPicker.axaml b/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPicker.axaml
index 548971094..6b65eb43b 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPicker.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPicker.axaml
@@ -83,13 +83,13 @@
Orientation="Horizontal"
Spacing="4">
-
+
-
+
-
+
@@ -129,7 +129,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPickerFlyoutPresenter.axaml b/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPickerFlyoutPresenter.axaml
index e09031e9d..d0e4b5f61 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPickerFlyoutPresenter.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/SimpleColorPickerFlyoutPresenter.axaml
@@ -40,10 +40,10 @@
ColumnDefinitions="*,Auto">
-
+
-
+
@@ -57,7 +57,7 @@
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Theme="{StaticResource TransparentButton}">
-
+
@@ -74,7 +74,7 @@
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Theme="{StaticResource FlyoutAcceptDismiss}">
-
+
@@ -150,7 +150,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/StorageFileEditor.axaml b/src/Beutl.Controls/Styling/PropertyEditors/StorageFileEditor.axaml
index 7a9133bf5..71f680e77 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/StorageFileEditor.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/StorageFileEditor.axaml
@@ -33,12 +33,12 @@
BorderBrush="{DynamicResource TextControlButtonBorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="{TemplateBinding CornerRadius}">
-
+
@@ -49,7 +49,7 @@
-
@@ -60,7 +60,7 @@
-
diff --git a/src/Beutl.Controls/Styling/PropertyEditors/Vector2Editor.axaml b/src/Beutl.Controls/Styling/PropertyEditors/Vector2Editor.axaml
index 9fc2b8be5..ac9c10a15 100644
--- a/src/Beutl.Controls/Styling/PropertyEditors/Vector2Editor.axaml
+++ b/src/Beutl.Controls/Styling/PropertyEditors/Vector2Editor.axaml
@@ -73,7 +73,7 @@
FontSize="{TemplateBinding FontSize}"
Foreground="{DynamicResource SystemAccentColor}"
IsVisible="False"
- Text="{TemplateBinding Watermark}" />
+ Text="{TemplateBinding PlaceholderText}" />
@@ -143,8 +145,8 @@
Margin="4,0,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Center"
- ToolTip.Tip="{TemplateBinding Description}"
- Text="{TemplateBinding Header}" />
+ Text="{TemplateBinding Header}"
+ ToolTip.Tip="{TemplateBinding Description}" />
@@ -164,8 +166,10 @@
Grid.Column="1"
Margin="4"
HorizontalContentAlignment="Right"
- IsEnabled="{TemplateBinding IsReadOnly, Converter={x:Static BoolConverters.Not}}"
- Text="{TemplateBinding FirstText, Mode=TwoWay}"
+ IsEnabled="{TemplateBinding IsReadOnly,
+ Converter={x:Static BoolConverters.Not}}"
+ Text="{TemplateBinding FirstText,
+ Mode=TwoWay}"
Theme="{StaticResource VectorElementTextBox}" />
@@ -180,8 +184,10 @@
Grid.Column="4"
Margin="4"
HorizontalContentAlignment="Right"
- IsEnabled="{TemplateBinding IsReadOnly, Converter={x:Static BoolConverters.Not}}"
- Text="{TemplateBinding SecondText, Mode=TwoWay}"
+ IsEnabled="{TemplateBinding IsReadOnly,
+ Converter={x:Static BoolConverters.Not}}"
+ Text="{TemplateBinding SecondText,
+ Mode=TwoWay}"
Theme="{StaticResource VectorElementTextBox}" />
@@ -239,8 +245,10 @@
Grid.Column="1"
Margin="4"
HorizontalContentAlignment="Right"
- IsEnabled="{TemplateBinding IsReadOnly, Converter={x:Static BoolConverters.Not}}"
- Text="{TemplateBinding FirstText, Mode=TwoWay}"
+ IsEnabled="{TemplateBinding IsReadOnly,
+ Converter={x:Static BoolConverters.Not}}"
+ Text="{TemplateBinding FirstText,
+ Mode=TwoWay}"
Theme="{StaticResource VectorElementTextBox}" />
@@ -255,8 +263,10 @@
Grid.Column="4"
Margin="4"
HorizontalContentAlignment="Right"
- IsEnabled="{TemplateBinding IsReadOnly, Converter={x:Static BoolConverters.Not}}"
- Text="{TemplateBinding SecondText, Mode=TwoWay}"
+ IsEnabled="{TemplateBinding IsReadOnly,
+ Converter={x:Static BoolConverters.Not}}"
+ Text="{TemplateBinding SecondText,
+ Mode=TwoWay}"
Theme="{StaticResource VectorElementTextBox}" />
@@ -342,8 +352,8 @@
VerticalAlignment="Center"
ClipToBounds="False"
Text="{TemplateBinding Header}"
- ToolTip.Tip="{TemplateBinding Description}"
- TextTrimming="CharacterEllipsis" />
+ TextTrimming="CharacterEllipsis"
+ ToolTip.Tip="{TemplateBinding Description}" />
@@ -362,8 +372,10 @@
@@ -405,8 +417,8 @@
Margin="4,0,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Center"
- ToolTip.Tip="{TemplateBinding Description}"
- Text="{TemplateBinding Header}" />
+ Text="{TemplateBinding Header}"
+ ToolTip.Tip="{TemplateBinding Description}" />
@@ -421,8 +433,10 @@
Margin="4,4"
HorizontalAlignment="Stretch"
HorizontalContentAlignment="Left"
- IsEnabled="{TemplateBinding IsReadOnly, Converter={x:Static BoolConverters.Not}}"
- Text="{TemplateBinding FirstText, Mode=TwoWay}"
+ IsEnabled="{TemplateBinding IsReadOnly,
+ Converter={x:Static BoolConverters.Not}}"
+ Text="{TemplateBinding FirstText,
+ Mode=TwoWay}"
Theme="{StaticResource VectorElementTextBox}" />
diff --git a/src/Beutl.Controls/Styling/ToggleButtonStyles.axaml b/src/Beutl.Controls/Styling/ToggleButtonStyles.axaml
index ae0787295..44c3fc823 100644
--- a/src/Beutl.Controls/Styling/ToggleButtonStyles.axaml
+++ b/src/Beutl.Controls/Styling/ToggleButtonStyles.axaml
@@ -9,13 +9,13 @@
-
+
-
+
-
+
diff --git a/src/Beutl.Editor.Components/Beutl.Editor.Components.csproj b/src/Beutl.Editor.Components/Beutl.Editor.Components.csproj
index 97815a439..bd1f299f2 100644
--- a/src/Beutl.Editor.Components/Beutl.Editor.Components.csproj
+++ b/src/Beutl.Editor.Components/Beutl.Editor.Components.csproj
@@ -20,7 +20,7 @@
-
+
diff --git a/src/Beutl.Editor.Components/FileBrowserTab/ViewModels/FileBrowserTabViewModel.cs b/src/Beutl.Editor.Components/FileBrowserTab/ViewModels/FileBrowserTabViewModel.cs
index 8fbcea1ee..2522d2ba4 100644
--- a/src/Beutl.Editor.Components/FileBrowserTab/ViewModels/FileBrowserTabViewModel.cs
+++ b/src/Beutl.Editor.Components/FileBrowserTab/ViewModels/FileBrowserTabViewModel.cs
@@ -257,17 +257,17 @@ public void OpenFile(string path)
public async Task DeleteItemAsync(FileSystemItemViewModel item)
{
- var dialog = new ContentDialog
+ var dialog = new FAContentDialog
{
Title = Strings.Delete,
Content = string.Format(MessageStrings.ConfirmDeleteFile, item.Name.Value),
PrimaryButtonText = Strings.Yes,
CloseButtonText = Strings.No,
- DefaultButton = ContentDialogButton.Close
+ DefaultButton = FAContentDialogButton.Close
};
var result = await dialog.ShowAsync();
- if (result == ContentDialogResult.Primary)
+ if (result == FAContentDialogResult.Primary)
{
try
{
@@ -299,17 +299,17 @@ public async Task DeleteItemsAsync(IReadOnlyList items)
return;
}
- var dialog = new ContentDialog
+ var dialog = new FAContentDialog
{
Title = Strings.Delete,
Content = string.Format(Strings.DeleteSelectedItems, items.Count),
PrimaryButtonText = Strings.Yes,
CloseButtonText = Strings.No,
- DefaultButton = ContentDialogButton.Close
+ DefaultButton = FAContentDialogButton.Close
};
var result = await dialog.ShowAsync();
- if (result == ContentDialogResult.Primary)
+ if (result == FAContentDialogResult.Primary)
{
foreach (var item in items)
{
@@ -368,7 +368,7 @@ public async Task RenameItemAsync(FileSystemItemViewModel item, string newName)
if (File.Exists(newPath) || Directory.Exists(newPath))
{
- var dialog = new ContentDialog
+ var dialog = new FAContentDialog
{
Title = Strings.Error,
Content = string.Format(MessageStrings.RenameConflict, item.Name.Value, newName),
diff --git a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml
index 758d70c3f..79d5f21dd 100644
--- a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml
+++ b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml
@@ -134,24 +134,24 @@
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
diff --git a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml.cs b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml.cs
index 1a2a71b08..cca244101 100644
--- a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml.cs
+++ b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileBrowserTabView.axaml.cs
@@ -196,7 +196,7 @@ private async void StartRename(FileSystemItemViewModel item, Control? sourceCont
flyout.ShowAt(target, true);
}
- private void BreadcrumbBarItemClicked(BreadcrumbBar sender, BreadcrumbBarItemClickedEventArgs args)
+ private void BreadcrumbBarItemClicked(FABreadcrumbBar sender, FABreadcrumbBarItemClickedEventArgs args)
{
ViewModel?.NavigateToBreadcrumb(args.Index);
}
diff --git a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileItemDragBehavior.cs b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileItemDragBehavior.cs
index b4f634862..5ec7c9c73 100644
--- a/src/Beutl.Editor.Components/FileBrowserTab/Views/FileItemDragBehavior.cs
+++ b/src/Beutl.Editor.Components/FileBrowserTab/Views/FileItemDragBehavior.cs
@@ -15,6 +15,7 @@ public class FileItemDragBehavior : Behavior
private Point? _dragStartPoint;
private FileSystemItemViewModel? _dragItem;
private bool _isDragStarting;
+ private PointerPressedEventArgs? _lastPointerPressedArgs;
// FileBrowserTab内部から開始されたドラッグ操作が進行中かどうかを示す。
// ドロップ時にコピーではなく移動として扱うべきかの判定に用いる。
@@ -51,12 +52,13 @@ private void OnPointerPressed(object? sender, PointerPressedEventArgs e)
{
_dragStartPoint = e.GetPosition(AssociatedObject);
_dragItem = item;
+ _lastPointerPressedArgs = e;
}
}
private async void OnPointerMoved(object? sender, PointerEventArgs e)
{
- if (_dragStartPoint == null || _dragItem == null || _isDragStarting || AssociatedObject == null)
+ if (_dragStartPoint == null || _dragItem == null || _isDragStarting || AssociatedObject == null || _lastPointerPressedArgs == null)
return;
if (!e.GetCurrentPoint(AssociatedObject).Properties.IsLeftButtonPressed)
@@ -103,12 +105,13 @@ private async void OnPointerMoved(object? sender, PointerEventArgs e)
// 外部アプリ(Finder/Explorer等)にMoveを要求させないため、ソース側ではCopyのみを許可する。
// FileBrowserTab内部での移動は、ドロップハンドラ側で IsInternalDragInProgress を見て実施する。
- await DragDrop.DoDragDropAsync(e, data, DragDropEffects.Copy);
+ await DragDrop.DoDragDropAsync(_lastPointerPressedArgs, data, DragDropEffects.Copy);
}
finally
{
_dragStartPoint = null;
_dragItem = null;
+ _lastPointerPressedArgs = null;
_isDragStarting = false;
IsInternalDragInProgress = false;
}
diff --git a/src/Beutl.Editor.Components/GraphEditorTab/Views/GraphEditorTabView.axaml b/src/Beutl.Editor.Components/GraphEditorTab/Views/GraphEditorTabView.axaml
index e67196171..c7d5100f4 100644
--- a/src/Beutl.Editor.Components/GraphEditorTab/Views/GraphEditorTabView.axaml
+++ b/src/Beutl.Editor.Components/GraphEditorTab/Views/GraphEditorTabView.axaml
@@ -29,7 +29,7 @@
{
var tabItem = new TabStripItem();
- var binding = new Binding($"{nameof(LibraryTabViewModel.LibraryTabDisplayModes)}[{item.Id}]", BindingMode.OneWay)
+ var binding = new ReflectionBinding($"{nameof(LibraryTabViewModel.LibraryTabDisplayModes)}[{item.Id}]")
{
- Converter = new FuncValueConverter(v => v == LibraryTabDisplayMode.Show)
+ Converter = new FuncValueConverter(v => v == LibraryTabDisplayMode.Show),
+ Mode = BindingMode.OneWay
};
tabItem.Bind(IsVisibleProperty, binding);
tabItem.Content = new StackPanel
@@ -50,9 +51,9 @@ public LibraryTabView()
new TextBlock { Text = item.Text }
}
};
- var switchMenu = new ToggleMenuFlyoutItem
+ var switchMenu = new FAToggleMenuFlyoutItem
{
- [!ToggleMenuFlyoutItem.IsCheckedProperty] = binding,
+ [!FAToggleMenuFlyoutItem.IsCheckedProperty] = binding,
Text = Strings.AlwaysDisplay
};
switchMenu.Click += (s, e) =>
@@ -76,13 +77,14 @@ public LibraryTabView()
{
ItemsSource = s_tabItems.Select(item =>
{
- var binding = new Binding($"{nameof(LibraryTabViewModel.LibraryTabDisplayModes)}[{item.Id}]", BindingMode.OneWay)
+ var binding = new ReflectionBinding($"{nameof(LibraryTabViewModel.LibraryTabDisplayModes)}[{item.Id}]")
{
- Converter = new FuncValueConverter(v => v == LibraryTabDisplayMode.Show)
+ Converter = new FuncValueConverter(v => v == LibraryTabDisplayMode.Show),
+ Mode = BindingMode.OneWay
};
- var switchMenu = new ToggleMenuFlyoutItem
+ var switchMenu = new FAToggleMenuFlyoutItem
{
- [!ToggleMenuFlyoutItem.IsCheckedProperty] = binding,
+ [!FAToggleMenuFlyoutItem.IsCheckedProperty] = binding,
Text = item.Text
};
switchMenu.Click += (s, e) =>
diff --git a/src/Beutl.Editor.Components/LibraryTab/Views/LibraryViews/SearchView.axaml b/src/Beutl.Editor.Components/LibraryTab/Views/LibraryViews/SearchView.axaml
index ef4082c98..6aa1ac93b 100644
--- a/src/Beutl.Editor.Components/LibraryTab/Views/LibraryViews/SearchView.axaml
+++ b/src/Beutl.Editor.Components/LibraryTab/Views/LibraryViews/SearchView.axaml
@@ -15,7 +15,7 @@
+ PlaceholderText="{x:Static lang:Strings.Search}" />
-
-
+
-
-
-
-
+
+
+
+
-
-
+
+
diff --git a/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml b/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml
index 610780ef2..0920ef994 100644
--- a/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml
+++ b/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml
@@ -15,20 +15,20 @@
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
diff --git a/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml.cs b/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml.cs
index 3abacf8a5..dd4708cce 100644
--- a/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml.cs
+++ b/src/Beutl.Editor.Components/NodeGraphTab/Views/NodeGraphTabView.axaml.cs
@@ -13,7 +13,7 @@ public NodeGraphTabView()
InitializeComponent();
}
- private void BreadcrumbBarItemClicked(BreadcrumbBar sender, BreadcrumbBarItemClickedEventArgs args)
+ private void BreadcrumbBarItemClicked(FABreadcrumbBar sender, FABreadcrumbBarItemClickedEventArgs args)
{
if (DataContext is NodeGraphTabViewModel viewModel)
{
diff --git a/src/Beutl.Editor.Components/ObjectPropertyTab/Views/ObjectPropertyTabView.axaml b/src/Beutl.Editor.Components/ObjectPropertyTab/Views/ObjectPropertyTabView.axaml
index bd63b3881..841aa25e9 100644
--- a/src/Beutl.Editor.Components/ObjectPropertyTab/Views/ObjectPropertyTabView.axaml
+++ b/src/Beutl.Editor.Components/ObjectPropertyTab/Views/ObjectPropertyTabView.axaml
@@ -15,7 +15,7 @@
Padding="8"
BorderThickness="0"
Background="Transparent">
-
+
diff --git a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml
index 6be29ba48..336d40a6f 100644
--- a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml
+++ b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml
@@ -34,36 +34,36 @@
diff --git a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml.cs b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml.cs
index 8e043b9e0..cf9d6d0d1 100644
--- a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml.cs
+++ b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorTabView.axaml.cs
@@ -439,10 +439,10 @@ private Thumb CreateThumb()
[!ThemeProperty] = new DynamicResourceExtension("PathEditorControlPointThumbTheme")
};
var flyout = new FAMenuFlyout();
- var delete = new MenuFlyoutItem
+ var delete = new FAMenuFlyoutItem
{
Text = Strings.Delete,
- IconSource = new SymbolIconSource { Symbol = Symbol.Delete }
+ IconSource = new FASymbolIconSource { Symbol = FASymbol.Delete }
};
delete.Click += OnDeleteClicked;
flyout.ItemsSource = new[] { delete };
@@ -456,7 +456,7 @@ private Thumb CreateThumb()
private void OnDeleteClicked(object? sender, RoutedEventArgs e)
{
- if (sender is MenuFlyoutItem { DataContext: PathSegment op }
+ if (sender is FAMenuFlyoutItem { DataContext: PathSegment op }
&& DataContext is PathEditorTabViewModel viewModel
&& viewModel.FigureContext.Value is IPathFigureEditorContext figureContext)
{
@@ -478,7 +478,7 @@ private void OnCanvasPointerPressed(object? sender, PointerPressedEventArgs e)
private void ToggleDragModeClick(object? sender, RoutedEventArgs e)
{
string? tag = null;
- if (sender is RadioMenuFlyoutItem button1)
+ if (sender is FARadioMenuFlyoutItem button1)
{
tag = button1.Tag as string;
}
@@ -510,7 +510,7 @@ private void ToggleDragModeClick(object? sender, RoutedEventArgs e)
private void AddOpClicked(object? sender, RoutedEventArgs e)
{
- if (sender is MenuFlyoutItem item
+ if (sender is FAMenuFlyoutItem item
&& DataContext is PathEditorTabViewModel viewModel
&& viewModel.PathFigure.Value is { } figure
&& viewModel.FigureContext.Value is IPathFigureEditorContext figureContext)
diff --git a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorView.axaml b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorView.axaml
index b008c23ee..436561283 100644
--- a/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorView.axaml
+++ b/src/Beutl.Editor.Components/PathEditorTab/Views/PathEditorView.axaml
@@ -19,34 +19,34 @@