[Catalyst] Introduce SettingsContract file

The new file contains all contract constants for external usages (e.g.
slice, external Get/Set API). Also reuse existing constants in
SettingsSlicesContract.

NO_IFTTT=Catalyst only

Bug: 388061003
Flag: EXEMPT refactor
Test: atest
Change-Id: I449b7b6cf82e1e102f2c96a21835191605f09943
This commit is contained in:
Jacky Wang
2025-02-04 15:39:57 +08:00
parent 1ecacd8a5a
commit 2e265d4a7a
8 changed files with 49 additions and 14 deletions

View File

@@ -53,6 +53,7 @@ import androidx.slice.SliceProvider;
import androidx.slice.widget.SliceLiveData;
import com.android.settings.Utils;
import com.android.settings.contract.SettingsContractKt;
import com.android.settings.testutils.DatabaseTestUtils;
import com.android.settings.testutils.FakeToggleController;
import com.android.settings.testutils.shadow.ShadowBluetoothAdapter;
@@ -626,7 +627,7 @@ public class SettingsSliceProviderTest {
.scheme(ContentResolver.SCHEME_CONTENT)
.authority(SettingsSlicesContract.AUTHORITY)
.appendPath(SettingsSlicesContract.PATH_SETTING_ACTION)
.appendPath(SettingsSlicesContract.KEY_LOCATION)
.appendPath(SettingsContractKt.KEY_LOCATION)
.build();
mProvider.onSlicePinned(uri);