From 9b5711d3124622b1f1b18500d442c76492da877a Mon Sep 17 00:00:00 2001
From: chunhualin1 <chunhualin1@lenovo.com>
Date: 星期一, 17 八月 2026 16:52:33 +0800
Subject: [PATCH] 优化llm插件及bug修复

---
 src/Moli.Desktop/Layout/Geometry.cs |   25 +++++++++++++++++++------
 1 files changed, 19 insertions(+), 6 deletions(-)

diff --git a/src/Moli.Desktop/Layout/Geometry.cs b/src/Moli.Desktop/Layout/Geometry.cs
index 9890e19..e3f5fcd 100644
--- a/src/Moli.Desktop/Layout/Geometry.cs
+++ b/src/Moli.Desktop/Layout/Geometry.cs
@@ -1,3 +1,4 @@
+using System.Text.Json.Serialization;
 using Moli.Desktop.Plugins;
 
 namespace Moli.Desktop.Layout;
@@ -23,11 +24,19 @@
     public override string ToString() => Value;
 }
 
-public enum DisplayPriority
+public enum DisplayLayer
 {
-    DesktopLayer,
-    IconLayer,
-    AppLayer
+    [JsonStringEnumMemberName("desktop")]
+    Desktop,
+
+    [JsonStringEnumMemberName("normal")]
+    Normal,
+
+    [JsonStringEnumMemberName("app-top")]
+    AppTop,
+
+    [JsonStringEnumMemberName("global-top")]
+    GlobalTop
 }
 
 public sealed record WidgetRuntimeState
@@ -37,10 +46,14 @@
     public required RectD Bounds { get; init; }
     public required MonitorId MonitorId { get; init; }
     public bool IsVisible { get; init; } = true;
+    public bool LayoutIsVisible { get; init; } = true;
     public bool IsLocked { get; init; }
     public double Opacity { get; init; } = 1;
     public bool ClickThrough { get; init; } = true;
-    public DisplayPriority DisplayPriority { get; init; } = DisplayPriority.IconLayer;
+    public bool LayoutClickThrough { get; init; } = true;
+    public bool IsInteractable { get; init; }
+    public bool HasSessionInteractable { get; init; }
+    public DisplayLayer DisplayLayer { get; init; } = DisplayLayer.Desktop;
 }
 
 public sealed record WidgetLayoutPatch
@@ -52,5 +65,5 @@
     public double? Opacity { get; init; }
     public bool? ClickThrough { get; init; }
     public double? Scale { get; init; }
-    public DisplayPriority? DisplayPriority { get; init; }
+    public DisplayLayer? DisplayLayer { get; init; }
 }

--
Gitblit v1.9.1