Skip to content

Commit 261b704

Browse files
committed
Fix About AlertDialog colour/theme
Setting `parent="Theme.StrokeInput"` also has the bonus effect of inflating the AlertDialog to full screen. Yay!
1 parent 755fa0d commit 261b704

3 files changed

Lines changed: 5 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
## [Unreleased]
55

66
- Made app main activity theme dark
7+
- Made `about.html` show full screen
78

89

910
## [v0.5.1] Visual improvements (2021-07-13)

app/src/main/java/io/github/yawnoc/strokeinput/MainActivity.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ else if (viewId == R.id.about_button) {
5757
final WebView htmlWebView = new WebView(this);
5858
htmlWebView.loadUrl(ABOUT_URI);
5959
final AlertDialog.Builder htmlAlertDialogBuilder =
60-
new AlertDialog.Builder(this);
60+
new AlertDialog.Builder(this, R.style.StrokeInputAlert);
6161
htmlAlertDialogBuilder
6262
.setView(htmlWebView)
6363
.setPositiveButton(R.string.activity_main_return_label, null)

app/src/main/res/values/styles.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
<item name="android:orientation">horizontal</item>
2121
<item name="android:gravity">center</item>
2222
</style>
23+
<style name="StrokeInputAlert" parent="Theme.StrokeInput">
24+
<item name="android:windowBackground">@color/very_dark_grey</item>
25+
</style>
2326
<style name="StrokeInputText" parent="android:Widget.EditText">
2427
<item name="android:textColor">?android:textColor</item>
2528
</style>

0 commit comments

Comments
 (0)