Skip to content

Commit 3fa7605

Browse files
committed
chore: 兼容一下custom action输入 box 0
1 parent b402c73 commit 3fa7605

1 file changed

Lines changed: 0 additions & 7 deletions

File tree

source/MaaFramework/Task/Component/Actuator.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -679,13 +679,6 @@ ActionResult
679679
auto session = tasker_->resource()->custom_action(param.name);
680680
auto rect = helper_.get_target_rect(param.target, box);
681681
if (rect.empty()) {
682-
if (param.target.type != MAA_RES_NS::Action::Target::Type::Self) {
683-
LogError << "failed to get target rect" << VAR(name);
684-
return { };
685-
}
686-
687-
// Non-visual custom actions may intentionally use the default self target
688-
// even when the current recognition box is empty (e.g. after closing a window).
689682
LogWarn << "custom action target rect is empty, continue with empty rect" << VAR(name) << VAR(param.name);
690683
}
691684
bool ret = CustomAction::run(context_, name, session, param, reco_id, rect);

0 commit comments

Comments
 (0)