Skip to content

[codex] add macOS controller support#271

Draft
a16797 wants to merge 1 commit into
MistEO:mainfrom
a16797:codex/add-macos-controller-support
Draft

[codex] add macOS controller support#271
a16797 wants to merge 1 commit into
MistEO:mainfrom
a16797:codex/add-macos-controller-support

Conversation

@a16797

@a16797 a16797 commented Jul 1, 2026

Copy link
Copy Markdown

Summary

  • add ProjectInterface and runtime config support for the MacOS controller type
  • wire macOS native window discovery/selection through the existing desktop-window flow
  • create MaaFramework macOS controllers with Controller::new_macos
  • filter the controller to macOS hosts and add localized controller labels

Closes #242

Adversarial review notes

  • verified the pinned maa-framework 1.16.0 docs expose Controller::new_macos(window_id, screencap_method, input_method)
  • kept Win32-only process-path probing out of the macOS window path
  • rechecked window-controller conditionals so macOS is treated as a selectable window controller, not as PlayCover/address input

Validation

  • npm run build (tsc && vite build) passed
  • git diff --check passed

Not verified

  • Tauri/Rust compilation was not run locally because this Windows environment does not have cargo/rustc
  • native macOS controller runtime behavior still needs validation on macOS with MaaFramework dylibs and permissions

Summary by Sourcery

为现有桌面控制器新增一流的 macOS 原生窗口控制器支持,并通过共享的连接/选择流程进行路由。

New Features:

  • 在前端和 Tauri 命令类型中引入 macOS 控制器类型和配置,通过 Controller::new_macos 连接 MaaFramework 的 macOS 控制器。
  • 使用现有桌面窗口(Win32/Gamepad)连接工作流,实现 macOS 原生窗口的发现和选择功能,包括工具栏、连接面板和设备选择器等用户体验。
  • 为 macOS 窗口控制器在所有受支持的界面语言中添加本地化标签和图标。

Enhancements:

  • 通过抽象 Win32、Gamepad 和 macOS 控制器的共享逻辑(包括正则解析和控制器配置构建),统一桌面窗口控制器处理方式。
  • 在界面加载器中将 macOS 原生控制器和 PlayCover 限制为仅在 macOS 主机上可用,并优化回调日志记录,将 macOS 控制器视为基于窗口的控制器。
Original summary in English

Summary by Sourcery

Add first-class macOS native window controller support alongside existing desktop controllers and route it through the shared connection/selection flows.

New Features:

  • Introduce a macOS controller type and config in both frontend and Tauri command types to connect MaaFramework macOS controllers via Controller::new_macos.
  • Enable macOS native window discovery and selection using the existing desktop window (Win32/Gamepad) connection workflows, including toolbar, connection panel, and device selector UX.
  • Add localized labels and icons for macOS window controllers across supported interface languages.

Enhancements:

  • Unify desktop window controller handling by abstracting shared logic for Win32, Gamepad, and macOS controllers, including regex resolution and controller config construction.
  • Restrict macOS-native controllers and PlayCover to macOS hosts in the interface loader and refine callback logging to treat macOS controllers as window-based.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

对原生mac控制器的支持

1 participant