Skip to content

Commit 9cb31c8

Browse files
committed
Improve code quality
1 parent aaca0c0 commit 9cb31c8

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

Flow.Launcher.Infrastructure/Win32Helper.cs

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -299,15 +299,8 @@ public static Point TransformPixelsToDIP(Visual visual, double unitX, double uni
299299

300300
#region WndProc
301301

302-
public static bool WM_ENTERSIZEMOVE(uint msg)
303-
{
304-
return msg == PInvoke.WM_ENTERSIZEMOVE;
305-
}
306-
307-
public static bool WM_EXITSIZEMOVE(uint msg)
308-
{
309-
return msg == PInvoke.WM_EXITSIZEMOVE;
310-
}
302+
public const int WM_ENTERSIZEMOVE = (int)PInvoke.WM_ENTERSIZEMOVE;
303+
public const int WM_EXITSIZEMOVE = (int)PInvoke.WM_EXITSIZEMOVE;
311304

312305
#endregion
313306

Flow.Launcher/MainWindow.xaml.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -212,17 +212,18 @@ private async void OnLoaded(object sender, RoutedEventArgs _)
212212
break;
213213
}
214214
};
215+
215216
// ✅ QueryTextBox.Text 변경 감지 (글자 수 1 이상일 때만 동작하도록 수정)
216217
QueryTextBox.TextChanged += (sender, e) => UpdateClockPanelVisibility();
217218

218219
// ✅ ContextMenu.Visibility 변경 감지
219220
DependencyPropertyDescriptor
220-
.FromProperty(UIElement.VisibilityProperty, typeof(ContextMenu))
221+
.FromProperty(VisibilityProperty, typeof(ContextMenu))
221222
.AddValueChanged(ContextMenu, (s, e) => UpdateClockPanelVisibility());
222223

223224
// ✅ History.Visibility 변경 감지
224225
DependencyPropertyDescriptor
225-
.FromProperty(UIElement.VisibilityProperty, typeof(StackPanel)) // History는 StackPanel이라고 가정
226+
.FromProperty(VisibilityProperty, typeof(StackPanel)) // History는 StackPanel이라고 가정
226227
.AddValueChanged(History, (s, e) => UpdateClockPanelVisibility());
227228
}
228229

0 commit comments

Comments
 (0)