SHARE
TWEET

Untitled

a guest Jan 22nd, 2020 66 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Completer<GoogleMapController> _controller=Completer();
  2.   SnappingSheetController sheetController = SnappingSheetController();
  3.  void onMapCreated(controller) {
  4.     setState(() {
  5.       _controller.complete(controller);
  6.     });
  7.   }
  8.   @override
  9.   Widget build(BuildContext context) {
  10.  return SnappingSheet(grabbingHeight: 60,
  11.  sheetBelow: Container(
  12.                 color: Colors.white,
  13.                 child: GoogleMap(
  14.                   initialCameraPosition: CameraPosition(
  15.                       target: LatLng(Location.latitude, Location.longitude),
  16.                       zoom: 18),
  17. //                  markers: ,
  18.                   myLocationEnabled: true,
  19.                   onMapCreated: onMapCreated,
  20.                 ),
  21.               ),
  22.               grabbing: Container(
  23.                 height: 20,
  24.                 decoration: ShapeDecoration(
  25.                     color: Colors.amber,
  26.                     shape: RoundedRectangleBorder(
  27.                         borderRadius: BorderRadius.only(
  28.                             topLeft: Radius.circular(30),
  29.                             topRight: Radius.circular(30)))),
  30.                 padding: EdgeInsets.only(top: 10),
  31.                 child: Text(
  32.                   "See in Map",
  33.                   textAlign: TextAlign.center,
  34.                   style: TextStyle(
  35.                     fontSize: 30,
  36.                     color: Colors.white,
  37.                     fontWeight: FontWeight.bold,
  38.                   ),
  39.                 ),
  40.               ),
  41.             );
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top