building the windows 8 community app

33
#comdaybe Building the Windows 8 Community app WiPhug Bart Lannoeye & Glenn Versweyveld

Upload: bartlannoeye

Post on 28-Nov-2014

900 views

Category:

Technology


2 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Building the windows 8 community app

#comdaybe

Building the Windows 8 Community app

WiPhugBart Lannoeye & Glenn

Versweyveld

Page 2: Building the windows 8 community app

Who are we?

Bart [email protected]/blogGlenn [email protected]

Page 3: Building the windows 8 community app

Agenda

• The Windows 8 Community App• The basic frame of your app• Content first• Layout & branding & some good

practices• Q&A

Page 4: Building the windows 8 community app

The Win8 Community App

Page 5: Building the windows 8 community app

Why this app?

• So many communities with their events

• Windows 8 = hot topic• Idea sprung as topic for Win8

hackaton• We know XAML (as WP7 devs)• #sharingiscaring

Page 6: Building the windows 8 community app

demoWhat did we build so far

The Win8 Community App

Page 7: Building the windows 8 community app

Build your (first) Win8 app

The basics

Page 8: Building the windows 8 community app

Using MVVM (Light)

• Get the NuGet for MVVM Light• Add your ViewModel registrations in

ViewModelLocator• Set ViewModelLocator in App.xaml• Bind View DataContext to your

ViewModel

Page 9: Building the windows 8 community app

Content firstData is the start of everything

Page 10: Building the windows 8 community app

Complex (cyclic) data model

Usergroup

Event

Session

SpeakerLocation*

*

* *

*

**

1

1

*

Page 11: Building the windows 8 community app

Our approach on data

• Lazy loading–Base object contains enough for

tiles–Full object for the detail page

• REST Api

Page 12: Building the windows 8 community app

demoWalking through the REST API

The data behind our app

Page 13: Building the windows 8 community app

Consuming the REST API

• Async !• Consider an extended

splashscreen• Lazy loading? Careful with

references !• Json.net vs built-in Json library

Page 14: Building the windows 8 community app

demoConsuming the REST Api

The data behind our app

Page 15: Building the windows 8 community app

Build your (first) Win8 app

Styling & branding

Page 16: Building the windows 8 community app

Styling & branding

• Personalize your app !• Use VS app template• There will be a Common folder

with StandardStyles.xaml• We derived our own from those

StandardStyles

Page 17: Building the windows 8 community app

demoBing Maps

Styling, branding & practices

Page 18: Building the windows 8 community app

Bing Maps

• Install Bing Maps SDK for Metro• Get a Bing Maps key & put it in

App.xaml• Add references• Choose a Platform!–ARM, x86 or x64 > Not Any CPU

Page 19: Building the windows 8 community app

demoImage manipulation

Styling, branding & practices

Page 20: Building the windows 8 community app

Image manipulation

• Get WriteableBitmapEx lib• Use FromStream method to get

image from Url• Use Blit method for image

manipulation• Remark – Blue shade in current

release

Page 21: Building the windows 8 community app

demoFlyout control

Styling, branding & practices

Page 22: Building the windows 8 community app

Flyout in XAML

Page 23: Building the windows 8 community app

Flyout in XAML

• Get Callisto library• Add event to a control to trigger

Flyout• In code set Placement where you

need it on the page• Add controls you like

Page 24: Building the windows 8 community app

Build your (first) Win8 app

Some good practices

Page 25: Building the windows 8 community app

Integrate with charms

• Windows 8 provides charms, use them

• Share contract• Search contract• Settings

Page 26: Building the windows 8 community app

Share charms

• ShareManager class– Initialize in code behind of view– Initialize in ViewModel

• ShareDate class–Use to share content given from

ViewModel

Page 27: Building the windows 8 community app

demoShare contract

Styling, branding & practices

Page 28: Building the windows 8 community app

Use resources

• Localization (worldwide market)• Leverage resources for scaling• XAML binding to resources

Page 29: Building the windows 8 community app

demoResources

Styling, branding & practices

Page 30: Building the windows 8 community app

Takeaways

• Content = Chrome !• Style & brand your app• Stick to the Design guidlines• Integrate with the Charms• Have fun !

Page 32: Building the windows 8 community app

Q&A

Page 33: Building the windows 8 community app

Thank you!Building the Windows 8 Community app