Modern-Apps.git
Publicgit clone https://git.maproj.org/Modern-Apps.gitModern-Apps.git / camera / src / main / AndroidManifest.xml
AndroidManifest.xml109 lines · 5.9 KiBRaw
| 1 | <?xml version="1.0" encoding="utf-8"?> |
| 2 | <manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools"> |
| 3 | |
| 4 | <uses-permission android:name="android.permission.CAMERA" /> |
| 5 | <uses-permission android:name="android.permission.RECORD_AUDIO" /> |
| 6 | <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> |
| 7 | <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" /> |
| 8 | <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> |
| 9 | <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /> |
| 10 | <uses-permission android:name="android.permission.INTERNET" tools:node="remove" /> |
| 11 | <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" tools:node="remove" /> |
| 12 | |
| 13 | <!-- Single APK for phone and watch. Deliberately NO |
| 14 | android.hardware.type.watch uses-feature here: required="true" |
| 15 | would block every phone install, and required="false" is |
| 16 | disallowed for this feature (lint InvalidWearFeatureAttribute; |
| 17 | Google's packaging model does not support one APK for Wear and |
| 18 | non-Wear via Play). This app does not distribute through Play's |
| 19 | watch channel — it is sideloaded / F-Droid-installed, where no |
| 20 | feature declaration is needed to install on a watch — so the |
| 21 | APK carries no watch feature filter at all and |
| 22 | FormFactor.isWatch (PackageManager.FEATURE_WATCH, still |
| 23 | reported by watch hardware at runtime) routes the experience. |
| 24 | The camera feature is likewise not required: a watch has no |
| 25 | camera of its own (the watch experience is a remote viewfinder |
| 26 | streamed from the phone, entered before any camera use), and |
| 27 | phones keep the existing permission-gated camera UI. --> |
| 28 | <uses-feature android:name="android.hardware.camera" android:required="false" /> |
| 29 | <uses-feature android:name="android.hardware.camera.autofocus" android:required="false" /> |
| 30 | <!-- Watch-local viewfinder/controls wake the watch CPU while linked. --> |
| 31 | <uses-permission android:name="android.permission.WAKE_LOCK" /> |
| 32 | |
| 33 | <!-- Package visibility (API 30+): lets the eSIM universal link resolve to the |
| 34 | LPA declaring esimsetup.android.com instead of failing visibility and |
| 35 | falling through to a browser. --> |
| 36 | <queries> |
| 37 | <intent> |
| 38 | <action android:name="android.intent.action.VIEW" /> |
| 39 | <data android:scheme="https" /> |
| 40 | </intent> |
| 41 | </queries> |
| 42 | |
| 43 | <application |
| 44 | android:allowBackup="true" |
| 45 | android:dataExtractionRules="@xml/data_extraction_rules" |
| 46 | android:icon="@mipmap/ic_launcher" |
| 47 | android:label="@string/app_name" |
| 48 | android:roundIcon="@mipmap/ic_launcher" |
| 49 | android:supportsRtl="true" |
| 50 | android:theme="@style/Theme.General"> |
| 51 | |
| 52 | <!-- Watch experience is paired with the phone app, not standalone. --> |
| 53 | <meta-data |
| 54 | android:name="com.google.android.wearable.standalone" |
| 55 | android:value="false" /> |
| 56 | <!-- Portrait-locked on purpose: the viewfinder layout never rotates, so |
| 57 | capture controls stay in the same place in portrait and landscape; |
| 58 | only the control icons rotate in place, and capture orientation is |
| 59 | derived from the same physical quadrant (OrientationEventListener |
| 60 | in CameraScreenEffects, via domain.CaptureRotation). --> |
| 61 | <activity |
| 62 | android:configChanges="mcc|mnc|colorMode|density|fontScale|fontWeightAdjustment|keyboard|keyboardHidden|layoutDirection|navigation|orientation|screenLayout|screenSize|smallestScreenSize|touchscreen|uiMode" |
| 63 | android:name=".MainActivity" |
| 64 | android:exported="true" |
| 65 | android:screenOrientation="portrait" |
| 66 | tools:ignore="LockedOrientationActivity" |
| 67 | android:showWhenLocked="true" |
| 68 | android:turnScreenOn="true" |
| 69 | android:theme="@style/Theme.General"> |
| 70 | <intent-filter> |
| 71 | <action android:name="android.intent.action.MAIN" /> |
| 72 | <category android:name="android.intent.category.LAUNCHER" /> |
| 73 | </intent-filter> |
| 74 | <intent-filter> |
| 75 | <action android:name="android.intent.action.APPLICATION_PREFERENCES" /> |
| 76 | <category android:name="android.intent.category.DEFAULT" /> |
| 77 | </intent-filter> |
| 78 | <intent-filter> |
| 79 | <action android:name="android.media.action.IMAGE_CAPTURE" /> |
| 80 | <category android:name="android.intent.category.DEFAULT" /> |
| 81 | </intent-filter> |
| 82 | <intent-filter> |
| 83 | <action android:name="android.media.action.STILL_IMAGE_CAMERA" /> |
| 84 | <category android:name="android.intent.category.DEFAULT" /> |
| 85 | </intent-filter> |
| 86 | <intent-filter> |
| 87 | <action android:name="android.media.action.STILL_IMAGE_CAMERA_SECURE" /> |
| 88 | <category android:name="android.intent.category.DEFAULT" /> |
| 89 | </intent-filter> |
| 90 | <intent-filter> |
| 91 | <action android:name="android.media.action.VIDEO_CAPTURE" /> |
| 92 | <category android:name="android.intent.category.DEFAULT" /> |
| 93 | </intent-filter> |
| 94 | </activity> |
| 95 | <!-- Watch experience: entered only via MainActivity's watch routing |
| 96 | (no launcher filter of its own). Inert on a phone: it is |
| 97 | reached only from MainActivity's FEATURE_WATCH forward, its |
| 98 | WearLinkBridge is created only by this activity, and the |
| 99 | phone-side WearCameraSync starts only on the phone path of |
| 100 | MainActivity. This module declares no broadcast receivers, so |
| 101 | there is no wrong-form-factor receiver surface to gate. --> |
| 102 | <activity |
| 103 | android:name=".ui.WearMainActivity" |
| 104 | android:exported="false" |
| 105 | android:taskAffinity="" |
| 106 | android:theme="@android:style/Theme.Material.NoActionBar" /> |
| 107 | </application> |
| 108 | |
| 109 | </manifest> |