diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index d14b126..0000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,38 +0,0 @@ ---- -name: Bug report -about: Create a report to help improve this app -title: '[bug] ' -labels: bug -assignees: '' - ---- - -# Describe the bug - - - -# To Reproduce - - - -# Expected behavior - - - -# Screenshots - - -# Smartphone (please complete the following information) - - Device: - - Android Version: - - µLauncher Version: - -# Additional info - - diff --git a/.github/ISSUE_TEMPLATE/bug_report.yaml b/.github/ISSUE_TEMPLATE/bug_report.yaml new file mode 100644 index 0000000..fa112ae --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yaml @@ -0,0 +1,50 @@ +name: Bug report +description: Create a report to help improve this app +title: '[bug] ' +labels: bug +body: + - type: markdown + attributes: + value: | + Thank you for helping to improve µLauncher! + - type: textarea + id: bug + attributes: + label: Describe the Bug + description: What happened? + placeholder: A clear and concise description of what the bug is. + render: markdown + validations: + required: true + - type: textarea + id: expected + attributes: + label: Expected Behavior + description: What did you expect to happen instead? + render: markdown + validations: + required: false + - type: textarea + id: reproduce + attributes: + label: To Reproduce + description: What steps are required to reproduce the bug? + render: markdown + placeholder: | + Steps to reproduce the behavior: + 1. Go to '...' + 2. Click on '....' + 3. Scroll down to '....' + 4. See error + validations: + required: false + - type: textarea + id: device + attributes: + label: Your Device + description: | + What device are you using? Adding this information helps to reproduce the bug. + You can copy this from µLauncher > Settings > Meta > Report Bug. + render: markdown + validations: + required: false diff --git a/app/build.gradle b/app/build.gradle index 9bc7295..23273af 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -23,8 +23,8 @@ android { minSdkVersion 21 targetSdkVersion 35 compileSdk 35 - versionCode 36 - versionName "j-0.0.20" + versionCode 37 + versionName "0.0.21" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } diff --git a/app/src/main/java/de/jrpie/android/launcher/Functions.kt b/app/src/main/java/de/jrpie/android/launcher/Functions.kt index ebfc070..721caa2 100644 --- a/app/src/main/java/de/jrpie/android/launcher/Functions.kt +++ b/app/src/main/java/de/jrpie/android/launcher/Functions.kt @@ -3,6 +3,7 @@ package de.jrpie.android.launcher import android.app.Activity import android.app.Service import android.app.role.RoleManager +import android.content.ActivityNotFoundException import android.content.ClipData import android.content.ClipboardManager import android.content.Context @@ -16,6 +17,7 @@ import android.os.UserHandle import android.os.UserManager import android.provider.Settings import android.util.Log +import android.widget.Toast import de.jrpie.android.launcher.actions.Action import de.jrpie.android.launcher.actions.Gesture import de.jrpie.android.launcher.apps.AppInfo @@ -83,14 +85,18 @@ fun getPrivateSpaceUser(context: Context): UserHandle? { val userManager = context.getSystemService(Context.USER_SERVICE) as UserManager val launcherApps = context.getSystemService(Context.LAUNCHER_APPS_SERVICE) as LauncherApps return userManager.userProfiles.firstOrNull { u -> - launcherApps.getLauncherUserInfo(u)?.userType == UserManager.USER_TYPE_PROFILE_PRIVATE + launcherApps.getLauncherUserInfo(u)?.userType == UserManager.USER_TYPE_PROFILE_PRIVATE } } fun openInBrowser(url: String, context: Context) { val intent = Intent(Intent.ACTION_VIEW, Uri.parse(url)) intent.putExtras(Bundle().apply { putBoolean("new_window", true) }) - context.startActivity(intent) + try { + context.startActivity(intent) + } catch (_: ActivityNotFoundException) { + Toast.makeText(context, R.string.toast_activity_not_found_browser, Toast.LENGTH_LONG).show() + } } fun openTutorial(context: Context) { diff --git a/app/src/main/java/de/jrpie/android/launcher/actions/AppAction.kt b/app/src/main/java/de/jrpie/android/launcher/actions/AppAction.kt index 2bb3780..4b71a90 100644 --- a/app/src/main/java/de/jrpie/android/launcher/actions/AppAction.kt +++ b/app/src/main/java/de/jrpie/android/launcher/actions/AppAction.kt @@ -2,6 +2,7 @@ package de.jrpie.android.launcher.actions import android.app.AlertDialog import android.app.Service +import android.content.ActivityNotFoundException import android.content.Context import android.content.Intent import android.content.pm.LauncherApps @@ -34,7 +35,11 @@ class AppAction(val app: AppInfo) : Action { context.packageManager.getLaunchIntentForPackage(packageName)?.let { it.addCategory(Intent.CATEGORY_LAUNCHER) - context.startActivity(it) + try { + context.startActivity(it) + } catch (_: ActivityNotFoundException) { + return false + } return true } diff --git a/app/src/main/java/de/jrpie/android/launcher/ui/list/apps/ListFragmentApps.kt b/app/src/main/java/de/jrpie/android/launcher/ui/list/apps/ListFragmentApps.kt index 55f07a5..c52f951 100644 --- a/app/src/main/java/de/jrpie/android/launcher/ui/list/apps/ListFragmentApps.kt +++ b/app/src/main/java/de/jrpie/android/launcher/ui/list/apps/ListFragmentApps.kt @@ -1,11 +1,13 @@ package de.jrpie.android.launcher.ui.list.apps +import android.content.ActivityNotFoundException import android.content.Intent import android.content.SharedPreferences import android.os.Bundle import android.view.LayoutInflater import android.view.View import android.view.ViewGroup +import android.widget.Toast import androidx.fragment.app.Fragment import de.jrpie.android.launcher.R import de.jrpie.android.launcher.apps.AppFilter @@ -91,7 +93,16 @@ class ListFragmentApps : Fragment(), UIObject { if (LauncherPreferences.functionality().searchWeb()) { val i = Intent(Intent.ACTION_WEB_SEARCH).putExtra("query", query) - activity?.startActivity(i) + try { + activity?.startActivity(i) + } catch (_: ActivityNotFoundException) { + Toast.makeText( + requireContext(), + R.string.toast_activity_not_found_search_web, + Toast.LENGTH_LONG + ).show() + } + } else { appsRecyclerAdapter.selectItem(0) } diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index e815940..e7c7546 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -76,10 +76,12 @@ - --> Aussehen + Farbe Zeit anzeigen Datum anzeigen Lokalisiertes Datumsformat verwenden Datum und Uhrzeit tauschen + Dynamisch Textschatten Hintergrund (Alle Apps und Einstellungen) Einfarbig @@ -103,6 +105,7 @@ Kantenaktionen Kantenbreite Suchergebnis starten + Beim Durchsuchen der Apps Enter drücken um stattdessen im Internet zu suchen Tastatur automatisch öffnen Empfindlichkeit