[Thread] use dedicated flag for Thread settings
a larger THREAD_ENABLED_PLATFORM flag which guards all Thread-related platform changes is used for the Thread settings change. But we need more flexible control of the UX release timeline. So use a dedicated THREAD_SETTINGS_ENABLED flag here. Bug: 329384658 Change-Id: Ib5b3ae3c71ccc890fc46af982b021858774938f3
This commit is contained in:
@@ -34,9 +34,9 @@ import androidx.lifecycle.LifecycleEventObserver
|
||||
import androidx.lifecycle.LifecycleOwner
|
||||
import androidx.preference.Preference
|
||||
import androidx.preference.PreferenceScreen
|
||||
import com.android.net.thread.platform.flags.Flags
|
||||
import com.android.settings.R
|
||||
import com.android.settings.core.TogglePreferenceController
|
||||
import com.android.settings.flags.Flags
|
||||
import java.util.concurrent.Executor
|
||||
|
||||
/** Controller for the "Thread" toggle in "Connected devices > Connection preferences". */
|
||||
@@ -110,7 +110,7 @@ class ThreadNetworkPreferenceController @VisibleForTesting constructor(
|
||||
}
|
||||
|
||||
override fun getAvailabilityStatus(): Int {
|
||||
return if (!Flags.threadEnabledPlatform()) {
|
||||
return if (!Flags.threadSettingsEnabled()) {
|
||||
CONDITIONALLY_UNAVAILABLE
|
||||
} else if (!isThreadSupportedOnDevice) {
|
||||
UNSUPPORTED_ON_DEVICE
|
||||
|
||||
Reference in New Issue
Block a user