mirror of
https://github.com/YTVanced/VancedMicroG
synced 2024-11-28 14:13:00 +00:00
commit
dc55916fc4
41 changed files with 538 additions and 119 deletions
|
@ -49,7 +49,7 @@ allprojects {
|
|||
|
||||
group = 'org.microg.gms'
|
||||
version = "0.2.11.202414-vanced"
|
||||
ext.appVersionCode = 194301000
|
||||
ext.appVersionCode = 21124414
|
||||
ext.isReleaseVersion = false
|
||||
}
|
||||
|
||||
|
|
|
@ -15,6 +15,8 @@
|
|||
*/
|
||||
|
||||
apply plugin: 'com.android.application'
|
||||
apply plugin: 'kotlin-android'
|
||||
apply plugin: 'kotlin-android-extensions'
|
||||
|
||||
dependencies {
|
||||
implementation "com.squareup.wire:wire-runtime:1.6.1"
|
||||
|
@ -40,8 +42,14 @@ dependencies {
|
|||
implementation "androidx.appcompat:appcompat:$appcompatVersion"
|
||||
implementation "androidx.mediarouter:mediarouter:$mediarouterVersion"
|
||||
implementation "androidx.preference:preference:$preferenceVersion"
|
||||
|
||||
implementation "androidx.navigation:navigation-fragment:$navigationVersion"
|
||||
implementation "androidx.navigation:navigation-ui:$navigationVersion"
|
||||
implementation "androidx.navigation:navigation-fragment-ktx:$navigationVersion"
|
||||
implementation "androidx.navigation:navigation-ui-ktx:$navigationVersion"
|
||||
|
||||
implementation "androidx.lifecycle:lifecycle-service:$lifecycleVersion"
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
|
||||
}
|
||||
|
||||
android {
|
||||
|
@ -55,8 +63,6 @@ android {
|
|||
minSdkVersion androidMinSdk
|
||||
targetSdkVersion androidTargetSdk
|
||||
|
||||
multiDexEnabled true
|
||||
|
||||
ndk {
|
||||
abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64"
|
||||
}
|
||||
|
@ -70,6 +76,7 @@ android {
|
|||
sourceSets {
|
||||
main {
|
||||
java.srcDirs += 'src/main/protos-java'
|
||||
java.srcDirs += 'src/main/kotlin'
|
||||
}
|
||||
}
|
||||
|
||||
|
|
2
play-services-core/src/main/kotlin/org/microg/gms/provision/ProvisionService.kt
Normal file → Executable file
2
play-services-core/src/main/kotlin/org/microg/gms/provision/ProvisionService.kt
Normal file → Executable file
|
@ -14,7 +14,6 @@ import androidx.lifecycle.lifecycleScope
|
|||
import kotlinx.coroutines.delay
|
||||
import org.microg.gms.checkin.CheckinPrefs
|
||||
import org.microg.gms.gcm.GcmPrefs
|
||||
import org.microg.gms.snet.SafetyNetPrefs
|
||||
|
||||
class ProvisionService : LifecycleService() {
|
||||
private fun Bundle.getBooleanOrNull(key: String): Boolean? {
|
||||
|
@ -31,7 +30,6 @@ class ProvisionService : LifecycleService() {
|
|||
|
||||
intent?.extras?.getBooleanOrNull("checkin_enabled")?.let { CheckinPrefs.setEnabled(this@ProvisionService, it) }
|
||||
intent?.extras?.getBooleanOrNull("gcm_enabled")?.let { GcmPrefs.setEnabled(this@ProvisionService, it) }
|
||||
intent?.extras?.getBooleanOrNull("safetynet_enabled")?.let { SafetyNetPrefs.get(this@ProvisionService).isEnabled = it }
|
||||
// What else?
|
||||
|
||||
delay(2 * 1000) // Wait 2 seconds to give provisioning some extra time
|
||||
|
|
0
play-services-core/src/main/kotlin/org/microg/gms/ui/AppIconPreference.kt
Normal file → Executable file
0
play-services-core/src/main/kotlin/org/microg/gms/ui/AppIconPreference.kt
Normal file → Executable file
4
play-services-core/src/main/kotlin/org/microg/gms/ui/DeviceRegistrationFragment.kt
Normal file → Executable file
4
play-services-core/src/main/kotlin/org/microg/gms/ui/DeviceRegistrationFragment.kt
Normal file → Executable file
|
@ -11,8 +11,8 @@ import android.view.View
|
|||
import android.view.ViewGroup
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import com.google.android.gms.R
|
||||
import com.google.android.gms.databinding.DeviceRegistrationFragmentBinding
|
||||
import com.mgoogle.android.gms.R
|
||||
import com.mgoogle.android.gms.databinding.DeviceRegistrationFragmentBinding
|
||||
import org.microg.gms.checkin.CheckinPrefs
|
||||
|
||||
class DeviceRegistrationFragment : Fragment(R.layout.device_registration_fragment) {
|
||||
|
|
2
play-services-core/src/main/kotlin/org/microg/gms/ui/DeviceRegistrationPreferencesFragment.kt
Normal file → Executable file
2
play-services-core/src/main/kotlin/org/microg/gms/ui/DeviceRegistrationPreferencesFragment.kt
Normal file → Executable file
|
@ -11,7 +11,7 @@ import android.text.format.DateUtils
|
|||
import androidx.preference.Preference
|
||||
import androidx.preference.PreferenceCategory
|
||||
import androidx.preference.PreferenceFragmentCompat
|
||||
import com.google.android.gms.R
|
||||
import com.mgoogle.android.gms.R
|
||||
import org.microg.gms.checkin.CheckinPrefs
|
||||
import org.microg.gms.checkin.LastCheckinInfo
|
||||
|
||||
|
|
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAllAppsFragment.kt
Normal file → Executable file
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAllAppsFragment.kt
Normal file → Executable file
|
@ -14,7 +14,7 @@ import androidx.navigation.fragment.findNavController
|
|||
import androidx.preference.Preference
|
||||
import androidx.preference.PreferenceCategory
|
||||
import androidx.preference.PreferenceFragmentCompat
|
||||
import com.google.android.gms.R
|
||||
import com.mgoogle.android.gms.R
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.withContext
|
||||
import org.microg.gms.gcm.GcmDatabase
|
||||
|
|
4
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAppFragment.kt
Normal file → Executable file
4
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAppFragment.kt
Normal file → Executable file
|
@ -17,8 +17,8 @@ import androidx.appcompat.content.res.AppCompatResources
|
|||
import androidx.fragment.app.Fragment
|
||||
import androidx.fragment.app.findFragment
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import com.google.android.gms.R
|
||||
import com.google.android.gms.databinding.PushNotificationAppFragmentBinding
|
||||
import com.mgoogle.android.gms.R
|
||||
import com.mgoogle.android.gms.databinding.PushNotificationAppFragmentBinding
|
||||
|
||||
|
||||
class PushNotificationAppFragment : Fragment(R.layout.push_notification_fragment) {
|
||||
|
|
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAppPreferencesFragment.kt
Normal file → Executable file
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationAppPreferencesFragment.kt
Normal file → Executable file
|
@ -13,7 +13,7 @@ import androidx.preference.Preference
|
|||
import androidx.preference.PreferenceCategory
|
||||
import androidx.preference.PreferenceFragmentCompat
|
||||
import androidx.preference.TwoStatePreference
|
||||
import com.google.android.gms.R
|
||||
import com.mgoogle.android.gms.R
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.withContext
|
||||
import org.microg.gms.gcm.GcmDatabase
|
||||
|
|
4
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationFragment.kt
Normal file → Executable file
4
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationFragment.kt
Normal file → Executable file
|
@ -9,8 +9,8 @@ import android.view.*
|
|||
import androidx.fragment.app.Fragment
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import androidx.navigation.fragment.findNavController
|
||||
import com.google.android.gms.R
|
||||
import com.google.android.gms.databinding.PushNotificationFragmentBinding
|
||||
import com.mgoogle.android.gms.R
|
||||
import com.mgoogle.android.gms.databinding.PushNotificationFragmentBinding
|
||||
import org.microg.gms.checkin.CheckinPrefs
|
||||
import org.microg.gms.gcm.GcmPrefs
|
||||
|
||||
|
|
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationPreferencesFragment.kt
Normal file → Executable file
2
play-services-core/src/main/kotlin/org/microg/gms/ui/PushNotificationPreferencesFragment.kt
Normal file → Executable file
|
@ -14,7 +14,7 @@ import androidx.navigation.fragment.findNavController
|
|||
import androidx.preference.Preference
|
||||
import androidx.preference.PreferenceCategory
|
||||
import androidx.preference.PreferenceFragmentCompat
|
||||
import com.google.android.gms.R
|
||||
import com.mgoogle.android.gms.R
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.withContext
|
||||
import org.microg.gms.gcm.GcmDatabase
|
||||
|
|
|
@ -1,61 +0,0 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
package org.microg.gms.ui
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.*
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.navigation.fragment.findNavController
|
||||
import com.google.android.gms.R
|
||||
import com.google.android.gms.databinding.SafetyNetFragmentBinding
|
||||
import org.microg.gms.checkin.CheckinPrefs
|
||||
import org.microg.gms.snet.SafetyNetPrefs
|
||||
|
||||
class SafetyNetFragment : Fragment(R.layout.safety_net_fragment) {
|
||||
|
||||
private lateinit var binding: SafetyNetFragmentBinding
|
||||
|
||||
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
|
||||
binding = SafetyNetFragmentBinding.inflate(inflater, container, false)
|
||||
binding.switchBarCallback = object : PreferenceSwitchBarCallback {
|
||||
override fun onChecked(newStatus: Boolean) {
|
||||
SafetyNetPrefs.get(requireContext()).isEnabled = newStatus
|
||||
binding.safetynetEnabled = newStatus
|
||||
}
|
||||
}
|
||||
return binding.root
|
||||
}
|
||||
|
||||
override fun onResume() {
|
||||
super.onResume()
|
||||
binding.checkinEnabled = CheckinPrefs.get(requireContext()).isEnabled
|
||||
binding.safetynetEnabled = SafetyNetPrefs.get(requireContext()).isEnabled
|
||||
}
|
||||
|
||||
override fun onActivityCreated(savedInstanceState: Bundle?) {
|
||||
super.onActivityCreated(savedInstanceState)
|
||||
setHasOptionsMenu(true)
|
||||
}
|
||||
|
||||
override fun onCreateOptionsMenu(menu: Menu, inflater: MenuInflater) {
|
||||
menu.add(0, MENU_ADVANCED, 0, R.string.menu_advanced)
|
||||
super.onCreateOptionsMenu(menu, inflater)
|
||||
}
|
||||
|
||||
override fun onOptionsItemSelected(item: MenuItem): Boolean {
|
||||
return when (item.itemId) {
|
||||
MENU_ADVANCED -> {
|
||||
findNavController().navigate(R.id.openSafetyNetAdvancedSettings)
|
||||
true
|
||||
}
|
||||
else -> super.onOptionsItemSelected(item)
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
private const val MENU_ADVANCED = Menu.FIRST
|
||||
}
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
package org.microg.gms.ui
|
||||
|
||||
import android.os.Bundle
|
||||
import androidx.preference.PreferenceFragmentCompat
|
||||
import com.google.android.gms.R
|
||||
|
||||
class SafetyNetPreferencesFragment : PreferenceFragmentCompat() {
|
||||
|
||||
override fun onCreatePreferences(savedInstanceState: Bundle?, rootKey: String?) {
|
||||
addPreferencesFromResource(R.xml.preferences_safetynet)
|
||||
}
|
||||
}
|
14
play-services-core/src/main/res/drawable/dots_horizontal.xml
Executable file
14
play-services-core/src/main/res/drawable/dots_horizontal.xml
Executable file
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
|
||||
<path
|
||||
android:fillColor="#000000"
|
||||
android:pathData="M16,12A2,2 0 0,1 18,10A2,2 0 0,1 20,12A2,2 0 0,1 18,14A2,2 0 0,1 16,12M10,12A2,2
|
||||
0 0,1 12,10A2,2 0 0,1 14,12A2,2 0 0,1 12,14A2,2 0 0,1 10,12M4,12A2,2 0 0,1
|
||||
6,10A2,2 0 0,1 8,12A2,2 0 0,1 6,14A2,2 0 0,1 4,12Z" />
|
||||
</vector>
|
19
play-services-core/src/main/res/drawable/ic_expand_apps.xml
Executable file
19
play-services-core/src/main/res/drawable/ic_expand_apps.xml
Executable file
|
@ -0,0 +1,19 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2019, The Android Open Source Project
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<vector
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:autoMirrored="true"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M9.71,18.71l-1.42,-1.42l5.3,-5.29l-5.3,-5.29l1.42,-1.42l6.7,6.71z" />
|
||||
</vector>
|
17
play-services-core/src/main/res/drawable/ic_info_outline.xml
Executable file
17
play-services-core/src/main/res/drawable/ic_info_outline.xml
Executable file
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2019, The Android Open Source Project
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M11,17h2v-6h-2v6zM12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM12,20c-4.41,0 -8,-3.59 -8,-8s3.59,-8 8,-8 8,3.59 8,8 -3.59,8 -8,8zM11,9h2L13,7h-2v2z" />
|
||||
</vector>
|
41
play-services-core/src/main/res/layout/device_registration_fragment.xml
Executable file
41
play-services-core/src/main/res/layout/device_registration_fragment.xml
Executable file
|
@ -0,0 +1,41 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="checkinEnabled"
|
||||
type="boolean" />
|
||||
|
||||
<variable
|
||||
name="switchBarCallback"
|
||||
type="org.microg.gms.ui.PreferenceSwitchBarCallback" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include
|
||||
layout="@layout/preference_switch_bar"
|
||||
app:callback="@{switchBarCallback}"
|
||||
app:checked="@{checkinEnabled}"
|
||||
app:description='@{"Register device"}'
|
||||
app:enabled="@{true}" />
|
||||
|
||||
<androidx.fragment.app.FragmentContainerView
|
||||
android:id="@+id/sub_preferences"
|
||||
android:name="org.microg.gms.ui.DeviceRegistrationPreferencesFragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
</LinearLayout>
|
||||
</layout>
|
9
play-services-core/src/main/res/layout/preference_category_no_label.xml
Executable file
9
play-services-core/src/main/res/layout/preference_category_no_label.xml
Executable file
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<View xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp" />
|
17
play-services-core/src/main/res/layout/preference_progress_bar.xml
Executable file
17
play-services-core/src/main/res/layout/preference_progress_bar.xml
Executable file
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ProgressBar
|
||||
style="@style/Widget.AppCompat.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true" />
|
||||
</LinearLayout>
|
73
play-services-core/src/main/res/layout/preference_switch_bar.xml
Executable file
73
play-services-core/src/main/res/layout/preference_switch_bar.xml
Executable file
|
@ -0,0 +1,73 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="checked"
|
||||
type="boolean" />
|
||||
|
||||
<variable
|
||||
name="enabled"
|
||||
type="boolean" />
|
||||
|
||||
<variable
|
||||
name="description"
|
||||
type="String" />
|
||||
|
||||
<variable
|
||||
name="callback"
|
||||
type="org.microg.gms.ui.PreferenceSwitchBarCallback" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:clickable="@{enabled}"
|
||||
android:focusable="@{enabled}"
|
||||
android:gravity="center"
|
||||
android:onClick="@{(v) -> callback.onChecked(!Boolean.valueOf(checked))}"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||
android:paddingLeft="?attr/listPreferredItemPaddingLeft"
|
||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd"
|
||||
android:paddingRight="?attr/listPreferredItemPaddingRight"
|
||||
android:background="@{checked ? android.R.attr.colorControlActivated : (enabled ? android.R.attr.colorButtonNormal : android.R.attr.colorControlHighlight)}"
|
||||
tools:background="?attr/colorControlActivated">
|
||||
|
||||
<TextView
|
||||
android:id="@android:id/title"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:maxLines="2"
|
||||
android:paddingStart="56dp"
|
||||
android:paddingLeft="56dp"
|
||||
android:text="@{description}"
|
||||
android:textAppearance="?attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorPrimaryInverse"
|
||||
tools:text="Enabled" />
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/switch_widget"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:background="@null"
|
||||
android:checked="@{checked}"
|
||||
android:enabled="@{enabled}"
|
||||
app:onCheckedChangeListener="@{(v, newStatus) -> callback.onChecked(newStatus)}"
|
||||
app:thumbTint="?android:attr/textColorPrimaryInverse"
|
||||
app:trackTint="?android:attr/textColorSecondaryInverse"
|
||||
tools:checked="true" />
|
||||
</LinearLayout>
|
||||
</layout>
|
82
play-services-core/src/main/res/layout/push_notification_app_fragment.xml
Executable file
82
play-services-core/src/main/res/layout/push_notification_app_fragment.xml
Executable file
|
@ -0,0 +1,82 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="appName"
|
||||
type="String" />
|
||||
|
||||
<variable
|
||||
name="appIcon"
|
||||
type="android.graphics.drawable.Drawable" />
|
||||
|
||||
<variable
|
||||
name="callbacks"
|
||||
type="org.microg.gms.ui.PushNotificationAppFragmentCallbacks" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/colorPrimary"
|
||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||
android:paddingLeft="?attr/listPreferredItemPaddingLeft"
|
||||
android:paddingTop="24dp"
|
||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd"
|
||||
android:paddingRight="?attr/listPreferredItemPaddingRight"
|
||||
android:paddingBottom="16dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:gravity="center_horizontal"
|
||||
android:onClick='@{() -> callbacks.onAppClicked()}'
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/icon"
|
||||
android:layout_width="48dp"
|
||||
android:layout_height="48dp"
|
||||
android:antialias="true"
|
||||
android:scaleType="fitCenter"
|
||||
android:src="@{appIcon}"
|
||||
tools:src="@android:mipmap/sym_def_app_icon" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:ellipsize="marquee"
|
||||
android:gravity="center"
|
||||
android:singleLine="false"
|
||||
android:text='@{appName}'
|
||||
android:textAppearance="@style/TextAppearance.AppCompat.Subhead"
|
||||
android:textColor="?android:attr/textColorPrimary"
|
||||
android:textSize="20sp"
|
||||
tools:text="@tools:sample/lorem" />
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.fragment.app.FragmentContainerView
|
||||
android:id="@+id/sub_preferences"
|
||||
android:name="org.microg.gms.ui.PushNotificationAppPreferencesFragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
</LinearLayout>
|
||||
</layout>
|
45
play-services-core/src/main/res/layout/push_notification_fragment.xml
Executable file
45
play-services-core/src/main/res/layout/push_notification_fragment.xml
Executable file
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="gcmEnabled"
|
||||
type="boolean" />
|
||||
|
||||
<variable
|
||||
name="checkinEnabled"
|
||||
type="boolean" />
|
||||
|
||||
<variable
|
||||
name="switchBarCallback"
|
||||
type="org.microg.gms.ui.PreferenceSwitchBarCallback" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include
|
||||
layout="@layout/preference_switch_bar"
|
||||
app:callback="@{switchBarCallback}"
|
||||
app:checked="@{gcmEnabled}"
|
||||
app:description='@{"Receive push notifications"}'
|
||||
app:enabled="@{checkinEnabled}" />
|
||||
|
||||
<androidx.fragment.app.FragmentContainerView
|
||||
android:id="@+id/sub_preferences"
|
||||
android:name="org.microg.gms.ui.PushNotificationPreferencesFragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
</LinearLayout>
|
||||
</layout>
|
|
@ -70,6 +70,7 @@ Dies kann einige Minuten dauern."</string>
|
|||
|
||||
<string name="prefcat_about">Infos</string>
|
||||
<string name="prefcat_google_services">Google-Dienste</string>
|
||||
<string name="pref_more_settings">Mehr</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Batterieoptimierung aktiv</string>
|
||||
<string name="cond_gcm_bat_summary">Google Cloud Messaging ist aktiv aber Batterieoptimierungen wurden für microG nicht deaktiviert. Damit Push-Nachrichten zugestellt werden können, muss Batterieoptimierung deaktiviert werden.</string>
|
||||
|
@ -100,6 +101,8 @@ Dies kann einige Minuten dauern."</string>
|
|||
<string name="gcm_unregister_confirm_message">Einige Apps registrieren sich nicht automatisch erneut und haben keine Möglichkeit dies manuell anzustoßen. Diese Apps funktionieren eventuell nach dem abmelden nicht mehr richtig.\nFortsetzen?</string>
|
||||
<string name="gcm_unregister_after_deny_message">Du hast einer App die Erlaubnis der Registrierung entzogen, die bereits registriert ist.\nWillst du diese App jetzt auch abmelden damit sie zukünftig keine Push-Nachrichten erhält?</string>
|
||||
<string name="gcm_messages_counter">Nachrichten: <xliff:g example="123">%1$d</xliff:g> (<xliff:g example="12345">%2$d</xliff:g> bytes)</string>
|
||||
<string name="gcm_network_state_disconnected">Nicht verbunden</string>
|
||||
<string name="gcm_network_state_connected">Verbunden seit <xliff:g example="2 hours ago">%1$s</xliff:g></string>
|
||||
|
||||
<string name="pref_snet_status_official_info">offizieller Server</string>
|
||||
<string name="pref_snet_status_third_party_info">Dritt-Server</string>
|
||||
|
|
|
@ -69,6 +69,7 @@ Ceci peut prendre plusieurs minutes."</string>
|
|||
|
||||
<string name="prefcat_about">À propos</string>
|
||||
<string name="prefcat_google_services">Services Google</string>
|
||||
<string name="pref_more_settings">Plus</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Optimisations de la batterie activées</string>
|
||||
<string name="cond_gcm_bat_summary">Vous avez activé Google Cloud Messaging mais l’optimisation de la batterie est activée pour microG Services Core. Afin de recevoir les notifications push vous devriez désactiver les optimisations de la batterie.</string>
|
||||
|
@ -98,5 +99,7 @@ Ceci peut prendre plusieurs minutes."</string>
|
|||
<string name="gcm_unregister_confirm_message">Certaines applications ne se réenregistrent pas et/ou ne fournisse pas de moyens de le faire manuellement. Ces applications peuvent ne plus fonctionner correctement après le désenregistrement.\nContinuer ?</string>
|
||||
<string name="gcm_unregister_after_deny_message">Vous avez empêché une application déjà enregistrée de s’enregistrer pour recevoir des notifications push.\nVoulez-vous la désenregistrer maintenant pour qu’elle ne reçoive plus de notifications push à l’avenir ?</string>
|
||||
<string name="gcm_messages_counter">Messages : <xliff:g example="123">%1$d</xliff:g> (<xliff:g example="12345">%2$d</xliff:g> octets)</string>
|
||||
<string name="gcm_network_state_disconnected">Déconnecté</string>
|
||||
<string name="gcm_network_state_connected">Connecté depuis <xliff:g example="2 hours ago">%1$s</xliff:g></string>
|
||||
|
||||
</resources>
|
||||
|
|
|
@ -77,6 +77,7 @@ Questa operazione può richiedere alcuni minuti."</string>
|
|||
|
||||
<string name="prefcat_about">Informazioni</string>
|
||||
<string name="prefcat_google_services">Servizi Google</string>
|
||||
<string name="pref_more_settings">Impostazioni avanzate</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Ottimizzazioni della batteria abilitate</string>
|
||||
<string name="cond_gcm_bat_summary">Hai abilitato il servizio di messaggistica cloud di Google, tuttavia le ottimizzazioni della batteria sono abilitate per microG. Al fine di garantire la ricezione delle notisfiche push, dovresti slezionare l\'opzione per ignorare le ottimizzazioni della batteria.</string>
|
||||
|
@ -110,7 +111,8 @@ Questa operazione può richiedere alcuni minuti."</string>
|
|||
<string name="gcm_unregister_confirm_message">Alcune applicazioni non rinnovano automaticamente la registrazione e/o non forniscono un\'opzione per farlo manualmente. Queste applicazioni potrebbero non funzionare correttamente a seguito della de-registrazione.\nContinuare?</string>
|
||||
<string name="gcm_unregister_after_deny_message">Hai negato ad una applicazione già registrata di registrarsi alle notifiche push.\nDesideri de-registrarla così che non riceva più notifiche push in futuro?</string>
|
||||
<string name="gcm_messages_counter">Messaggi: <xliff:g example="123">%1$d</xliff:g> (<xliff:g example="12345">%2$d</xliff:g> bytes)</string>
|
||||
|
||||
<string name="gcm_network_state_disconnected">Disconnesso</string>
|
||||
<string name="gcm_network_state_connected">Connesso da <xliff:g example="2 hours ago">%1$s</xliff:g></string>
|
||||
<string name="pref_snet_status_official_info">Server ufficiale</string>
|
||||
<string name="pref_snet_status_third_party_info">Server di terze parti</string>
|
||||
<string name="pref_snet_status_self_signed_info">Certificato auto-firmato</string>
|
||||
|
|
|
@ -69,6 +69,7 @@ To zajmie kilka minut.</string>
|
|||
|
||||
<string name="prefcat_about">O programie</string>
|
||||
<string name="prefcat_google_services">Usługi Google</string>
|
||||
<string name="pref_more_settings">Więcej</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Optymalizacja baterii włączona</string>
|
||||
<string name="cond_gcm_bat_summary">Aktywowałeś usługę Google Cloud Messaging, ale optymalizacja baterii dla usługi microG jest włączona. Aby powiadomienia ‘push’ działały, powinieneś wyłączyć optymalizację baterii dla microG.</string>
|
||||
|
|
|
@ -88,5 +88,7 @@ Isso pode demorar alguns minutos."</string>
|
|||
<string name="gcm_unregister_confirm_message">Algumas aplicações não registam automaticamente e/ou não fornecem uma opção para fazê-lo manualmente. Esses aplicativos podem não funcionar corretamente após o cancelamento do registro.\nContinuar?</string>
|
||||
<string name="gcm_unregister_after_deny_message">Você negou um app para se registrar para notificações push que já está registrado.\nDeseja cancelar o registo agora para que não receba mensagens de envio no futuro?</string>
|
||||
<string name="gcm_messages_counter">Mensagens: <xliff:g example="123">%1$d</xliff:g> (<xliff:g example="12345">%2$d</xliff:g> bytes)</string>
|
||||
<string name="gcm_network_state_disconnected">Desconectado</string>
|
||||
<string name="gcm_network_state_connected">Conectado desde <xliff:g example="2 hours ago">%1$s</xliff:g></string>
|
||||
|
||||
</resources>
|
||||
|
|
|
@ -77,6 +77,7 @@
|
|||
|
||||
<string name="prefcat_about">О программе</string>
|
||||
<string name="prefcat_google_services">Google сервисы</string>
|
||||
<string name="pref_more_settings">Ещё</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Активна оптимизация энергопотребления</string>
|
||||
<string name="cond_gcm_bat_summary">Вы включили Google Cloud Messaging, но у вас активна оптимизация энергопотребления для microG Services Core. Чтобы получать push-уведомления вам необходимо разрешить приложению работать в фоновом режиме.</string>
|
||||
|
|
|
@ -76,6 +76,7 @@
|
|||
|
||||
<string name="prefcat_about">Про</string>
|
||||
<string name="prefcat_google_services">Сервіси Google</string>
|
||||
<string name="pref_more_settings">Додатково</string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Увімкнута оптимізація енергоспоживання</string>
|
||||
<string name="cond_gcm_bat_summary">Ви увімкнули Google Cloud Messaging але лиши оптимізацію енергоспоживання активним для microG Services Core. Аби отримувати push-сповіщення необхідно вимкнути оптимізацію енергоспоживання.</string>
|
||||
|
|
|
@ -62,6 +62,7 @@ This can take a couple of minutes."</string>
|
|||
|
||||
<string name="menu_advanced">Advanced</string>
|
||||
<string name="list_no_item_none">None</string>
|
||||
<string name="list_item_see_all">See all</string>
|
||||
|
||||
<string name="network_type_mobile">Mobile network</string>
|
||||
<string name="network_type_wifi">Wi-Fi</string>
|
||||
|
@ -79,6 +80,10 @@ This can take a couple of minutes."</string>
|
|||
|
||||
<string name="prefcat_about">About</string>
|
||||
<string name="prefcat_google_services">Google Services</string>
|
||||
<string name="pref_more_settings">More</string>
|
||||
|
||||
<string name="checkin_not_registered">Not registered</string>
|
||||
<string name="checkin_last_registration">Last registration: <xliff:g example="Yesterday, 02:20 PM">%1$s</xliff:g></string>
|
||||
|
||||
<string name="cond_gcm_bat_title">Battery optimizations enabled</string>
|
||||
<string name="cond_gcm_bat_summary">You enabled Google Cloud Messaging but have battery optimizations active for microG Services Core. For push notifications to arrive you should ignore battery optimizations.</string>
|
||||
|
@ -102,6 +107,9 @@ This can take a couple of minutes."</string>
|
|||
|
||||
<string name="pref_about_title">About Vanced microG</string>
|
||||
|
||||
<string name="pref_checkin_enable_summary">Registers your device to Google services and creates a unique device identifier. Vanced microG strips identifying bits other than your Google account name from registration data.</string>
|
||||
<string name="pref_info_status">Status</string>
|
||||
|
||||
<string name="gcm_unregister_app">Unregister</string>
|
||||
<string name="gcm_not_registered">Not registered</string>
|
||||
<string name="gcm_no_message_yet">No messages received so far</string>
|
||||
|
@ -112,7 +120,16 @@ This can take a couple of minutes."</string>
|
|||
<string name="gcm_unregister_confirm_message">Some apps do not automatically re-register and/or do not provide an option to do so manually. These apps might not work correctly after unregistering.\nContinue?</string>
|
||||
<string name="gcm_unregister_after_deny_message">You denied an app to register for push notifications that is already registered.\nDo you want to unregister it now so it does not receive push messages in the future?</string>
|
||||
<string name="gcm_messages_counter">Messages: <xliff:g example="123">%1$d</xliff:g> (<xliff:g example="12345">%2$d</xliff:g> bytes)</string>
|
||||
<string name="gcm_network_state_disconnected">Disconnected</string>
|
||||
<string name="gcm_network_state_connected">Connected since <xliff:g example="2 hours ago">%1$s</xliff:g></string>
|
||||
|
||||
<string name="pref_push_app_allow_register_title">Allow registration</string>
|
||||
<string name="pref_push_app_allow_register_summary">Allow the app to register for push notifications.</string>
|
||||
<string name="pref_push_app_wake_for_delivery_title">Start app on push message</string>
|
||||
<string name="pref_push_app_wake_for_delivery_summary">Start the app while in background to receive the incoming push messages.</string>
|
||||
<string name="prefcat_push_apps_title">Apps using push notifications</string>
|
||||
<string name="prefcat_push_apps_registered_title">Registered apps</string>
|
||||
<string name="prefcat_push_apps_unregistered_title">Unregistered apps</string>
|
||||
<string name="prefcat_push_networks_title">Networks to use for push notifications</string>
|
||||
|
||||
<string name="pref_snet_status_official_info">official server</string>
|
||||
|
|
0
play-services-core/src/main/res/xml/preferences_account.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_account.xml
Normal file → Executable file
6
play-services-core/src/main/res/xml/preferences_auth.xml
Normal file → Executable file
6
play-services-core/src/main/res/xml/preferences_auth.xml
Normal file → Executable file
|
@ -18,16 +18,16 @@
|
|||
<PreferenceScreen
|
||||
android:key="k2"
|
||||
android:title="@string/prefs_account_security">
|
||||
<intent android:action="com.google.android.gms.accountsettings.SECURITY_SETTINGS"/>
|
||||
<intent android:action="com.mgoogle.android.gms.accountsettings.SECURITY_SETTINGS"/>
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen
|
||||
android:key="k3"
|
||||
android:title="@string/prefs_account_privacy">
|
||||
<intent android:action="com.google.android.gms.accountsettings.PRIVACY_SETTINGS"/>
|
||||
<intent android:action="com.mgoogle.android.gms.accountsettings.PRIVACY_SETTINGS"/>
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen
|
||||
android:key="k4"
|
||||
android:title="@string/prefs_account">
|
||||
<intent android:action="com.google.android.gms.accountsettings.ACCOUNT_PREFERENCES_SETTINGS"/>
|
||||
<intent android:action="com.mgoogle.android.gms.accountsettings.ACCOUNT_PREFERENCES_SETTINGS"/>
|
||||
</PreferenceScreen>
|
||||
</PreferenceScreen>
|
||||
|
|
24
play-services-core/src/main/res/xml/preferences_device_registration.xml
Executable file
24
play-services-core/src/main/res/xml/preferences_device_registration.xml
Executable file
|
@ -0,0 +1,24 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2017, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_device_registration_status"
|
||||
android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:key="pref_device_registration_status"
|
||||
android:selectable="false"
|
||||
android:title="@string/pref_info_status"
|
||||
tools:summary="Last registration: 13 hours ago" />
|
||||
</PreferenceCategory>
|
||||
<PreferenceCategory android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:icon="@drawable/ic_info_outline"
|
||||
android:selectable="false"
|
||||
android:summary="@string/pref_checkin_enable_summary" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
0
play-services-core/src/main/res/xml/preferences_gcm.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_gcm.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_gcm_advanced.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_gcm_advanced.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_google_more.xml
Normal file → Executable file
0
play-services-core/src/main/res/xml/preferences_google_more.xml
Normal file → Executable file
40
play-services-core/src/main/res/xml/preferences_push_notifications.xml
Executable file
40
play-services-core/src/main/res/xml/preferences_push_notifications.xml
Executable file
|
@ -0,0 +1,40 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:title="Push notifications">
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_apps"
|
||||
android:title="@string/prefcat_push_apps_title">
|
||||
<Preference
|
||||
android:enabled="false"
|
||||
android:key="pref_push_apps_none"
|
||||
android:title="@string/list_no_item_none"
|
||||
tools:isPreferenceVisible="true" />
|
||||
<Preference
|
||||
android:icon="@drawable/ic_expand_apps"
|
||||
android:key="pref_push_apps_all"
|
||||
android:order="5"
|
||||
android:title="@string/list_item_see_all" />
|
||||
</PreferenceCategory>
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_status"
|
||||
android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:key="pref_push_status"
|
||||
android:selectable="false"
|
||||
android:title="Status"
|
||||
tools:summary="Connected since 15 minutes ago" />
|
||||
</PreferenceCategory>
|
||||
<PreferenceCategory android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:icon="@drawable/ic_info_outline"
|
||||
android:selectable="false"
|
||||
android:summary="@string/pref_gcm_enable_mcs_summary" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
|
@ -0,0 +1,39 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:title="@string/prefcat_push_apps_title">
|
||||
<Preference
|
||||
android:key="pref_push_apps_all_progress"
|
||||
android:layout="@layout/preference_progress_bar"
|
||||
app:allowDividerBelow="false" />
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_apps_registered"
|
||||
android:title="@string/prefcat_push_apps_registered_title"
|
||||
app:isPreferenceVisible="false"
|
||||
tools:isPreferenceVisible="true">
|
||||
<Preference
|
||||
android:enabled="false"
|
||||
android:key="pref_push_apps_registered_none"
|
||||
android:title="@string/list_no_item_none"
|
||||
app:isPreferenceVisible="false"
|
||||
tools:isPreferenceVisible="true" />
|
||||
</PreferenceCategory>
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_apps_unregistered"
|
||||
android:title="@string/prefcat_push_apps_unregistered_title"
|
||||
app:isPreferenceVisible="false"
|
||||
tools:isPreferenceVisible="true">
|
||||
<Preference
|
||||
android:enabled="false"
|
||||
android:key="pref_push_apps_unregistered_none"
|
||||
android:title="@string/list_no_item_none"
|
||||
app:isPreferenceVisible="false"
|
||||
tools:isPreferenceVisible="true" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
43
play-services-core/src/main/res/xml/preferences_push_notifications_app.xml
Executable file
43
play-services-core/src/main/res/xml/preferences_push_notifications_app.xml
Executable file
|
@ -0,0 +1,43 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ SPDX-FileCopyrightText: 2020, microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_app_settings"
|
||||
android:layout="@layout/preference_category_no_label">
|
||||
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="pref_push_app_allow_register"
|
||||
android:persistent="false"
|
||||
android:summary="@string/pref_push_app_allow_register_summary"
|
||||
android:title="@string/pref_push_app_allow_register_title" />
|
||||
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="pref_push_app_wake_for_delivery"
|
||||
android:persistent="false"
|
||||
android:summary="@string/pref_push_app_wake_for_delivery_summary"
|
||||
android:title="@string/pref_push_app_wake_for_delivery_title" />
|
||||
|
||||
</PreferenceCategory>
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="prefcat_push_app_unregister"
|
||||
android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:key="pref_push_app_unregister"
|
||||
android:title="@string/gcm_unregister_app" />
|
||||
</PreferenceCategory>
|
||||
|
||||
<PreferenceCategory android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:key="pref_push_app_status"
|
||||
android:selectable="false"
|
||||
tools:summary="Messages: 1000 (37 MB)\nLast message: 22 min ago\nRegistered since: 3 month ago" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
43
play-services-core/src/main/res/xml/preferences_start.xml
Normal file → Executable file
43
play-services-core/src/main/res/xml/preferences_start.xml
Normal file → Executable file
|
@ -14,40 +14,39 @@
|
|||
~ limitations under the License.
|
||||
-->
|
||||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<PreferenceCategory android:title="@string/prefcat_google_services">
|
||||
<org.microg.tools.ui.TintIconPreference
|
||||
<Preference
|
||||
android:icon="@drawable/ic_add_account"
|
||||
android:summary="@string/pref_add_account_summary"
|
||||
android:title="@string/pref_add_account_title">
|
||||
<intent
|
||||
android:targetClass="org.microg.gms.auth.login.LoginActivity"
|
||||
android:targetPackage="com.mgoogle.android.gms"/>
|
||||
</org.microg.tools.ui.TintIconPreference>
|
||||
<org.microg.tools.ui.TintIconPreference
|
||||
android:targetPackage="com.mgoogle.android.gms" />
|
||||
</Preference>
|
||||
<Preference
|
||||
android:icon="@drawable/ic_device_login"
|
||||
android:key="pref_checkin"
|
||||
android:title="@string/service_name_checkin">
|
||||
<intent
|
||||
android:targetClass="org.microg.gms.ui.CheckinFragment$AsActivity"
|
||||
android:targetPackage="com.mgoogle.android.gms"/>
|
||||
</org.microg.tools.ui.TintIconPreference>
|
||||
<org.microg.tools.ui.TintIconPreference
|
||||
android:title="@string/service_name_checkin" />
|
||||
<Preference
|
||||
android:icon="@drawable/ic_cloud_bell"
|
||||
android:key="pref_gcm"
|
||||
android:title="@string/service_name_mcs">
|
||||
android:title="@string/service_name_mcs" />
|
||||
<Preference
|
||||
android:icon="@drawable/dots_horizontal"
|
||||
android:key="pref_google_more"
|
||||
android:title="@string/pref_more_settings"
|
||||
app:isPreferenceVisible="false">
|
||||
<intent
|
||||
android:targetClass="org.microg.gms.ui.GcmFragment$AsActivity"
|
||||
android:targetPackage="com.mgoogle.android.gms"/>
|
||||
</org.microg.tools.ui.TintIconPreference>
|
||||
android:targetClass="org.microg.gms.ui.GoogleMoreFragment$AsActivity"
|
||||
android:targetPackage="com.mgoogle.android.gms" />
|
||||
</Preference>
|
||||
</PreferenceCategory>
|
||||
<PreferenceCategory android:title="@string/prefcat_about">
|
||||
<org.microg.tools.ui.TintIconPreference
|
||||
<PreferenceCategory android:layout="@layout/preference_category_no_label">
|
||||
<Preference
|
||||
android:icon="@drawable/ic_info_outline"
|
||||
android:key="pref_about"
|
||||
android:title="@string/pref_about_title">
|
||||
<intent
|
||||
android:targetClass="org.microg.gms.ui.AboutFragment$AsActivity"
|
||||
android:targetPackage="com.mgoogle.android.gms"/>
|
||||
</org.microg.tools.ui.TintIconPreference>
|
||||
android:title="@string/pref_about_title" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
||||
|
|
Loading…
Reference in a new issue