wip: start working on dark theme#138
Open
edoput wants to merge 1 commit intoj4velin:masterfrom
edoput:master
Open
wip: start working on dark theme#138edoput wants to merge 1 commit intoj4velin:masterfrom edoput:master
edoput wants to merge 1 commit intoj4velin:masterfrom
edoput:master
Conversation
- move theming to values - inherit from appcompat DayNight to support system dark mode
Author
|
So let's see the bad news; when changing this I get some strange error about not finding the Here's the log for this error, unfortunately I don't have that much experience so I'm not sure how to proceed |
Author
|
Installing on a virtual device got me further and now the error is caused by setting the action bar so definitely my bad. If you know how to fix this further please let me know E/AndroidRuntime: FATAL EXCEPTION: main
Process: de.j4velin.pedometer, PID: 3647
java.lang.RuntimeException: Unable to resume activity {de.j4velin.pedometer/de.j4velin.pedometer.ui.Activity_Main}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.app.ActionBar.setDisplayHomeAsUpEnabled(boolean)' on a null object reference
at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3581)
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3621)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2862)
at android.app.ActivityThread.-wrap11(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6494)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.app.ActionBar.setDisplayHomeAsUpEnabled(boolean)' on a null object reference
at de.j4velin.pedometer.ui.Fragment_Overview.onResume(Fragment_Overview.java:116)
at android.app.Fragment.performResume(Fragment.java:2554)
at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1322)
at android.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManager.java:1557)
at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1618)
at android.app.FragmentManagerImpl.dispatchMoveToState(FragmentManager.java:3027)
at android.app.FragmentManagerImpl.dispatchResume(FragmentManager.java:2989)
at android.app.FragmentController.dispatchResume(FragmentController.java:200)
at android.app.Activity.performResume(Activity.java:7138)
at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3556)
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3621)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2862)
at android.app.ActivityThread.-wrap11(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6494)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) |
mrgogomaster
approved these changes
Aug 11, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I've been toying around #86 and would like to add support a dark theme based on the
system DayNight theme.
It's not extremely clear to me what should be done but this is the gist of it
at the moment the
appThemeis not even populated but there you can put the values for the style of views and then apply the style on the single elements.