WEBVTT

NOTE Confidence: 0.8568568

00:00:10.360 --> 00:00:23.360
Hi I'm David or now a senior program manager with the mobile developer tools team focused on Zalman forms in this video. I want to share with you. Some highlights of what we've been releasing over the last several months.

NOTE Confidence: 0.8505878

00:00:23.400 --> 00:00:37.740
And what we're also releasing today for you to try out, so let's dive into some of the highlights. We've been focused. A lot on quality performance. An we also have some feature work for you quality and performance are key for our mobile applications.

NOTE Confidence: 0.8494254

00:00:37.790 --> 00:00:50.690
Enabling you to have the best experience on your cross platform. Appsso.net standard 2.0 compatibility is now available, meaning you can take the salmon forms new get package bring it into your projects of that type.

NOTE Confidence: 0.8465893

00:00:50.760 --> 00:01:03.230
And you're going to go, but I also 11 has introduced several new things for us, including safe layout. An large titles as well as a few other things, so that's something that we've come up to speed with compiled bindings.

NOTE Confidence: 0.8531377

00:01:03.260 --> 00:01:18.400
Any of the performance benefit the type checking benefit of having that done for you, Accessibility improvements. Surfacing those APIs so that you can make your apps more accessible merge dictionaries, which was a great community contribution. So you can merge multiple resource dictionaries in your application.

NOTE Confidence: 0.8454415

00:01:18.530 --> 00:01:31.740
And then we also have Mako Essen Zeedijk, a preview is now available for you to try out so you can. Start taking your mobile applications, extending them to the desktop and then modify the modifying them to be more useful on a desktop application platform.

NOTE Confidence: 0.8239585

00:01:31.810 --> 00:01:47.890
And then today I want to dive more deeply into fast renderers layout compression in page and bedding in native, which gives you not only performance benefits allows you to do much more with your salmon forms applications into user you in many new ways.

NOTE Confidence: 0.8780999

00:01:47.960 --> 00:01:48.870
So let's jump in.

NOTE Confidence: 0.8009096

00:01:50.110 --> 00:02:03.440
Fast renders so if you're familiar with these informs platform render architecture. What this means is that when you ask him reforms for a button on the native platform. You're going to get a button renderer and then that native.

NOTE Confidence: 0.8592507

00:02:03.480 --> 00:02:13.960
Element so on Android for example, it's an app Compat Button, but that means that 2 views are now being inflated on Android and if we can do anything to avoid that we absolutely want to.

NOTE Confidence: 0.8762738

00:02:14.660 --> 00:02:24.000
Optimize that that whole process so with fast renders. We've refactored the render architecture to allow us to do that. So now you just get the app Compat Button.

NOTE Confidence: 0.8554692

00:02:24.750 --> 00:02:34.910
API changes So what that means is that you need to opt into this to make sure it's right for your application. This works for button image an label and you can try that today.

NOTE Confidence: 0.8588167

00:02:35.640 --> 00:02:50.280
Nation with this in the spirit of reducing you I layers. We have introduced layout compression, so let's take for example, a content page. In that content page. You have a stack layout within their you have a grid so now we're nesting our views.

NOTE Confidence: 0.8419024

00:02:50.600 --> 00:03:04.650
Then within their you have 3 labels so that's 1234 late 4 layers of hierarchy below the page layer and that's a lot of choice of the you. I tree that needs to be climbed up and down to make sure that everything is measured in laid out properly.

NOTE Confidence: 0.8510928

00:03:04.920 --> 00:03:12.880
And then to finish this off. We have a list of you So what if you didn't actually need those layout elements. You didn't need to create views for them.

NOTE Confidence: 0.8553697

00:03:13.590 --> 00:03:25.590
We do to remove them what we enabled is the ability for you, just declare them as hidden. So then you can remove them. You don't need him anymore. So now that optimizes not only how many views are created.

NOTE Confidence: 0.8709735

00:03:26.100 --> 00:03:39.300
Enables you to flatten the hierarchy of your view, so that you don't need to go all the way up for or down 4 measure. All of that out for yourself, so let's take a look at how this works in some real applications.

NOTE Confidence: 0.8445587

00:03:40.510 --> 00:03:54.500
Okay, so here I have a simple profile screen similar to something I've done for other applications and so I felt it was a good example to show off faster, Enders and layout compression, so this is an iPhone a rendering of this screen.

NOTE Confidence: 0.8594382

00:03:54.560 --> 00:04:08.260
It's got plenty of views on it, you can see the layout is a kind of interesting and so it's a fairly good example and I have the same thing running over here on Android So what I want to do is then take a look at the inspector, which I have running right here.

NOTE Confidence: 0.8652698

00:04:08.300 --> 00:04:23.770
And I've attached it to my Android emulator and if we look at this view and look at the hierarchy on the left-hand side here, you see the hierarchy of all the views. That created so like I was describing button renderer app. Compat button over on the left hand side you can.

NOTE Confidence: 0.8490527

