Skip to content

Commit adda27d

Browse files
committed
Manual unrestrict on 13790637.
1 parent 42f9dda commit adda27d

22 files changed

+3
-37
lines changed

xr/build.gradle.kts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ android {
2525
buildFeatures {
2626
compose = true
2727
}
28+
lint {
29+
disable += "RestrictedApi"
30+
}
2831
}
2932

3033
dependencies {

xr/src/main/java/com/example/xr/arcore/Anchors.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ private fun createAnchorAtTrackable(trackable: Trackable<*>) {
6363
// [END androidxr_arcore_anchor_create_trackable]
6464
}
6565

66-
@Suppress("RestrictedApi") // b/422174724
6766
private fun attachEntityToAnchor(
6867
session: Session,
6968
entity: Entity,

xr/src/main/java/com/example/xr/arcore/Hands.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ fun secondaryHandDetection(activity: Activity, session: Session) {
7676
// [END androidxr_arcore_hand_handedness]
7777
}
7878

79-
@Suppress("RestrictedApi") // b/416066566
8079
fun ComponentActivity.renderPlanetAtHandPalm(leftHandState: Hand.State) {
8180
val session: Session = null!!
8281
val palmEntity: GltfModelEntity = null!!
@@ -97,7 +96,6 @@ fun ComponentActivity.renderPlanetAtHandPalm(leftHandState: Hand.State) {
9796
// [END androidxr_arcore_hand_entityAtHandPalm]
9897
}
9998

100-
@Suppress("RestrictedApi") // b/416066566
10199
fun ComponentActivity.renderPlanetAtFingerTip(rightHandState: Hand.State) {
102100
val session: Session = null!!
103101
val indexFingerEntity: GltfModelEntity = null!!
@@ -120,7 +118,6 @@ fun ComponentActivity.renderPlanetAtFingerTip(rightHandState: Hand.State) {
120118
// [END androidxr_arcore_hand_entityAtIndexFingerTip]
121119
}
122120

123-
@Suppress("RestrictedApi") // b/416066566
124121
private fun detectPinch(session: Session, handState: Hand.State): Boolean {
125122
// [START androidxr_arcore_hand_pinch_gesture]
126123
val thumbTip = handState.handJoints[HandJointType.THUMB_TIP] ?: return false

xr/src/main/java/com/example/xr/arcore/Planes.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ private suspend fun subscribePlanes(session: Session) {
4848
// [END androidxr_arcore_planes_subscribe]
4949
}
5050

51-
@Suppress("RestrictedApi") // b/416066566
5251
private fun hitTestTable(session: Session) {
5352
val pose = session.scene.spatialUser.head?.transformPoseTo(Pose(), session.scene.perceptionSpace) ?: return
5453
val ray = Ray(pose.translation, pose.forward)

xr/src/main/java/com/example/xr/compose/Orbiter.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ import androidx.xr.compose.subspace.layout.resizable
5050
import androidx.xr.compose.subspace.layout.width
5151
import com.example.xr.R
5252

53-
@Suppress("RestrictedApi") // b/416066566
5453
@Composable
5554
private fun OrbiterExampleSubspace() {
5655
// [START androidxr_compose_OrbiterExampleSubspace]
@@ -98,7 +97,6 @@ fun OrbiterExample() {
9897
// [END androidxr_compose_OrbiterExample]
9998

10099
@Composable
101-
@Suppress("RestrictedApi") // b/416066566
102100
fun OrbiterAnchoringExample() {
103101
// [START androidxr_compose_OrbiterAnchoringExample]
104102
Subspace {

xr/src/main/java/com/example/xr/compose/SpatialCapabilities.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ private fun SpatialCapabilitiesCheck() {
4545
// [END androidxr_compose_checkSpatialCapabilities]
4646
}
4747

48-
@Suppress("RestrictedApi") // b/416066566
4948
@Composable
5049
private fun checkSpatialUiEnabled() {
5150
// [START androidxr_compose_checkSpatialUiEnabled]

xr/src/main/java/com/example/xr/compose/SpatialExternalSurface.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ import androidx.xr.compose.subspace.layout.width
3636

3737
// [START androidxr_compose_SpatialExternalSurfaceStereo]
3838
@OptIn(ExperimentalComposeApi::class)
39-
@Suppress("RestrictedApi") // b/416066566
4039
@Composable
4140
fun SpatialExternalSurfaceContent() {
4241
val context = LocalContext.current
@@ -77,7 +76,6 @@ fun SpatialExternalSurfaceContent() {
7776

7877
// [START androidxr_compose_SpatialExternalSurfaceDRM]
7978
@OptIn(ExperimentalComposeApi::class)
80-
@Suppress("RestrictedApi") // b/416066566
8179
@Composable
8280
fun DrmSpatialVideoPlayer() {
8381
val context = LocalContext.current

xr/src/main/java/com/example/xr/compose/SpatialLayout.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ import androidx.xr.compose.subspace.layout.SubspaceModifier
3636
import androidx.xr.compose.subspace.layout.height
3737
import androidx.xr.compose.subspace.layout.width
3838

39-
@Suppress("RestrictedApi") // b/416066566
4039
@Composable
4140
private fun SpatialLayoutExampleSubspace() {
4241
// [START androidxr_compose_SpatialLayoutExampleSubspace]

xr/src/main/java/com/example/xr/compose/SpatialPanel.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ import androidx.xr.compose.subspace.layout.movable
3636
import androidx.xr.compose.subspace.layout.resizable
3737
import androidx.xr.compose.subspace.layout.width
3838

39-
@Suppress("RestrictedApi") // b/416066566
4039
@Composable
4140
private fun SpatialPanelExample() {
4241
// [START androidxr_compose_SpatialPanel]
@@ -76,7 +75,6 @@ fun SpatialPanelContent() {
7675
@Composable
7776
private fun AppContent() {}
7877

79-
@Suppress("RestrictedApi") // b/416066566
8078
@Composable
8179
private fun ContentInSpatialPanel() {
8280
// [START androidxr_compose_SpatialPanelAppContent]

xr/src/main/java/com/example/xr/compose/SpatialRow.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ import androidx.xr.compose.subspace.layout.SubspaceModifier
2424
import androidx.xr.compose.subspace.layout.height
2525
import androidx.xr.compose.subspace.layout.width
2626

27-
@Suppress("RestrictedApi") // b/416066566
2827
@Composable
2928
private fun SpatialRowExample() {
3029
// [START androidxr_compose_SpatialRowExample]

0 commit comments

Comments
 (0)