mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2026-07-31 07:44:24 +02:00
Improve internethelper preferences layout
This commit is contained in:
committed by
Arjan Schrijver
parent
11e18c0a63
commit
3528ab725c
+1
@@ -56,6 +56,7 @@ class InternetHelperPreferencesActivity : AbstractGBActivity() {
|
||||
retrieveList()
|
||||
|
||||
val recyclerView = findViewById<RecyclerView>(R.id.internet_helper_url_list)
|
||||
recyclerView.isNestedScrollingEnabled = false
|
||||
recyclerView.layoutManager = LinearLayoutManager(this)
|
||||
recyclerView.adapter = UrlListAdapter(urlItems) { entry, action ->
|
||||
when (action) {
|
||||
|
||||
@@ -1,20 +1,28 @@
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/root_layout"
|
||||
<androidx.core.widget.NestedScrollView
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/root_scroll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
android:fillViewport="true">
|
||||
|
||||
<!-- Preference screen -->
|
||||
<FrameLayout
|
||||
android:id="@+id/settings_container"
|
||||
<LinearLayout
|
||||
android:id="@+id/root_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- Dynamic URL List -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/internet_helper_url_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:paddingTop="8dp"/>
|
||||
</LinearLayout>
|
||||
<!-- Preference screen -->
|
||||
<FrameLayout
|
||||
android:id="@+id/settings_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<!-- Dynamic URL List -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/internet_helper_url_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:paddingTop="8dp"/>
|
||||
</LinearLayout>
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
@@ -2,10 +2,6 @@
|
||||
<PreferenceScreen
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<Preference
|
||||
android:key="pref_key_internethelper_info"
|
||||
android:summary="Use the list below to configure which (parts of) URLs are allowed or denied to be forwarded to the internethelper add-on app. The validation is using a simple text comparison, so a part of a URL can be entered too."
|
||||
app:iconSpaceReserved="false" />
|
||||
<PreferenceCategory
|
||||
android:title="@string/pref_header_general"
|
||||
app:iconSpaceReserved="false">
|
||||
@@ -29,5 +25,9 @@
|
||||
android:key="pref_key_internethelper_url_list"
|
||||
android:title="Known URLs"
|
||||
app:iconSpaceReserved="false">
|
||||
<Preference
|
||||
android:key="pref_key_internethelper_info"
|
||||
android:summary="Use the list below to configure which (parts of) URLs are allowed or denied to be forwarded to the internethelper add-on app. The validation is using a simple text comparison, so a part of a URL can be entered too."
|
||||
app:iconSpaceReserved="false" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
||||
Reference in New Issue
Block a user