Skip to content

GD-1057: Remove key modifiery arguments from the simulate key press/ed release methods #1057

@MikeSchulze

Description

@MikeSchulze

Refactoring Type

Code cleanup/organization

Current State

@abstract func simulate_key_pressed(key_code: int, shift_pressed := false, ctrl_pressed := false) -> GdUnitSceneRunner

@abstract func simulate_key_press(key_code: int, shift_pressed := false, ctrl_pressed := false) -> GdUnitSceneRunner

@abstract func simulate_key_release(key_code: int, shift_pressed := false, ctrl_pressed := false) -> GdUnitSceneRunner

Problems and Motivation

The functions are marked as deprecated, and we need to remove the modifier arguments.
For more details, see #1055

Proposed Changes

@abstract func simulate_key_pressed(key_code: int) -> GdUnitSceneRunner

@abstract func simulate_key_press(key_code: int) -> GdUnitSceneRunner

@abstract func simulate_key_release(key_code: int) -> GdUnitSceneRunner

Affected Areas

SceneRunner API

Backward Compatibility

Godot compatibility is not affected.

Implementation Approach

Remove the modifier arguments and fix the tests.

Benefits and Risks

No response

Developer Notes

No response

Metadata

Metadata

Assignees

Labels

APIMarks the issue API related.refactoringMark to refactoring a implementation

Projects

Status

No status

Relationships

None yet

Development

No branches or pull requests

Issue actions