blockly-samples icon indicating copy to clipboard operation
blockly-samples copied to clipboard

fix: scroll-options when drag surface is disabled

Open HollowMan6 opened this issue 3 years ago • 4 comments
trafficstars

Patch for integration of https://github.com/mit-cml/workspace-multiselect/pull/1

Signed-off-by: Hollow Man [email protected]

HollowMan6 avatar Jul 22 '22 02:07 HollowMan6

🤖 I detect that the PR title and the commit message differ and there's only one commit. To use the PR title for the commit history, you can use Github's automerge feature with squashing, or use automerge label. Good luck human!

-- conventional-commit-lint bot https://conventionalcommits.org/

I've read through this PR, and the info from your other PR, and I'm not following what this is fixing :/ Could you explain what this change is doing and why it's necessary?

BeksOmega avatar Jul 22 '22 15:07 BeksOmega

I've read through this PR, and the info from your other PR, and I'm not following what this is fixing :/ Could you explain what this change is doing and why it's necessary?

@BeksOmega

Say that when the drag surface is disabled (Blockly.utils.svgMath.is3dSupported() returns false), then the scroll-options plugin won't work without this patch.

As https://github.com/mit-cml/workspace-multiselect/pull/1 make drag surface disabled as the default, and you also mentioned that https://github.com/google/blockly/issues/6160 the drag surface has some performance issue, so I guess it would be the best to merge it into the upstream if someone choose to disable the drag surface while still want to use this plugin.

HollowMan6 avatar Jul 23 '22 01:07 HollowMan6

You can check the bugs when you use the monkey patch for disabling drag surface like here: https://github.com/HollowMan6/workspace-multiselect/blob/f2584f477903e2c3789f7f6f43577bc5dc4795ce/src/multiselect_patch.js#L13-L19

image For wheel scroll, it doesn't work anymore although no error is in the console logs. For edge scroll, errors will occur: image

HollowMan6 avatar Jul 23 '22 01:07 HollowMan6