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

Enable help webui for checking update status and upgrade detector #271

Merged
merged 4 commits into from
Jul 30, 2018

Conversation

simonhong
Copy link
Member

@simonhong simonhong commented Jul 19, 2018

Close brave/brave-browser#316

SparkleGlue is glue layer between VersionUpdater/UpgradeDectector and Sparkle framework.
VersionUpdater is used to check update status and trigger update by about page.
UpgradeDetector is periodically checks whether there is already installed new version. If it detects newly installed one, notify it to its observers(app menu button). Then, observers notify/warn to relaunch browser.

This PR

  • Refactor BraveAppController/SparkleGlueMac
    • Delete update item from menu
    • Delete BraveAppController. Initialize sparkle in BraveBrowserMainPartsMac instead.
    • Move SUUpdateDelegate impl to SparkleGlueMac because SparkleGlueMac should know update status from Sparkle framework for future impl
  • Enable help webui for checking update status
    • Can trigger upgrade via loading help page
    • Shows update is in-progress and ready to relaunch
  • Enable upgrade detector
    • Upgrade detector detects upgrade status by checking installed version via sparkle glue
    • User can see upgrade notification via app menu button

Submitter Checklist:

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).
  • Tagged reviewers and labelled the pull request as needed.
  • Request a security/privacy review as needed.

Test Plan:

Manual update test.
Upgrade detector test by /src/out/Debug/Brave.app/Contents/MacOS/Brave --enable-logging=stderr --v=0 --check-for-update-interval=50

Reviewer Checklist:

  • New files have MPL-2.0 license header.
  • Request a security/privacy review as needed.
  • Adequate test coverage exists to prevent regressions

@simonhong simonhong self-assigned this Jul 19, 2018
@simonhong simonhong changed the title Cleanup/Refactoring BraveAppController/SparkleGlueMac Refactoring of BraveAppController/SparkleGlueMac Jul 19, 2018
@RyanJarv
Copy link
Contributor

+1 on deleting the update button, can be pretty confusing with silent updates enabled now

@simonhong simonhong force-pushed the cleanup_sparkle_glue branch 5 times, most recently from e5c7419 to 2f7f5c5 Compare July 20, 2018 08:26
* Delete update item from menu
* Delete BraveAppController. Initialize sparkle in BraveBrowserMainPartsMac instead.
* Move SUUpdateDelegate impl to SparkleGlueMac
@simonhong
Copy link
Member Author

Rebased on C68.

This PR disables sparkle's dialog UI.
With this, browser notifies that install is ready via app menu button.
@simonhong simonhong changed the title Refactoring of BraveAppController/SparkleGlueMac Enable help webui for checking update status and upgrade detector Jul 24, 2018
@simonhong simonhong requested a review from bbondy July 24, 2018 13:39
@simonhong
Copy link
Member Author

With this, all mac update related issues are cleared.

@simonhong simonhong requested a review from bridiver July 28, 2018 00:52
@simonhong
Copy link
Member Author

Kindly ping..

@bbondy bbondy merged commit 124433a into master Jul 30, 2018
@simonhong simonhong deleted the cleanup_sparkle_glue branch August 19, 2018 23:22
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.

3 participants