00:04:23.860 --> 00:04:34.590
You can see how that's creating a lot of use. And if we start to turn this and you can see, there's a lot of layers that were generating so first let's enable fast renders.

NOTE Confidence: 0.8465201

00:04:35.570 --> 00:04:48.770
And see what that does for us, so in order to enable fast renders. We come down into our Android Project, which you can see over here on the side and we come into the main activity where we're initializing forms and just before we initialize forms.

NOTE Confidence: 0.850282

00:04:48.810 --> 00:05:01.580
We can use the new set flags API to pass in a string to opt into fast renders which were calling experimental this time as I described the API is changed and so it's not necessarily going to behave the same way.

NOTE Confidence: 0.8221294

00:05:01.630 --> 00:05:14.120
As the initial uh renders. We tried to do the best we could with that, but uh your mileage may vary try that out in see how you wrap behaves so we've enabled that let's rerun this application.

NOTE Confidence: 0.7852051

00:05:17.120 --> 00:05:18.500
And while that's running.

NOTE Confidence: 0.8391523

00:05:19.220 --> 00:05:26.610
Will jump over to the inspector once it launches all right and you can see that my layouts the same nothing is changed.

NOTE Confidence: 0.8751858

00:05:26.650 --> 00:05:31.510
So I'm getting all the same you elements that I had before we launch another inspector.

NOTE Confidence: 0.8435585

00:05:33.160 --> 00:05:45.240
And now if we inspect the hierarchy on the left-hand side when it comes up now. You can see that. We just get the button. Render we just get the Imagerunner just get the button render we're not getting those additional layers there.

NOTE Confidence: 0.859796

00:05:45.300 --> 00:05:58.190
And we're starting to it's a little bit hard to see but it's were starting to flatten. This you out, all right. So now let's enable layout compression to flatten this out, even further in order to do that.

NOTE Confidence: 0.8346925

00:05:58.500 --> 00:06:11.150
Let's take a look at some of the layout that I have here in my Xaml. You see that I've got my content page and then I've got a stack layout so anywhere that I have a layout that doesn't need to have a background color doesn't need to accept gestures.

NOTE Confidence: 0.8466294

00:06:11.200 --> 00:06:22.020
I'm going to enable is headless in So what is has less means is that I don't need to create a view for it and to make this easy on myself, I can toggle this on and off.

NOTE Confidence: 0.8473357

00:06:22.050 --> 00:06:32.740
There is a boolean for use layout compression up in my app class an so you can try this out easily yourself, so I'm going to enable that let's rerun.

NOTE Confidence: 0.8739716

00:06:34.300 --> 00:06:45.410
And then we'll take another look at that in the inspector now, what you want to notice is that it's still the same layout. We have not compromised our layout at all.

NOTE Confidence: 0.8569397

00:06:45.650 --> 00:07:00.380
You can notice that I do have a layer of the top that's great here. I wanted to call your attention to that. So I have an absolutely out here because it's using that gray background. I need that view to be created. So I can't make that one had less if I do. It's going to disappear. I won't get my gray background.

NOTE Confidence: 0.8769305

00:07:00.430 --> 00:07:03.340
But the layout is the same, so let's open up the inspector.

NOTE Confidence: 0.8781

00:07:05.360 --> 00:07:07.390
Flip over to our cool of you.

NOTE Confidence: 0.8599599

00:07:08.790 --> 00:07:20.990
And we can see that we have a much flatter layout. Now we've done much better, so to count these altogether. This comes from 130, you elements initially.

NOTE Confidence: 0.8238371

00:07:21.190 --> 00:07:29.760
We were able to drop it all the way down to 70, which is uh above a 40% improvement and layouts and views that need to be created.

NOTE Confidence: 0.8115042

00:07:31.220 --> 00:07:43.270
The next thing I want to dive into is paging bedding so with zero iOS Android, an with you to be pea. You have the ability to share all your csharp logic, but you're creating your you I 3 times over.

NOTE Confidence: 0.8274168

00:07:43.320 --> 00:07:59.370
So naturally what you can do is you can use them and forms to replace that whole you. I layer, but what if you don't want to what if you want to be able to use the iOS that you I layer. The Android XML files. You want to use natural native you double ups Amal.

NOTE Confidence: 0.8245184

00:07:59.420 --> 00:08:14.040
But you want to sprinkle in some shared you I or some you I that same reforms provides for you, that you want. So what you can do now is paging bedding is you can bring that into your native applications without declaring the entire you examine forms.

NOTE Confidence: 0.8781

00:08:15.090 --> 00:08:21.490
So let's take a look at how that works how you can enable that in your applications in where you might be able to benefit from that.

NOTE Confidence: 0.8475539

00:08:23.230 --> 00:08:35.970
So here on my screen. I have a weather application. A very basic looking weather application and what I want to add to it was a shared you I to be able to view history. So this is iOS on the left hand here.

NOTE Confidence: 0.8128612

00:08:36.160 --> 00:08:45.780
Are on the side of the screen and you can see that I've got my uh my forms and I'm going to show you the code in just a second and the exact same thing on Android so we can load that up.

