Unfocus search on tap away
This commit is contained in:
@@ -96,13 +96,9 @@ PODS:
|
|||||||
- nanopb/encode (= 3.30910.0)
|
- nanopb/encode (= 3.30910.0)
|
||||||
- nanopb/decode (3.30910.0)
|
- nanopb/decode (3.30910.0)
|
||||||
- nanopb/encode (3.30910.0)
|
- nanopb/encode (3.30910.0)
|
||||||
- "no_screenshot (0.0.1+4)":
|
|
||||||
- Flutter
|
|
||||||
- ScreenProtectorKit (~> 1.3.1)
|
|
||||||
- printing (1.0.0):
|
- printing (1.0.0):
|
||||||
- Flutter
|
- Flutter
|
||||||
- PromisesObjC (2.4.0)
|
- PromisesObjC (2.4.0)
|
||||||
- ScreenProtectorKit (1.3.1)
|
|
||||||
- SDWebImage (5.20.0):
|
- SDWebImage (5.20.0):
|
||||||
- SDWebImage/Core (= 5.20.0)
|
- SDWebImage/Core (= 5.20.0)
|
||||||
- SDWebImage/Core (5.20.0)
|
- SDWebImage/Core (5.20.0)
|
||||||
@@ -128,7 +124,6 @@ DEPENDENCIES:
|
|||||||
- geolocator_apple (from `.symlinks/plugins/geolocator_apple/darwin`)
|
- geolocator_apple (from `.symlinks/plugins/geolocator_apple/darwin`)
|
||||||
- local_auth_darwin (from `.symlinks/plugins/local_auth_darwin/darwin`)
|
- local_auth_darwin (from `.symlinks/plugins/local_auth_darwin/darwin`)
|
||||||
- mobile_scanner (from `.symlinks/plugins/mobile_scanner/ios`)
|
- mobile_scanner (from `.symlinks/plugins/mobile_scanner/ios`)
|
||||||
- no_screenshot (from `.symlinks/plugins/no_screenshot/ios`)
|
|
||||||
- printing (from `.symlinks/plugins/printing/ios`)
|
- printing (from `.symlinks/plugins/printing/ios`)
|
||||||
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
|
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
|
||||||
- syncfusion_flutter_pdfviewer (from `.symlinks/plugins/syncfusion_flutter_pdfviewer/ios`)
|
- syncfusion_flutter_pdfviewer (from `.symlinks/plugins/syncfusion_flutter_pdfviewer/ios`)
|
||||||
@@ -150,7 +145,6 @@ SPEC REPOS:
|
|||||||
- MLKitVision
|
- MLKitVision
|
||||||
- nanopb
|
- nanopb
|
||||||
- PromisesObjC
|
- PromisesObjC
|
||||||
- ScreenProtectorKit
|
|
||||||
- SDWebImage
|
- SDWebImage
|
||||||
- SwiftyGif
|
- SwiftyGif
|
||||||
|
|
||||||
@@ -173,8 +167,6 @@ EXTERNAL SOURCES:
|
|||||||
:path: ".symlinks/plugins/local_auth_darwin/darwin"
|
:path: ".symlinks/plugins/local_auth_darwin/darwin"
|
||||||
mobile_scanner:
|
mobile_scanner:
|
||||||
:path: ".symlinks/plugins/mobile_scanner/ios"
|
:path: ".symlinks/plugins/mobile_scanner/ios"
|
||||||
no_screenshot:
|
|
||||||
:path: ".symlinks/plugins/no_screenshot/ios"
|
|
||||||
printing:
|
printing:
|
||||||
:path: ".symlinks/plugins/printing/ios"
|
:path: ".symlinks/plugins/printing/ios"
|
||||||
shared_preferences_foundation:
|
shared_preferences_foundation:
|
||||||
@@ -208,10 +200,8 @@ SPEC CHECKSUMS:
|
|||||||
MLKitVision: 45e79d68845a2de77e2dd4d7f07947f0ed157b0e
|
MLKitVision: 45e79d68845a2de77e2dd4d7f07947f0ed157b0e
|
||||||
mobile_scanner: af8f71879eaba2bbcb4d86c6a462c3c0e7f23036
|
mobile_scanner: af8f71879eaba2bbcb4d86c6a462c3c0e7f23036
|
||||||
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
|
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
|
||||||
no_screenshot: 6d183496405a3ab709a67a54e5cd0f639e94729e
|
|
||||||
printing: 54ff03f28fe9ba3aa93358afb80a8595a071dd07
|
printing: 54ff03f28fe9ba3aa93358afb80a8595a071dd07
|
||||||
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
|
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
|
||||||
ScreenProtectorKit: 83a6281b02c7a5902ee6eac4f5045f674e902ae4
|
|
||||||
SDWebImage: 73c6079366fea25fa4bb9640d5fb58f0893facd8
|
SDWebImage: 73c6079366fea25fa4bb9640d5fb58f0893facd8
|
||||||
shared_preferences_foundation: 9e1978ff2562383bd5676f64ec4e9aa8fa06a6f7
|
shared_preferences_foundation: 9e1978ff2562383bd5676f64ec4e9aa8fa06a6f7
|
||||||
SwiftyGif: 706c60cf65fa2bc5ee0313beece843c8eb8194d4
|
SwiftyGif: 706c60cf65fa2bc5ee0313beece843c8eb8194d4
|
||||||
|
|||||||
@@ -28,6 +28,10 @@ class MihApp extends StatefulWidget {
|
|||||||
class _MihAppState extends State<MihApp> {
|
class _MihAppState extends State<MihApp> {
|
||||||
late PageController _pageController;
|
late PageController _pageController;
|
||||||
|
|
||||||
|
void unfocusAll() {
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void dispose() {
|
void dispose() {
|
||||||
super.dispose();
|
super.dispose();
|
||||||
@@ -55,69 +59,72 @@ class _MihAppState extends State<MihApp> {
|
|||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
Size screenSize = MediaQuery.of(context).size;
|
Size screenSize = MediaQuery.of(context).size;
|
||||||
return Scaffold(
|
return GestureDetector(
|
||||||
drawer: widget.actionDrawer,
|
onTap: unfocusAll,
|
||||||
body: SafeArea(
|
child: Scaffold(
|
||||||
child: Container(
|
drawer: widget.actionDrawer,
|
||||||
width: screenSize.width,
|
body: SafeArea(
|
||||||
height: screenSize.height,
|
child: Container(
|
||||||
//color: Colors.black,
|
width: screenSize.width,
|
||||||
padding: const EdgeInsets.only(top: 5),
|
height: screenSize.height,
|
||||||
child: Column(
|
//color: Colors.black,
|
||||||
children: [
|
padding: const EdgeInsets.only(top: 5),
|
||||||
Row(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
children: [
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
Row(
|
||||||
children: [
|
mainAxisSize: MainAxisSize.min,
|
||||||
widget.appActionButton,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
Flexible(child: widget.appTools),
|
children: [
|
||||||
],
|
widget.appActionButton,
|
||||||
),
|
Flexible(child: widget.appTools),
|
||||||
Expanded(
|
],
|
||||||
child: PageView.builder(
|
|
||||||
controller: _pageController,
|
|
||||||
itemCount: widget.appBody.length,
|
|
||||||
itemBuilder: (context, index) {
|
|
||||||
return widget.appBody[index];
|
|
||||||
},
|
|
||||||
onPageChanged: (index) {
|
|
||||||
setState(() {
|
|
||||||
widget.selectedbodyIndex = index;
|
|
||||||
widget.onIndexChange(widget.selectedbodyIndex);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
),
|
),
|
||||||
),
|
Expanded(
|
||||||
// Expanded(
|
child: PageView.builder(
|
||||||
// child: SwipeDetector(
|
controller: _pageController,
|
||||||
// onSwipeLeft: (offset) {
|
itemCount: widget.appBody.length,
|
||||||
// if (widget.selectedbodyIndex <
|
itemBuilder: (context, index) {
|
||||||
// widget.appTools.tools.length - 1) {
|
return widget.appBody[index];
|
||||||
// setState(() {
|
},
|
||||||
// widget.selectedbodyIndex += 1;
|
onPageChanged: (index) {
|
||||||
// widget.onIndexChange(widget.selectedbodyIndex);
|
setState(() {
|
||||||
// });
|
widget.selectedbodyIndex = index;
|
||||||
// }
|
widget.onIndexChange(widget.selectedbodyIndex);
|
||||||
// // print("swipe left");
|
});
|
||||||
// },
|
},
|
||||||
// onSwipeRight: (offset) {
|
),
|
||||||
// if (widget.selectedbodyIndex > 0) {
|
),
|
||||||
// setState(() {
|
// Expanded(
|
||||||
// widget.selectedbodyIndex -= 1;
|
// child: SwipeDetector(
|
||||||
// widget.onIndexChange(widget.selectedbodyIndex);
|
// onSwipeLeft: (offset) {
|
||||||
// });
|
// if (widget.selectedbodyIndex <
|
||||||
// }
|
// widget.appTools.tools.length - 1) {
|
||||||
// // print("swipe right");
|
// setState(() {
|
||||||
// },
|
// widget.selectedbodyIndex += 1;
|
||||||
// child: Row(
|
// widget.onIndexChange(widget.selectedbodyIndex);
|
||||||
// children: [
|
// });
|
||||||
// Expanded(
|
// }
|
||||||
// child: widget.appBody[widget.selectedbodyIndex],
|
// // print("swipe left");
|
||||||
// )
|
// },
|
||||||
// ],
|
// onSwipeRight: (offset) {
|
||||||
// ),
|
// if (widget.selectedbodyIndex > 0) {
|
||||||
// )),
|
// setState(() {
|
||||||
],
|
// widget.selectedbodyIndex -= 1;
|
||||||
|
// widget.onIndexChange(widget.selectedbodyIndex);
|
||||||
|
// });
|
||||||
|
// }
|
||||||
|
// // print("swipe right");
|
||||||
|
// },
|
||||||
|
// child: Row(
|
||||||
|
// children: [
|
||||||
|
// Expanded(
|
||||||
|
// child: widget.appBody[widget.selectedbodyIndex],
|
||||||
|
// )
|
||||||
|
// ],
|
||||||
|
// ),
|
||||||
|
// )),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -50,6 +50,7 @@ class _AboutMihState extends State<AboutMih> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -40,6 +40,7 @@ class _MihAccessState extends State<MihAccess> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ class _MIHCalculatorState extends State<MIHCalculator> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ class _MzansiCalendarState extends State<MzansiCalendar> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ class _MzansiAiState extends State<MzansiAi> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ class _MzansiBusinessProfileState extends State<MzansiBusinessProfile> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ class _MzansiProfileState extends State<MzansiProfile> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -49,6 +49,7 @@ class _MihWalletState extends State<MihWallet> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -48,6 +48,7 @@ class _PatManagerState extends State<PatManager> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,6 +42,7 @@ class _PatientProfileState extends State<PatientProfile> {
|
|||||||
iconSize: 35,
|
iconSize: 35,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.of(context).pop();
|
Navigator.of(context).pop();
|
||||||
|
FocusScope.of(context).unfocus();
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user