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

Run the Google Drive authorization flow in a separate thread and disable interaction until complete #309

Merged
merged 3 commits into from Jan 17, 2021

Conversation

jpgill86
Copy link
Owner

@jpgill86 jpgill86 commented Jan 17, 2021

The app's main window would become unresponsive while the authorization flow was waiting for user input in the web browser if triggered by the "Request Google Drive authorization now" menu action. Now the flow is executed on a separate thread so the app can remain responsive.

An instructive message is also displayed in the main window, and all menus are disabled until the flow completes.

Also hides the metadata selector and replaces it with a message when the auth flow is triggered by the menu action. If the auth flow is triggered by a download instead, it will still run on the network thread, but the metadata selector won't be hidden. This is not ideal, but making the download-triggered case the same would be difficult.
neurotic already handles this.
The menu bar gets disabled only if the auth flow is triggered by the menu action. It does not get disabled if triggered by a download. This is not ideal, but making the download-triggered case the same would be difficult.
@jpgill86 jpgill86 added the enhancement New feature or request label Jan 17, 2021
@jpgill86 jpgill86 added this to the 1.5.0 milestone Jan 17, 2021
@jpgill86 jpgill86 added bug Something isn't working and removed enhancement New feature or request labels Jan 17, 2021
@coveralls
Copy link

Coverage Status

Coverage increased (+0.01%) to 58.907% when pulling d22d3a6 on gdrive-auth-threading into 4bebf15 on master.

@jpgill86 jpgill86 merged commit 460fac0 into master Jan 17, 2021
@jpgill86 jpgill86 deleted the gdrive-auth-threading branch January 17, 2021 06:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants