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

[Feature]: Open Shelf at Cursor Position #14

Merged
merged 2 commits into from
Oct 3, 2021

Conversation

AJAYK-01
Copy link
Contributor

@AJAYK-01 AJAYK-01 commented Oct 3, 2021

Context

DropPoint currently opens new instances of the shelf on the top middle of screen.
This PR changes the position of a new instance to be near the current cursor position for better UX while trying to drag files into it.

Description of the Change

  • Changed the default window positions x and y coordinate in Window.js to follow the cursor position.
  • The coordinates are in such a way that as the shelf opens the cursor will be at the bottom left of the shelf.
  • Since Windows and Linux can open a window out of the bounds of the physical display, added a conditional check to detect if the shelf opens beyond the screen and make the necessary correction to the coordinates.

Demo

droppointpr mov

Possible Drawbacks

Nil

Verification Process

Tested on MacOs and Windows, and verified that the application and the new change works as intended.

Release Notes

DropPoint Shelf now opens at cursor position

@GameGodS3
Copy link
Owner

Awesome! 🤩❤
Thank You

@GameGodS3 GameGodS3 merged commit e2da2d8 into GameGodS3:main Oct 3, 2021
@GameGodS3 GameGodS3 added enhancement New feature or request hacktoberfest-accepted Your PR is valid and has been qualified for hacktoberfest labels Oct 3, 2021
@AJAYK-01 AJAYK-01 deleted the window-position-fix branch October 3, 2021 08:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request hacktoberfest-accepted Your PR is valid and has been qualified for hacktoberfest
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants