diff --git a/src/Ursa.Themes.Semi/Controls/Dialog.axaml b/src/Ursa.Themes.Semi/Controls/Dialog.axaml
index cebe482..8d35c05 100644
--- a/src/Ursa.Themes.Semi/Controls/Dialog.axaml
+++ b/src/Ursa.Themes.Semi/Controls/Dialog.axaml
@@ -7,68 +7,72 @@
+
+
+
-
+
-
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+
-
+
+
-
+
\ No newline at end of file
diff --git a/src/Ursa.Themes.Semi/Controls/Resizer.axaml b/src/Ursa.Themes.Semi/Controls/Resizer.axaml
index e349066..f184112 100644
--- a/src/Ursa.Themes.Semi/Controls/Resizer.axaml
+++ b/src/Ursa.Themes.Semi/Controls/Resizer.axaml
@@ -13,10 +13,12 @@
-
+
-
+
+
+
diff --git a/src/Ursa/Controls/Dialog/Dialog.cs b/src/Ursa/Controls/Dialog/Dialog.cs
index 08deb07..be9d516 100644
--- a/src/Ursa/Controls/Dialog/Dialog.cs
+++ b/src/Ursa/Controls/Dialog/Dialog.cs
@@ -205,6 +205,8 @@ public static class Dialog
window.IsCloseButtonVisible = options.IsCloseButtonVisible;
window.ShowInTaskbar = options.ShowInTaskBar;
window.CanDragMove = options.CanDragMove;
+ window.CanResize = options.CanResize;
+ window.IsManagedResizerVisible = options.CanResize;
if (options.StartupLocation == WindowStartupLocation.Manual)
{
if (options.Position is not null)
@@ -229,6 +231,8 @@ public static class Dialog
window.ShowInTaskbar = options.ShowInTaskBar;
window.IsCloseButtonVisible = options.IsCloseButtonVisible;
window.CanDragMove = options.CanDragMove;
+ window.IsManagedResizerVisible = options.CanResize;
+ window.CanResize = options.CanResize;
if (options.StartupLocation == WindowStartupLocation.Manual)
{
if (options.Position is not null)
diff --git a/src/Ursa/Controls/Dialog/DialogControlBase.cs b/src/Ursa/Controls/Dialog/DialogControlBase.cs
index aa0cabb..c22f331 100644
--- a/src/Ursa/Controls/Dialog/DialogControlBase.cs
+++ b/src/Ursa/Controls/Dialog/DialogControlBase.cs
@@ -24,6 +24,9 @@ public abstract class DialogControlBase : OverlayFeedbackElement
AvaloniaProperty.RegisterDirect(
nameof(IsFullScreen), o => o.IsFullScreen, (o, v) => o.IsFullScreen = v);
+ public static readonly StyledProperty CanResizeProperty = AvaloniaProperty.Register(
+ nameof(CanResize));
+
protected internal Button? _closeButton;
private bool _isFullScreen;
@@ -36,6 +39,12 @@ public abstract class DialogControlBase : OverlayFeedbackElement
IsFullScreenProperty.AffectsPseudoClass(PC_FullScreen);
}
+ public bool CanResize
+ {
+ get => GetValue(CanResizeProperty);
+ set => SetValue(CanResizeProperty, value);
+ }
+
internal HorizontalPosition HorizontalAnchor { get; set; } = HorizontalPosition.Center;
internal VerticalPosition VerticalAnchor { get; set; } = VerticalPosition.Center;
internal HorizontalPosition ActualHorizontalAnchor { get; set; }
diff --git a/src/Ursa/Controls/Dialog/DialogWindow.cs b/src/Ursa/Controls/Dialog/DialogWindow.cs
index 29f5398..f56ae09 100644
--- a/src/Ursa/Controls/Dialog/DialogWindow.cs
+++ b/src/Ursa/Controls/Dialog/DialogWindow.cs
@@ -17,8 +17,17 @@ public class DialogWindow : Window
public const string PART_TitleArea = "PART_TitleArea";
protected internal Button? _closeButton;
+
private Panel? _titleArea;
- public bool CanDragMove { get; set; } = true;
+
+ public static readonly StyledProperty IsManagedResizerVisibleProperty = AvaloniaProperty.Register(
+ nameof(IsManagedResizerVisible));
+
+ public bool IsManagedResizerVisible
+ {
+ get => GetValue(IsManagedResizerVisibleProperty);
+ set => SetValue(IsManagedResizerVisibleProperty, value);
+ }
static DialogWindow()
{
@@ -26,9 +35,11 @@ public class DialogWindow : Window
window.OnDataContextChange(e));
}
+ public bool CanDragMove { get; set; } = true;
+ internal bool? IsCloseButtonVisible { get; set; }
+
protected override Type StyleKeyOverride { get; } = typeof(DialogWindow);
- internal bool? IsCloseButtonVisible { get; set; }
private void OnDataContextChange(AvaloniaPropertyChangedEventArgs