Skip to content

Revert "Add support for stylus buttons"#187581

Open
flutteractionsbot wants to merge 1 commit into
flutter:masterfrom
flutteractionsbot:revert-183369-1780597283
Open

Revert "Add support for stylus buttons"#187581
flutteractionsbot wants to merge 1 commit into
flutter:masterfrom
flutteractionsbot:revert-183369-1780597283

Conversation

@flutteractionsbot
Copy link
Copy Markdown
Contributor

Reverts: Add support for stylus buttons

Initiated by: @loic-sharma

Reason for reverting: This PR causes the Windows windows_host_engine_test to fail. cc @CodeDoctorDE

Original PR Author: @CodeDoctorDE

Reviewed By: @mattkae

The original PR description is provided below:

Continuation of #165323.

Now we have stylus support on windows with the last pull request.

This pull request now adds support for invertedStylus and stylus buttons (primary + secondary).

The pull request shouldn't have any breaking changes other than the pointer event shows the correct button bitmap instead of 1 always on a stylus input.

Should completly fix: #102836.

Tested on my notebook:
grafik
repo for the demo code: https://github.com/CodeDoctorDE/flutter-input-demo

This pull request is currently a draft and my next steps is to add tests

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

@flutteractionsbot flutteractionsbot requested review from a team and loic-sharma as code owners June 4, 2026 18:21
@flutter-dashboard flutter-dashboard Bot added the CICD Run CI/CD label Jun 4, 2026
@github-actions github-actions Bot added engine flutter/engine related. See also e: labels. platform-windows Building on or for Windows specifically a: desktop Running on desktop team-windows Owned by the Windows platform team labels Jun 4, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request removes support for inverted stylus device kinds and stylus-specific button flags from the embedder API and the Windows platform implementation. The Windows platform pointer event handling has been refactored to remove the generic buttons parameter, replacing it with a button parameter for down and up events that is converted to mouse buttons. Associated unit tests and fixtures have been updated or removed to reflect these changes. I have no feedback to provide as there are no review comments.

@CodeDoctorDE
Copy link
Copy Markdown
Contributor

Quick question: how is the process to reland prs again?
I'm currently fixing the test and would then create a new pr?

@loic-sharma
Copy link
Copy Markdown
Member

@CodeDoctorDE Yup that's right, please create a new PR with the fix.

If you want to go the extra mile, I'd recommend that you squash your commits such that the original PR is the first commit, and the fix is the second commit. That makes it easier to review, but it's not required :)

@CodeDoctorDE
Copy link
Copy Markdown
Contributor

Do i need to wait until this pr is merged?

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

Labels

a: desktop Running on desktop CICD Run CI/CD engine flutter/engine related. See also e: labels. platform-windows Building on or for Windows specifically team-windows Owned by the Windows platform team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Flutter on Windows ignores stylus input

3 participants