<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen
    xmlns:app="http://schemas.android.com/apk/res-auto">
    <PreferenceCategory
        app:title="@string/preference_category_search_favorites">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_show_favorites"
            app:summary="@string/preference_search_show_favorites_summary"
            app:title="@string/preference_search_show_favorites"/>

        <!--<SwitchPreference
            app:defaultValue="true"
            app:dependency="search_show_favorites"
            app:key="search_auto_add_favorites"
            app:summary="@string/preference_search_auto_add_favorites_summary"
            app:title="@string/preference_search_auto_add_favorites"/> -->
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_calculator">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_calculator"
            app:summary="@string/preference_search_calculator_summary"
            app:title="@string/preference_search_calculator"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_unitconverter">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_unitconverter"
            app:summary="@string/preference_search_unitconverter_summary"
            app:title="@string/preference_search_unitconverter"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_files">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_files"
            app:summary="@string/preference_search_files_summary"
            app:title="@string/preference_search_files"/>
        <SwitchPreference
            app:defaultValue="false"
            app:key="search_gdrive"
            app:summary="@string/preference_summary_not_logged_in"
            app:title="@string/preference_search_gdrive"/>
        <SwitchPreference
            app:defaultValue="false"
            app:key="search_onedrive"
            app:summary="@string/preference_account_checking_status"
            app:title="@string/preference_search_onedrive"/>
        <SwitchPreference
            app:defaultValue="false"
            app:key="search_nextcloud"
            app:summary="@string/preference_account_checking_status"
            app:title="@string/preference_search_nextcloud"/>
        <SwitchPreference
            app:defaultValue="false"
            app:key="search_owncloud"
            app:summary="@string/preference_account_checking_status"
            app:title="@string/preference_search_owncloud"/>
        <SwitchPreference
            app:defaultValue="true"
            app:dependency="search_gdrive"
            app:key="search_gdrive_mobile_data"
            app:summary="@string/preference_search_mobile_data_summary"
            app:title="@string/preference_search_mobile_data"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_calendar">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_calendars"
            app:title="@string/preference_search_calendar"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_contacts">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_contacts"
            app:title="@string/preference_search_contacts"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_wikipedia">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_wikipedia"
            app:title="@string/preference_search_wikipedia"/>
        <SwitchPreference
            app:defaultValue="true"
            app:dependency="search_wikipedia"
            app:key="search_wikipedia_mobile_data"
            app:summary="@string/preference_search_mobile_data_summary"
            app:title="@string/preference_search_mobile_data"/>
        <SwitchPreference
            app:defaultValue="false"
            app:dependency="search_wikipedia"
            app:key="search_wikipedia_pictures"
            app:summary="@string/preference_search_wikipedia_pictures_summary"
            app:title="@string/preference_search_wikipedia_pictures"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_websites">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_websites"
            app:summary="@string/preference_search_websites_summary"
            app:title="@string/preference_search_websites"/>
        <ListPreference
            app:defaultValue="1"
            app:dependency="search_websites"
            app:entries="@array/preference_search_websites_protocol_entries"
            app:entryValues="@array/preference_search_websites_protocol_values"
            app:key="search_websites_protocol"
            app:summary="@string/preference_search_websites_protocol_summary"
            app:title="@string/preference_search_websites_protocol"/>
        <SwitchPreference
            app:defaultValue="true"
            app:dependency="search_websites"
            app:key="search_websearch_mobile_data"
            app:summary="@string/preference_search_mobile_data_summary"
            app:title="@string/preference_search_mobile_data"/>
    </PreferenceCategory>

    <PreferenceCategory
        app:title="@string/preference_category_search_websearch">
        <SwitchPreference
            app:defaultValue="true"
            app:key="search_websearch"
            app:summary="@string/preference_search_websearch_summary"
            app:title="@string/preference_search_websearch"/>
        <Preference
            app:dependency="search_websearch"
            app:key="search_edit_websearch"
            app:title="@string/preference_search_edit_websearch"/>
    </PreferenceCategory>

</androidx.preference.PreferenceScreen>