Add dark app theme support
This commit is contained in:
parent
f91ba5298e
commit
5f5e1682a0
@ -158,6 +158,7 @@ public class PdfViewer extends AppCompatActivity implements LoaderManager.Loader
|
|||||||
setContentView(R.layout.webview);
|
setContentView(R.layout.webview);
|
||||||
|
|
||||||
mWebView = findViewById(R.id.webview);
|
mWebView = findViewById(R.id.webview);
|
||||||
|
mWebView.setBackgroundColor(Color.TRANSPARENT);
|
||||||
|
|
||||||
if (BuildConfig.DEBUG) {
|
if (BuildConfig.DEBUG) {
|
||||||
WebView.setWebContentsDebuggingEnabled(true);
|
WebView.setWebContentsDebuggingEnabled(true);
|
||||||
|
9
app/src/main/res/values-night/styles.xml
Normal file
9
app/src/main/res/values-night/styles.xml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<resources>
|
||||||
|
|
||||||
|
<!-- Base application theme. -->
|
||||||
|
<style name="AppTheme" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
|
||||||
|
<!-- Customize your theme here. -->
|
||||||
|
<item name="android:windowBackground">#000000</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
|
</resources>
|
@ -1,7 +1,7 @@
|
|||||||
<resources>
|
<resources>
|
||||||
|
|
||||||
<!-- Base application theme. -->
|
<!-- Base application theme. -->
|
||||||
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
|
<style name="AppTheme" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
|
||||||
<!-- Customize your theme here. -->
|
<!-- Customize your theme here. -->
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user