Skip to content

Add support for night mode #749

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

Merged
merged 3 commits into from
Jun 15, 2017
Merged

Add support for night mode #749

merged 3 commits into from
Jun 15, 2017

Conversation

SUPERCILEX
Copy link
Collaborator

@samtstern Dang, I completely forgot about the night mode issue but the styling PR was the best desision ever! 😄 It just works™️

Here are a bunch of screenshots I took while testing, everything LGTM!
screenshot_20170612-123707
screenshot_20170612-123714
screenshot_20170612-123717
screenshot_20170612-123728
screenshot_20170612-123745
screenshot_20170612-123756
screenshot_20170612-123819
screenshot_20170612-123910
screenshot_20170612-123938
screenshot_20170612-123942
screenshot_20170612-124230
screenshot_20170612-124241
screenshot_20170612-123505

@SUPERCILEX SUPERCILEX changed the base branch from master to version-2.1.0-dev June 13, 2017 01:00
@SUPERCILEX
Copy link
Collaborator Author

@samtstern I updated the base for this PR to 2.1

@SUPERCILEX SUPERCILEX changed the base branch from version-2.1.0-dev to version-2.0.0-dev June 13, 2017 01:04
@SUPERCILEX SUPERCILEX changed the base branch from version-2.0.0-dev to version-2.1.0-dev June 13, 2017 01:04
@SUPERCILEX
Copy link
Collaborator Author

@samtstern what are your thoughts on this?

Copy link
Contributor

@samtstern samtstern left a comment

Choose a reason for hiding this comment

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

The changes are really small so in general LGTM. And thank you for all of the awesome screenshots.

I don't really know much about night mode though, is what you did in app something that developers will have to do in their apps to enable night mode?


import com.squareup.leakcanary.LeakCanary;
import com.squareup.leakcanary.RefWatcher;

public class LeakCatcher extends Application {
private RefWatcher mRefWatcher;

static {
AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_AUTO);
Copy link
Contributor

Choose a reason for hiding this comment

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

Feels a little strange to do this in a class called 'LeakCatcher'. Also should we use 'MODE_NIGHT_SYSTEM' to respect the system setting?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@samtstern Same, I was just being lazy. 😄

@SUPERCILEX
Copy link
Collaborator Author

@samtstern As for the whole night mode thing, I've been really getting into AppCompat's coolness and I found these great resources which should clear things up for you:

@SUPERCILEX
Copy link
Collaborator Author

TL;DR

image

image

image

image

@samtstern samtstern merged commit 9bbcf8d into firebase:version-2.1.0-dev Jun 15, 2017
@SUPERCILEX SUPERCILEX deleted the night-mode branch June 15, 2017 20:16
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.

2 participants