Skip to content

Commit

Permalink
Add relevant permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
dhzdhd committed Jun 29, 2024
1 parent 119ccd3 commit 0c2f147
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 10 deletions.
17 changes: 10 additions & 7 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACTION_MANAGE_ALL_FILES_ACCESS_PERMISSION" />
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
<application
android:label="syncvault"
android:name="${applicationName}"
Expand All @@ -19,12 +21,12 @@
while the Flutter UI initializes. After that, this theme continues
to determine the Window background behind the Flutter UI. -->
<meta-data
android:name="io.flutter.embedding.android.NormalTheme"
android:resource="@style/NormalTheme"
/>
android:name="io.flutter.embedding.android.NormalTheme"
android:resource="@style/NormalTheme"
/>
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

Expand All @@ -35,13 +37,14 @@
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="msauth" android:host="com.example.syncvault"/>
<data android:scheme="msauth" android:host="com.example.syncvault" />
</intent-filter>
<intent-filter android:label="flutter_web_auth_2">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="com.googleusercontent.apps.844110357681-4sa1ev4ep3thlfa5gq3l4pjigvv3n98q"/>
<data
android:scheme="com.googleusercontent.apps.844110357681-4sa1ev4ep3thlfa5gq3l4pjigvv3n98q" />
</intent-filter>
</activity>

Expand Down
9 changes: 6 additions & 3 deletions lib/src/introduction/views/intro_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ class _IntroductionViewState extends ConsumerState<IntroductionView> {
done: const Text('Done', style: TextStyle(fontWeight: FontWeight.w700)),
back: const Text('Back'),
showBackButton: true,
dotsDecorator: DotsDecorator(
activeColor: Theme.of(context).colorScheme.primary,
),
onDone: () {
Navigator.of(context).popAndPushNamed('/home');
},
Expand All @@ -44,7 +47,7 @@ class _IntroductionViewState extends ConsumerState<IntroductionView> {
footer: Center(
child: FilledButton(
onPressed: () async {
await Permission.accessMediaLocation
await Permission.manageExternalStorage
.onDeniedCallback(() {})
.onGrantedCallback(() {})
.request();
Expand All @@ -58,7 +61,7 @@ class _IntroductionViewState extends ConsumerState<IntroductionView> {
body:
'SyncVault requires you to remove battery optimizations to operate normally.',
image: const Center(
child: Icon(Icons.folder, size: 50.0),
child: Icon(Icons.battery_saver, size: 50.0),
),
footer: Center(
child: FilledButton(
Expand All @@ -77,7 +80,7 @@ class _IntroductionViewState extends ConsumerState<IntroductionView> {
body:
'SyncVault requires notification permissions to notify you during sync.',
image: const Center(
child: Icon(Icons.folder, size: 50.0),
child: Icon(Icons.notifications, size: 50.0),
),
footer: Center(
child: FilledButton(
Expand Down

0 comments on commit 0c2f147

Please sign in to comment.