Table of Contents

Class WindowZOrderManager

Namespace
Ink_Canvas.Helpers
Assembly
InkCanvasForClass.dll

窗口Z-Order管理器,用于管理窗口的层级顺序 在无焦点模式下,确保后打开的窗口能够置顶于先打开的窗口

public static class WindowZOrderManager
Inheritance
WindowZOrderManager
Inherited Members

Methods

BringToTop(Window)

将窗口移到最顶层

public static void BringToTop(Window window)

Parameters

window Window

要移到最顶层的窗口

CleanupInvalidWindows()

清理无效的窗口记录

public static void CleanupInvalidWindows()

ForceRefreshAllWindows()

强制刷新所有窗口的置顶状态

public static void ForceRefreshAllWindows()

GetWindowCount()

获取当前注册的窗口数量

public static int GetWindowCount()

Returns

int

窗口数量

HasChildWindowInForeground()

检查是否有子窗口在前景

public static bool HasChildWindowInForeground()

Returns

bool

如果有子窗口在前景返回true

RegisterWindow(Window, bool, bool)

注册窗口到Z-Order管理器

public static void RegisterWindow(Window window, bool isTopmost = false, bool isNoFocusMode = false)

Parameters

window Window

要注册的窗口

isTopmost bool

是否置顶

isNoFocusMode bool

是否无焦点模式

SetWindowTopmost(Window, bool)

设置窗口为置顶状态

public static void SetWindowTopmost(Window window, bool isTopmost)

Parameters

window Window

要置顶的窗口

isTopmost bool

是否置顶

UnregisterWindow(Window)

从Z-Order管理器中移除窗口

public static void UnregisterWindow(Window window)

Parameters

window Window

要移除的窗口