From cf247d44beffe32bd29a22a7f28a0b9ecde15024 Mon Sep 17 00:00:00 2001 From: MM20 <15646950+MM2-0@users.noreply.github.com> Date: Mon, 15 May 2023 13:45:25 +0200 Subject: [PATCH] Update docs --- .../media/MediaIntegrationSettingsScreen.kt | 1 + .../WeatherIntegrationSettingsScreen.kt | 2 +- docs/docs/user-guide/faq.md | 2 +- .../user-guide/integrations/_category_.yml | 4 +++ .../user-guide/integrations/mediacontrol.md | 25 +++++++++++++++++++ docs/docs/user-guide/integrations/weather.md | 23 +++++++++++++++++ docs/docs/user-guide/widgets/clock.md | 2 +- docs/docs/user-guide/widgets/music-widget.md | 21 +++++----------- .../docs/user-guide/widgets/weather-widget.md | 19 -------------- .../user-guide/widgets/weather-widget.mdx | 14 +++++++++++ 10 files changed, 76 insertions(+), 37 deletions(-) create mode 100644 docs/docs/user-guide/integrations/_category_.yml create mode 100644 docs/docs/user-guide/integrations/mediacontrol.md create mode 100644 docs/docs/user-guide/integrations/weather.md delete mode 100644 docs/docs/user-guide/widgets/weather-widget.md create mode 100644 docs/docs/user-guide/widgets/weather-widget.mdx diff --git a/app/ui/src/main/java/de/mm20/launcher2/ui/settings/media/MediaIntegrationSettingsScreen.kt b/app/ui/src/main/java/de/mm20/launcher2/ui/settings/media/MediaIntegrationSettingsScreen.kt index 38146981..b624fefa 100644 --- a/app/ui/src/main/java/de/mm20/launcher2/ui/settings/media/MediaIntegrationSettingsScreen.kt +++ b/app/ui/src/main/java/de/mm20/launcher2/ui/settings/media/MediaIntegrationSettingsScreen.kt @@ -47,6 +47,7 @@ fun MediaIntegrationSettingsScreen() { PreferenceScreen( stringResource(R.string.preference_media_integration), + helpUrl = "https://kvaesitso.mm20.de/docs/user-guide/integrations/mediacontrol" ) { if (loading) { item { diff --git a/app/ui/src/main/java/de/mm20/launcher2/ui/settings/weather/WeatherIntegrationSettingsScreen.kt b/app/ui/src/main/java/de/mm20/launcher2/ui/settings/weather/WeatherIntegrationSettingsScreen.kt index 2292f9cd..72f72ade 100644 --- a/app/ui/src/main/java/de/mm20/launcher2/ui/settings/weather/WeatherIntegrationSettingsScreen.kt +++ b/app/ui/src/main/java/de/mm20/launcher2/ui/settings/weather/WeatherIntegrationSettingsScreen.kt @@ -24,7 +24,7 @@ fun WeatherIntegrationSettingsScreen() { PreferenceScreen( title = stringResource(R.string.preference_screen_weatherwidget), - helpUrl = "https://kvaesitso.mm20.de/docs/user-guide/widgets/weather-widget" + helpUrl = "https://kvaesitso.mm20.de/docs/user-guide/integrations/weather" ) { item { PreferenceCategory { diff --git a/docs/docs/user-guide/faq.md b/docs/docs/user-guide/faq.md index dbaec075..250c8751 100644 --- a/docs/docs/user-guide/faq.md +++ b/docs/docs/user-guide/faq.md @@ -16,7 +16,7 @@ the favorites widget to the home screen. ## Can I remove / customize the clock? -Yes, you can customize the clock style by going to Settings > Widgets > Clock and selecting a different +Yes, you can customize the clock style by going to Settings > Home screen > Clock and selecting a different style. There is also an "empty style" that will remove the clock entirely. ## The toggle to grant notification access is disabled diff --git a/docs/docs/user-guide/integrations/_category_.yml b/docs/docs/user-guide/integrations/_category_.yml new file mode 100644 index 00000000..2414bb21 --- /dev/null +++ b/docs/docs/user-guide/integrations/_category_.yml @@ -0,0 +1,4 @@ +label: Integrations +link: + type: generated-index + title: Integrations \ No newline at end of file diff --git a/docs/docs/user-guide/integrations/mediacontrol.md b/docs/docs/user-guide/integrations/mediacontrol.md new file mode 100644 index 00000000..73fb9504 --- /dev/null +++ b/docs/docs/user-guide/integrations/mediacontrol.md @@ -0,0 +1,25 @@ +# Media Control + +This integration handles media sessions and exposes them to other launcher components. It is used by +the [music widget](/docs/user-guide/widgets/music-widget) and by +the [media control part](/docs/user-guide/widgets/clock#dynamic-components) of the clock widget. + +## My media playback doesn't show up! + +Per default, only media sessions from "music apps" are recognized by the media control integration. +You can select which apps should be included in Settings > Integrations > Media control. + +## I can't grant notification access permission! + +Please refer +to [notification access on Android 13+](/docs/user-guide/troubleshooting/restricted-settings#notification-access). + +## Why do I need to grant access to my notifications to control media? + +That's a very good question. I don't know. Ask Google, why they make +so [nonsensical decisions](https://www.reddit.com/r/mAndroidDev/comments/gn6ckb/man_im_so_happy_no_malicious_app_can_get_access/). +The only way for third party apps to control media sessions is to read notifications and extract the +media sessions from there. Sadly, the more privacy-friendly alternative is restricted to system apps +only, ["due to privacy of media consumption"](https://developer.android.com/reference/android/Manifest.permission#MEDIA_CONTENT_CONTROL). +Yep, that makes sense. Thank you, Google. + diff --git a/docs/docs/user-guide/integrations/weather.md b/docs/docs/user-guide/integrations/weather.md new file mode 100644 index 00000000..c5a05161 --- /dev/null +++ b/docs/docs/user-guide/integrations/weather.md @@ -0,0 +1,23 @@ +# Weather + +The weather integration provides the weather data that is used by +the [weather widget](/docs/user-guide/widgets/weather-widget). It can be configured at Settings > +Integrations > Weather. + +## Providers + +The service that provides the weather data. Weather data might differ in quality depending on your +location so pick whatever is working best for you. + +## Location + +You can either use your current location automatically (you need to grant location permission for +this) or set a fixed location manually. + +### Cannot find any locations! + +Some weather providers rely on the Android Geocoding API to convert location names to coordinates +and vice verca. This API is usually backed by the Google Play Services and Google Maps. It might not +be available if you use a degoogled Android distribution. In this case, you can try one of the +providers that ship their own geocoders (OpenWeatherMap or HERE), or you can specify the coordinates +manually using the following format: ` `. For example: `-90 0 South pole` diff --git a/docs/docs/user-guide/widgets/clock.md b/docs/docs/user-guide/widgets/clock.md index f031c019..1413728d 100644 --- a/docs/docs/user-guide/widgets/clock.md +++ b/docs/docs/user-guide/widgets/clock.md @@ -1,6 +1,6 @@ # Clock Widget -The clock widget is always the top-most widget in the widget list. It can be customized in several ways at Settings > Widgets > Clock. +The clock widget is always the top-most widget in the widget list. It can be customized in several ways at Settings > Home screen > Clock. ## Layout diff --git a/docs/docs/user-guide/widgets/music-widget.md b/docs/docs/user-guide/widgets/music-widget.md index c08d68b0..d674913c 100644 --- a/docs/docs/user-guide/widgets/music-widget.md +++ b/docs/docs/user-guide/widgets/music-widget.md @@ -1,18 +1,9 @@ # Music Widget -The music widget is one of the launcher's built-in widgets. It can be used to control media sessions on the device. The general usage is pretty self-explanatory: control the playback with the skip previous, skip next and toggle pause buttons. Tap on the album cover to open the current media player app. Long-press the album cover to open a player chooser. - -However there are a few things you might want to know: - -## My media playback doesn't show up! - -Per default, only media sessions from "music apps" are shown in the music widget. An app qualifies as "music app" if it has an activity that has either the `android.intent.action.MUSIC_PLAYER` action or the `android.intent.action.MAIN` action and the `android.intent.category.APP_MUSIC` category. Some media apps don't declare these in their manifests so the launcher won't recognize them as music apps. You can disable this filter in Settings > Widgets > Music > Restrict to music apps. With this setting disabled, the music widget will show media sessions from all apps, including non-music apps like browsers, video player apps and video streaming apps. - -## I can't grant notification access permission! - -Please refer to [notification access on Android 13+](/docs/user-guide/troubleshooting/restricted-settings#notification-access). - -## Why do I need to grant access to my notifications just to control some stupid media session? - -That's a very good question. I don't know. Ask Google, why they make so [nonsensical decisions](https://www.reddit.com/r/mAndroidDev/comments/gn6ckb/man_im_so_happy_no_malicious_app_can_get_access/). The only way for third party apps to control media sessions is to read notifications and extract the media sessions from there. Sadly, the more privacy-friendly alternative is restricted to system apps only, ["due to privacy of media consumption"](https://developer.android.com/reference/android/Manifest.permission#MEDIA_CONTENT_CONTROL). Yep, that makes sense. Thank you, Google. +The music widget is one of the launcher's built-in widgets. It can be used to control media sessions +on the device. The general usage is pretty self-explanatory: control the playback with the skip +previous, skip next and toggle pause buttons. Tap on the album cover to open the current media +player app. Long-press the album cover to open a player chooser. +It is backed by the [media control integration](/docs/user-guide/integrations/mediacontrol) which +can be configured at Settings > Integrations > Media control. \ No newline at end of file diff --git a/docs/docs/user-guide/widgets/weather-widget.md b/docs/docs/user-guide/widgets/weather-widget.md deleted file mode 100644 index bdcf6ee5..00000000 --- a/docs/docs/user-guide/widgets/weather-widget.md +++ /dev/null @@ -1,19 +0,0 @@ -# Weather Widget - -A widget that displays current and future weather data. - -## Configuration - -The weather widget can be configured at Settings > Widgets > Weather - -### Providers - -The service that provides the weather data. Weather data might differ in quality depending on your location so pick whataver is working best for you. - -### Location - -You can either use your current location automatically (you need to grant location permission for this) or set a fixed location manually. - -#### Cannot find any locations! - -Some weather providers rely on the Android Geocoding API to convert location names to coordinates and vice verca. This API is usually backed by the Google Play Services and Google Maps. It might not be available if you use a degoogled Android distribution. In this case, you can try one of the providers that ship their own geocoders (OpenWeatherMap or HERE), or you can specify the coordinates manually using the following format: ` `. For example: `-90 0 South pole` diff --git a/docs/docs/user-guide/widgets/weather-widget.mdx b/docs/docs/user-guide/widgets/weather-widget.mdx new file mode 100644 index 00000000..315691d6 --- /dev/null +++ b/docs/docs/user-guide/widgets/weather-widget.mdx @@ -0,0 +1,14 @@ +import TuneRoundedIcon from '@mui/icons-material/TuneRounded' + +# Weather Widget + +A widget that displays current and future weather data. + +## Configuration + +The weather widget can be configured by tapping "Edit widgets" and then selecting the icon +on the weather widget. + +- **Compact mode**: If enabled, the widget will only display the current weather data. Forecast data will be hidden. +- **Weather integration settings**: A shortcut to [Settings > Integrations > Weather](/docs/user-guide/integrations/weather). This is where you can configure + which weather provider to use and which location to get weather data for. \ No newline at end of file