Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support smooth scrolling #640

Closed
wants to merge 3 commits into from
Closed

Conversation

szbergeron
Copy link

Adds a stub to allow directly pulling smooth scroll events from reason-sdl2

@bryphe
Copy link
Member

bryphe commented Nov 13, 2019

Awesome! Great to see this making its way in - thanks @szbergeron !

@szbergeron
Copy link
Author

szbergeron commented Nov 14, 2019

Depends on changes in revery-ui/esy-sdl2#6, revery-ui/reason-sdl2#25

Awesome! Great to see this making its way in - thanks @szbergeron !

Thanks, happy to help 😃

Comment on lines 342 to 344
| _ =>
log("Unknown event recieved");
()
Copy link
Author

Choose a reason for hiding this comment

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

Prints

let wheelEvent: Events.mouseWheelEvent = {
deltaX: float_of_int(deltaX),
deltaY: float_of_int(deltaY),
};
Event.dispatch(v.onMouseWheel, wheelEvent);
| Sdl2.Event.MousePan({deltaX, deltaY, _}) =>
log("====Pan of " ++ string_of_int(deltaX) ++ ", " ++ string_of_int(deltaY));
Copy link
Author

Choose a reason for hiding this comment

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

Prints

@szbergeron
Copy link
Author

/azp run

@azure-pipelines
Copy link

Commenter does not have sufficient privileges for PR 640 in repo revery-ui/revery

@szbergeron
Copy link
Author

@bryphe is running CI intended to be a privileged action?

@glennsl
Copy link
Member

glennsl commented Dec 7, 2019

/azp run

@revery-ui revery-ui deleted a comment from azure-pipelines bot Dec 7, 2019
@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@szbergeron
Copy link
Author

Bunch of funky stuff seems to be going on with CI for this

@glennsl
Copy link
Member

glennsl commented Dec 7, 2019

Hygiene check fails because of formatting. Run esy format locally, commit and push to fix. Windows is still working and the others succeeded, but with "issues" that are normal as far as I'm aware.

@szbergeron
Copy link
Author

Running esy format locally doesn't seem to change anything, not sure why the check failed

@szbergeron
Copy link
Author

/azp run

@azure-pipelines
Copy link

Commenter does not have sufficient privileges for PR 640 in repo revery-ui/revery

@glennsl
Copy link
Member

glennsl commented Dec 9, 2019

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@glennsl
Copy link
Member

glennsl commented Dec 9, 2019

Running esy format locally doesn't seem to change anything, not sure why the check failed

Might be different version, but it's also not completely stable I've found.

@glennsl
Copy link
Member

glennsl commented Dec 9, 2019

This includes a lot of unrelated changes, which makes it really hard to review. Do you think you could try a rebase?

@szbergeron
Copy link
Author

Oh whoops, figured it would reconcile. I can try rebasing but not sure if that would help.

@szbergeron
Copy link
Author

Might make more sense to just revert the top two commits and remake them

@glennsl
Copy link
Member

glennsl commented Dec 9, 2019

An interactive rebase allows you to do pretty much that.

@szbergeron
Copy link
Author

I seem to have gotten myself in a bit of a pickle trying to do it with rebasing, lots of conflicts and none of them make much sense 🤷‍♀️

@glennsl
Copy link
Member

glennsl commented Dec 10, 2019

That happens sometimes. Just git rebase --abort and try again.

The way I think about a rebase is that it replays a set of commits onto the HEAD of the branch or ref you specify. Typically the set set of commits is every commit in your branch from the most recent common ancestor, but you can select the commits yourself by doing an interactive rebase with git rebase -i.

When you run git rebase -i you'll get a list of commits in your editor. Delete every line with a commit that should already be in the new base, ie. that isn't yours and aren't merge commits. Save and quit. You'll most likely still get conflicts, but they should hopefully be relatively small and straight forward to fix since it's just your own changes.

Hope that helps! If not, let me know and I'll try to guide you as best I can.

@szbergeron szbergeron force-pushed the master branch 2 times, most recently from 871ed26 to bfa2a2d Compare December 13, 2019 03:31
@glennsl
Copy link
Member

glennsl commented Dec 13, 2019

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@glennsl
Copy link
Member

glennsl commented Dec 13, 2019

Looks much better! Didn't realize the change was this tiny though. It really would have been much easier to just copy the changes out and back in after resetting. But hopefully you learned something new!

@glennsl
Copy link
Member

glennsl commented Dec 13, 2019

Something's up with the Linux CI:

Failed to fetch https://packages.microsoft.com/ubuntu/16.04/prod/dists/xenial/main/binary-amd64/Packages.bz2  Hash Sum mismatch

@bryphe?

@szbergeron
Copy link
Author

@bryphe I'm currently a bit occupied with projects other than libscroll atm, but since scrolling on wayland is currently regressed by the esy-sdl2/reason-sdl2 changes being applied without this one it's probably a good idea to at least wrap up this part so it isn't up in the air. Would you be able to kick the CI to see if that issue was just a transient issue? I don't currently see why it failed (I think the build logs expired maybe?)

@Et7f3
Copy link
Member

Et7f3 commented Jan 16, 2020

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@szbergeron szbergeron changed the title [WIP] Support smooth scrolling Support smooth scrolling Jan 16, 2020
@szbergeron szbergeron requested a review from bryphe January 16, 2020 16:48
@szbergeron szbergeron requested a review from Et7f3 January 25, 2020 03:35
@szbergeron
Copy link
Author

I think this is obsolete now and is anyway superseded by libscroll integration, so closing while I can get libscroll patch at #766 working.

@szbergeron szbergeron closed this Apr 15, 2020
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.

4 participants