NOTE Confidence: 0.8676665

00:08:46.450 --> 00:08:58.260
And we can look at her 2 Favourite Cities, Seattle in Saint Louis and we get our weather. So let's go into the code and I'll show you what we've got going on here so this is my.

NOTE Confidence: 0.8047953

00:08:58.290 --> 00:09:13.340
Stop this week, it full screen. This is my sample file. I have a shared whether app over here, so this is just forms you see, there's no app Samil. I'm not running a whole forms application. I just wanted to be able to share a little bit of Xaml for a single page.

NOTE Confidence: 0.8521942

00:09:13.450 --> 00:09:28.960
So that's what I've got here and then I've got a native Android application native iOS. Anna utopia application. These are not using forms other than I'm going to embed this page in them so that's what I'm in bedding. That's the history of you that you just saw.

NOTE Confidence: 0.7939286

00:09:29.620 --> 00:09:43.640
Uh so in order to enable this Andy utilized this an iOS. I can call my new history. Page, which is that page that Xaml Paige Ann. I just use the handy extension method create view controller.

NOTE Confidence: 0.8558598

00:09:43.730 --> 00:09:55.750
This returns to me a view controller just as if I had made my own you. I view controller and I can now push this on my platform navigation. Stack just like I would push any other are you a view controller and again.

NOTE Confidence: 0.8019961

00:09:56.180 --> 00:10:05.470
He is working commands a venting is working. Um all of that is working messaging centers being used to pass messages back and forth to the native platform.

NOTE Confidence: 0.7553419

00:10:06.160 --> 00:10:19.790
My interactive view same thing is happening over here on YouTube. You pee I can't run this. It's Razr as quickly as I'm running on a Mac. But uh it's the same thing happening, I have a history page.

NOTE Confidence: 0.8571855

00:10:19.840 --> 00:10:33.850
Create the framework element and now I can use that just as I would any other framework element or page that I would have created on you to be happy just to round it out here is our Android code in my main activity. I have a method for show history.

NOTE Confidence: 0.8258083

00:10:33.930 --> 00:10:46.070
Um, I do need to initialize forms before I call these things so it's a one time called that you can make an iOS. Android you'd be pea. It is optimized for this scenario, so it's not wiring up absolutely everything.

NOTE Confidence: 0.7919036

00:10:46.470 --> 00:10:58.590
Which is also benefiting us when you're running zalman forms a speed boost in here on Android? I want to fragment. So I grab my fragmentation. I create a fragment transaction and I push it to my Stu my stack to my view.

NOTE Confidence: 0.8286746

00:10:58.900 --> 00:11:16.110
I'm so just like that, I've taken a zalman forms example page. And I haven't bedded it in my native iOS. Android you to be pea. Applications I get all the functionality. I want but I do, I use. It just where I want an I don't have to use the entire zalman forms platform if I choose not to.

NOTE Confidence: 0.8672296

00:11:17.650 --> 00:11:30.400
So that's amazing, let's cover, some of the things that we currently support. So example compilations supported you get that performance benefit. You still get bindings, which is awesome, messaging centers available if you want to use it.

NOTE Confidence: 0.8485157

00:11:30.450 --> 00:11:44.780
Tennessee service if you don't already have an inversion of control container in your application. You want to use that you can and then of course, the primary thing you're going to be doing with page and bedding is you're going to be creating those native you I view controllers activity fragment's framework elements.

NOTE Confidence: 0.805123

00:11:44.830 --> 00:11:58.470
And then using them, however you wish in your native applications. We think this is an amazing functionality for you, you can now blend your yuan use it. However, you want to whether you start with the natives amariah, less Android are you to be pea.

NOTE Confidence: 0.8316486

00:11:58.630 --> 00:12:12.530
So base and your sprinkling in Sam reforms. Or maybe you have an existing examine forms application and you realize you're creating a lot of custom renders and you want to start heading the other direction, but leveraging everything you've already done. You don't want to lose any of that great work.

NOTE Confidence: 0.8781

00:12:12.560 --> 00:12:16.160
Now you can start to do all of that and benefit greatly.

NOTE Confidence: 0.859781

00:12:18.240 --> 00:12:29.990
So what do you can do today? Absolutely. Download the releases get the latest bits try it out and then you can learn even more if you had over to our blog, where we feature a lot of these great pieces.

NOTE Confidence: 0.8399142

00:12:30.060 --> 00:12:42.500
And, of course, as you're trying these things out join us on the forums. Talk to us. Let us know how things are going. Let me know how things are going because that greatly informs our road map an where we're taking things.

NOTE Confidence: 0.840297

00:12:42.560 --> 00:12:54.850
Of course continue your education on Zalman University, a lot of great content. There, a lot of great free content. There so head over there watch the self paced videos you can join some live classes and enjoy that.

NOTE Confidence: 0.8037064

00:12:55.330 --> 00:12:58.450
Uh with that I'm closing so thanks for watching.
