-
Notifications
You must be signed in to change notification settings - Fork 921
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
Bre onboarding 2 android #7292
Bre onboarding 2 android #7292
Conversation
Update BRE panel behaviour
@@ -122,9 +123,11 @@ public void RemovePublisherObserver(PublisherObserver observer) { | |||
} | |||
|
|||
public void OnNotifyFrontTabUrlChanged(int tabId, String url) { | |||
|
|||
Log.e("NTP", "OnNotifyFrontTabUrlChanged"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these logs just for debugging purposes? Should they be removed?
private static final int WITH_7_OPTIONS = 7; | ||
private static final int WITH_8_OPTIONS = 8; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe these should be called FEWER_OPTIONS
and MORE_OPTIONS
? Just thinking it will save some time if these numbers change in the future. Up to you!
double contribute = 15; | ||
if (checkedId == R.id.contribute_5_radio) { | ||
contribute = 5; | ||
} else if (checkedId == R.id.contribute_15_radio) { | ||
contribute = 15; | ||
} else if (checkedId == R.id.contribute_25_radio) { | ||
contribute = 25; | ||
} else if (checkedId == R.id.contribute_50_radio) { | ||
contribute = 50; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feels like a switch
statement might be a better fit here than an if-else, but it's up to you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@emerick for switch-case, R.id.contribute_50_radio
should be constant so we can't use it here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah OK, I didn't look carefully enough sorry!
// BraveRewardsHelper.updateBraveRewardsOpenCount(); | ||
// } | ||
// } | ||
if (root!= null && PackageUtils.isFirstInstall(mActivity)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Space after root
:-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
++
Verification in progress using NTP SI onboarding overlay/modal to be confirmed when this is checked on 1.18.x (cc @kjozwiak) Onboarding overlay/modal on chrome://rewards page to be implemented with brave/brave-browser#13008 in a follow up issue. Confirmed quick onboarding tour (post-opt in)
Confirmed ttps://github.com/brave/brave-browser/issues/12992 is fixed Hide Brave Rewards iconConfirmed able to Hide Brave Rewards icon on a clean install of 1.20.5. |
Resolves : brave/brave-browser#12533
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
,npm run lint
,npm run gn_check
,npm run tslint
git rebase master
(if needed).Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on.
Test Plan: