Glimpse of iOS developers on flutter Part 2

Glimpse of iOS developers on flutter Part 2

  • View Controllers – In iOS, a ViewController is something which represents a bit of UI i.e user interface, which is commonly mostly used for a screen. These are basically possessed together to frame difficult user interfaces, and to help you to map your application’s UI. Whereas in Flutter, this is basically done by the Widgets, UI screens in Flutter are basically represented by the Widgets since in flutter everything is a widget.

 

glimpse of ios developers on flutter part 2
glimpse of ios developers on flutter part 2

 

•  Gestures Detections and click listeners-

In iOS, an GestureRecognizer is attatched to a UIview to handle different click events. In Flutter, there are basically two ways to add touch listeners which are mentioned below:

  1. In the first case you will have to check if the widget is backing up event detection, then pass a function to it, and accordingly then handle the different events in the suitable function. Check on to the example mentioned below to get more clarity.

Example: @override

Widget build(BuildContext context) {

return new RaisedButton(

onPressed: () {

print(“click”);

},

child: new Text(“Button”),

);

}

  1. Second is the case in which the Widget does not support the detection of the events, so then you will have to go for the alternative i.e wrap the widget in a Gesture Detector and then pass a function accordingly to the onTap parameter. Check the example for the more clarity.

Example: class SampleApp extends StatelessWidget {

@override

Widget build(BuildContext context) {

return new Scaffold(

body: new Center(

child: new GestureDetector(

child: new FlutterLogo(

size: 200.0,),

onTap: () {print(“tap”);

},),),);

}

}

  • Databases and local storage– In iOS, collection of key-value pairs is stored using a property called list, also known as the User Defaults. Whereas in Flutter, you will have to access equivalent functionality using the Shared Preferences Plugins. This plugin is basically used to wrap the functionality of both the User Defaults and the Android equivalent, Shared Preferences.
  • NotificationsIn iOS, first you need to register your application on the developer portal to allow it push the various notifications. Whereas In Flutter, you can easily have the access this functionality using the firebase messaging

—————————————————————————————————————-

 

 

 

 

37 thoughts on “  Glimpse of iOS developers on flutter Part 2

Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Youre so cool! I dont suppose Ive read anything like this before. So good to search out somebody with some original thoughts on this subject. realy thanks for starting this up. this web site is something that is needed on the net, somebody with a bit originality. useful job for bringing one thing new to the internet!

  2. Hi, Neat post. There’s a problem together with your web site in internet explorer, may test this… IE nonetheless is the market leader and a large element of other folks will miss your wonderful writing because of this problem.

  3. I have been surfing online more than 3 hours today, yet I never found any interesting article like yours. It is pretty worth enough for me. In my opinion, if all webmasters and bloggers made good content as you did, the internet will be a lot more useful than ever before.

  4. I¡¦ve been exploring for a little bit for any high quality articles or weblog posts on this kind of space . Exploring in Yahoo I ultimately stumbled upon this website. Reading this info So i¡¦m satisfied to express that I have an incredibly just right uncanny feeling I discovered just what I needed. I so much unquestionably will make certain to don¡¦t disregard this web site and provides it a glance on a relentless basis.

  5. Hello there, just became alert to your blog through Google, and found that it is truly informative. I’m gonna watch out for brussels. I’ll appreciate if you continue this in future. A lot of people will be benefited from your writing. Cheers!

  6. Hi, Neat post. There is an issue along with your site in internet explorer, might check this¡K IE nonetheless is the market leader and a big element of people will leave out your magnificent writing due to this problem.

  7. Have you ever considered writing an ebook or guest authoring on other websites? I have a blog centered on the same information you discuss and would love to have you share some stories/information. I know my subscribers would appreciate your work. If you’re even remotely interested, feel free to send me an e-mail.

  8. I simply want to say I’m newbie to blogging and certainly savored your web site. Almost certainly I’m want to bookmark your blog post . You surely come with fabulous well written articles. With thanks for sharing with us your blog.

  9. I am not sure where you’re getting your information, but great topic. I needs to spend some time learning much more or understanding more. Thanks for great info I was looking for this information for my mission.

  10. It was a excitement getting to your site recently. I came up here right now hoping to find out interesting things. I was not dissatisfied. Your ideas upon new methods on this topic were insightful and a fantastic help to me. Thank you for creating time to create these things plus for sharing your thoughts.

  11. This is really interesting, You are a very skilled blogger. I have joined your rss feed and look forward to seeking more of your magnificent post. Also, I have shared your website in my social networks!

  12. I like the helpful info you provide in your articles. I’ll bookmark your blog and check again here frequently. I’m quite certain I’ll learn lots of new stuff right here! Best of luck for the next!

  13. You actually make it seem so easy with your presentation but I find this topic to be actually something which I think I would never understand. It seems too complex and extremely broad for me. I am looking forward for your next post, I will try to get the hang of it!

  14. Nice post. I was checking constantly this blog and I’m impressed! Very useful information specially the last part 🙂 I care for such information much. I was seeking this particular information for a very long time. Thank you and good luck.

  15. Wow! This can be one particular of the most useful blogs We’ve ever arrive across on this subject. Actually Magnificent. I am also a specialist in this topic therefore I can understand your effort.

Please wait...

Subscribe to our newsletter

Want to be notified when our article is published? Enter your email address and name below to be the first to know.