Skip to content

Commit c3c63c0

Browse files
committed
fix swipe gesture
1 parent 1b5fc00 commit c3c63c0

4 files changed

Lines changed: 45 additions & 7 deletions

File tree

lib/app/MainApp.dart

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,16 @@ class MyApp extends StatelessWidget {
221221
}
222222
}
223223

224-
final materialThemeDataLight = ThemeData.from(
224+
// final materialThemeDataLight = ThemeData(
225+
// colorScheme: ColorScheme.fromSeed(
226+
// seedColor: themeColorEntity.themeColor,
227+
// dynamicSchemeVariant: themeColorEntity.dynamicSchemeVariant,
228+
// brightness: Brightness.light,
229+
// )
230+
// //surface: Colors.white,
231+
// );
232+
233+
final materialThemeDataLight = ThemeData(
225234
colorScheme: ColorScheme.fromSeed(
226235
seedColor: themeColorEntity.themeColor,
227236
dynamicSchemeVariant: themeColorEntity.dynamicSchemeVariant,
@@ -230,9 +239,15 @@ class MyApp extends StatelessWidget {
230239
).harmonized(),
231240
useMaterial3: themeColorEntity.useMaterial3,
232241
textTheme: typography.black.useSystemChineseFont(Brightness.light),
242+
pageTransitionsTheme: Platform.isIOS?PageTransitionsTheme(
243+
builders: {
244+
TargetPlatform.android: CupertinoPageTransitionsBuilder(),
245+
TargetPlatform.iOS: CupertinoPageTransitionsBuilder(),
246+
}
247+
): null
233248
);
234249

235-
final materialThemeDataDark = ThemeData.from(
250+
final materialThemeDataDark = ThemeData(
236251
colorScheme: ColorScheme.fromSeed(
237252
seedColor: themeColorEntity.themeColor,
238253
dynamicSchemeVariant: themeColorEntity.dynamicSchemeVariant,
@@ -241,6 +256,12 @@ class MyApp extends StatelessWidget {
241256
).harmonized(),
242257
useMaterial3: themeColorEntity.useMaterial3,
243258
textTheme: typography.white.useSystemChineseFont(Brightness.dark),
259+
pageTransitionsTheme: Platform.isIOS?PageTransitionsTheme(
260+
builders: {
261+
TargetPlatform.android: CupertinoPageTransitionsBuilder(),
262+
TargetPlatform.iOS: CupertinoPageTransitionsBuilder(),
263+
}
264+
): null
244265
);
245266
const darkDefaultCupertinoTheme =
246267
CupertinoThemeData(brightness: Brightness.dark);

lib/page/SubscribeChannelPage.dart

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -223,15 +223,18 @@ class SubscribeChannelState extends State<SubscribeChannelStatefulWidget> {
223223
if (index ==
224224
subscribeChannelResult.channelList.length - 1 &&
225225
isSubmitting == true)
226-
PlatformCircularProgressIndicator(),
226+
Container(
227+
padding: EdgeInsets.all(8),
228+
child: PlatformCircularProgressIndicator()
229+
),
227230
],
228231
);
229232
});
230233
} else {
231234
// no channel
232235
return Center(
233236
child: Padding(
234-
padding: EdgeInsets.symmetric(vertical: 64, horizontal: 32),
237+
padding: EdgeInsets.symmetric(vertical: 64, horizontal: 16),
235238
child: Column(
236239
mainAxisSize: MainAxisSize.max,
237240
mainAxisAlignment: MainAxisAlignment.center,

lib/screen/LoadingScreen.dart

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,20 @@ class LoadingScreen extends StatelessWidget{
1111
@override
1212
Widget build(BuildContext context) {
1313

14-
return Container(
15-
child: PlatformCircularProgressIndicator(),
14+
return Center(
15+
child: Column(
16+
mainAxisSize: MainAxisSize.max,
17+
mainAxisAlignment: MainAxisAlignment.center,
18+
crossAxisAlignment: CrossAxisAlignment.center,
19+
children: [
20+
SizedBox(
21+
width: 32,
22+
height: 32,
23+
child: PlatformCircularProgressIndicator(),
24+
),
25+
26+
],
27+
),
1628
);
1729
}
1830

pubspec.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,9 @@ dependencies:
7575
# flutter_apns: ^1.6.0
7676
scroll_to_index: any
7777
easy_refresh: ^3.0.2+2
78-
open_filex: ^4.0.1
78+
open_filex:
79+
git:
80+
url: https://github.com/mufassalhussain/open_filex
7981
flutter_polls: ^0.1.0
8082
push: ^3.3.3
8183
google_mobile_ads: ^5.1.0

0 commit comments

Comments
 (0)