Skip to content
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

Restore AppCompat themes for some material components #4811

Merged
merged 1 commit into from
Sep 13, 2024

Conversation

Goooler
Copy link
Collaborator

@Goooler Goooler commented Sep 13, 2024

Description

We still rely on them for using material views.

Type of change

❌ General change (non-breaking change that doesn't fit the below categories like copyediting)
✅ Bug fix (non-breaking change which fixes an issue)
❌ New feature (non-breaking change which adds functionality)
❌ Breaking change (fix or feature that would cause existing functionality to not work as expected)

We still rely on them for using material views.

```
java.lang.IllegalArgumentException: The style on this component requires your app theme to be Theme.AppCompat (or a descendant).
	at com.google.android.material.internal.ThemeEnforcement.checkTheme(ThemeEnforcement.java:247)
	at com.google.android.material.internal.ThemeEnforcement.checkAppCompatTheme(ThemeEnforcement.java:212)
	at com.google.android.material.internal.ThemeEnforcement.checkCompatibleTheme(ThemeEnforcement.java:147)
	at com.google.android.material.internal.ThemeEnforcement.obtainStyledAttributes(ThemeEnforcement.java:76)
	at com.google.android.material.progressindicator.BaseProgressIndicatorSpec.<init>(BaseProgressIndicatorSpec.java:92)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:76)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:68)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:63)
	at com.google.android.material.progressindicator.CircularProgressIndicator.createSpec(CircularProgressIndicator.java:87)
	at com.google.android.material.progressindicator.CircularProgressIndicator.createSpec(CircularProgressIndicator.java:58)
	at com.google.android.material.progressindicator.BaseProgressIndicator.<init>(BaseProgressIndicator.java:144)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:78)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:73)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:69)
	at app.lawnchair.views.LauncherPreviewView.<init>(LauncherPreviewView.kt:46)
	at app.lawnchair.backup.ui.CreateBackupViewModel.captureScreenshot(CreateBackupViewModel.kt:58)
	at app.lawnchair.backup.ui.CreateBackupViewModel.access$captureScreenshot(CreateBackupViewModel.kt:24)
	at app.lawnchair.backup.ui.CreateBackupViewModel$1.invokeSuspend(CreateBackupViewModel.kt:38)
```
@Goooler Goooler merged commit dcc0470 into 14-dev Sep 13, 2024
2 checks passed
@Goooler Goooler deleted the g/restore-app-compat-themes branch September 13, 2024 00:17
nulldrf pushed a commit to nulldrf/lawnchair that referenced this pull request Sep 19, 2024
…her#4811)

We still rely on them for using material views.

```
java.lang.IllegalArgumentException: The style on this component requires your app theme to be Theme.AppCompat (or a descendant).
	at com.google.android.material.internal.ThemeEnforcement.checkTheme(ThemeEnforcement.java:247)
	at com.google.android.material.internal.ThemeEnforcement.checkAppCompatTheme(ThemeEnforcement.java:212)
	at com.google.android.material.internal.ThemeEnforcement.checkCompatibleTheme(ThemeEnforcement.java:147)
	at com.google.android.material.internal.ThemeEnforcement.obtainStyledAttributes(ThemeEnforcement.java:76)
	at com.google.android.material.progressindicator.BaseProgressIndicatorSpec.<init>(BaseProgressIndicatorSpec.java:92)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:76)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:68)
	at com.google.android.material.progressindicator.CircularProgressIndicatorSpec.<init>(CircularProgressIndicatorSpec.java:63)
	at com.google.android.material.progressindicator.CircularProgressIndicator.createSpec(CircularProgressIndicator.java:87)
	at com.google.android.material.progressindicator.CircularProgressIndicator.createSpec(CircularProgressIndicator.java:58)
	at com.google.android.material.progressindicator.BaseProgressIndicator.<init>(BaseProgressIndicator.java:144)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:78)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:73)
	at com.google.android.material.progressindicator.CircularProgressIndicator.<init>(CircularProgressIndicator.java:69)
	at app.lawnchair.views.LauncherPreviewView.<init>(LauncherPreviewView.kt:46)
	at app.lawnchair.backup.ui.CreateBackupViewModel.captureScreenshot(CreateBackupViewModel.kt:58)
	at app.lawnchair.backup.ui.CreateBackupViewModel.access$captureScreenshot(CreateBackupViewModel.kt:24)
	at app.lawnchair.backup.ui.CreateBackupViewModel$1.invokeSuspend(CreateBackupViewModel.kt:38)
```
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.

[BUG] App crashes when selecting General -> Icons -> Icon style (current dev source)
1 participant