<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto">

    <PreferenceCategory app:title="@string/advanced">

        <ListPreference
            android:defaultValue="disabled"
            android:entries="@array/dataSaverModeOptions"
            android:entryValues="@array/dataSaverModeValues"
            android:icon="@drawable/ic_data_saver"
            android:summary="@string/data_saver_mode_summary"
            app:key="data_saver_mode_key"
            app:title="@string/data_saver_mode" />

        <com.github.libretube.ui.views.SliderPreference
            android:icon="@drawable/ic_download"
            android:key="max_concurrent_downloads"
            android:title="@string/concurrent_downloads"
            app:defValue="6"
            app:stepSize="1"
            app:valueFrom="1"
            app:valueTo="20" />

        <ListPreference
            android:entries="@array/cacheSize"
            android:entryValues="@array/cacheSizeValues"
            android:icon="@drawable/ic_cache"
            app:defaultValue="128"
            app:key="image_cache_size"
            app:title="@string/maximum_image_cache"
            app:useSimpleSummaryProvider="true" />

        <SwitchPreferenceCompat
            android:icon="@drawable/ic_badge"
            android:summary="@string/new_videos_badge_summary"
            app:key="new_videos_badge"
            app:title="@string/new_videos_badge" />

        <SwitchPreferenceCompat
            android:icon="@drawable/ic_loading"
            android:summary="@string/save_feed_summary"
            app:key="save_feed"
            app:title="@string/save_feed" />

        <SwitchPreferenceCompat
            android:icon="@drawable/ic_check"
            android:summary="@string/confirm_unsubscribing_summary"
            app:key="confirm_unsubscribing"
            app:title="@string/confirm_unsubscribing" />

        <SwitchPreferenceCompat
            android:icon="@drawable/ic_invisible"
            android:summary="@string/hide_watched_from_feed_summary"
            android:title="@string/hide_watched_from_feed"
            app:key="hide_watched_from_feed" />

    </PreferenceCategory>

    <PreferenceCategory app:title="@string/misc">

        <Preference
            android:icon="@drawable/ic_reset"
            app:key="reset_settings"
            app:title="@string/reset" />

    </PreferenceCategory>

</PreferenceScreen>