Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Razvoj aplikacij Metro za Windows 8

2,878 views

Published on

A presentation on how to get started with development of Metro applications for Windows 8 in C#

Published in: Technology
  • ⇒⇒⇒WRITE-MY-PAPER.net ⇐⇐⇐ has really great writers to help you get the grades you need, they are fast and do great research. Support will always contact you if there is any confusion with the requirements of your paper so they can make sure you are getting exactly what you need.
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

Razvoj aplikacij Metro za Windows 8

  1. 1. Razvoj aplikacij Metro zaWindows 8Damir Arh, Adacta d.o.o.Arhitekt programske opremeMVP – Data Platform Developmentdamir.arh@adacta.sihttp://twitter.com/@DamirArh/http://www.damirscorner.com/ Nivo 300
  2. 2. Podprta razvojna okolja JavaScript C#/VB C++ + HTML + XAML + XAML Nivo 300
  3. 3. Kaj sploh potrebujem?• Windows 8 (Consumer Preview)• Visual Studio 11 (Beta) • Express for Windows 8• Razvijalsko licenco • Veljavnost: 30 dni • Vezana na Live ID Nivo 300
  4. 4. Pa začnimo… Nivo 300
  5. 5. Mapa Common• LayoutAwarePage• RichTextColumns• BooleanNegationConverter• BooleanToVisibilityConverter• BindableBase• StandardStyles.xaml Nivo 300
  6. 6. Struktura predloge strani• Osnovna postavitev: FullScreenLandscape• VisualStateManager • FullScreenPortrait • Filled • Snapped Nivo 300
  7. 7. Delo z datotekami• Razred Windows.Storage.ApplicationData • Nastavitve • LocalSettings • RemoteSettings • Datoteke • LocalFolder • RemoteFolder • TemporaryFolder• C:UsersUsernameAppDataLocalPackages Nivo 300
  8. 8. WinRT tokovi v ogrodju .NETStorageFolder dir = ApplicationData.Current.LocalFolder;StorageFile file = await folder.GetFileAsync(filename);IInputStream inStr = await file.OpenSequentialReadAsync();Stream stream = inStr.AsStreamForRead();StorageFolder dir = ApplicationData.Current.LocalFolder;StorageFile file = await folder.GetFileAsync(filename);IRandomAccessStream rndStream = await file.OpenAsync(FileAccessMode.ReadWrite);IOutputStream outStream = rndStream.GetOutputStreamAt(0)Stream stream = outStream.AsStreamForWrite(); Nivo 300
  9. 9. AsinhronostIAsyncOperation<StorageFile> GetFileAsync(string token)Task<WebResponse> GetResponseAsync()public async Task<string> GetAsync(){ return await FileIO.ReadTextAsync(myFile);}• Kadar je trajanje daljše od 50 ms• Async/await• Dispatcher.Invoke() ni potreben Nivo 300
  10. 10. Aplikacije Metro != .NET 4.5• Prenos obstoječih aplikacij ni enostaven • WinRT (imenski prostor Windows) • Manjkajoči razredi glede na ogrodje .NET• Kaj pa novi projekti? • Knjižnica s skupno poslovno logiko • Ločeni uporabniški vmesniki Nivo 300
  11. 11. Dodatne knjižnice• Trenutno skromna izbira • MVVM Light for Windows 8 Consumer Preview • http://bit.ly/MVVMLightWin8 • Autofac Portable • http://bit.ly/AutofacPortable • Reactive Extensions v2.0 • http://bit.ly/Rx2beta • SQLite3 WinRT • http://bit.ly/SQLite3WinRT Nivo 300
  12. 12. Testiranje• Izboljšave v Visual Studiu 11 • Možnost uporabe drugih testnih ogrodij • http://bit.ly/VS11UnitTestPlugins • Podprto testiranje asinhronih metod public async Task TestMethod() != public async void TestMethod() Nivo 300
  13. 13. Nameščanje• Privzeto le aplikacije iz trgovine• Izjemi: • Razvijalska licenca • “Sideloading” • http://bit.ly/Win8Sideloading• Remote Tools for Visual Studio 11 • http://bit.ly/VS11BetaRemoteTools Nivo 300
  14. 14. Viri• Windows 8 Consumer Preview • http://bit.ly/Win8CP• Visual Studio 11 Beta • http://bit.ly/VS11beta• Dev Center – Metro Style Apps • http://bit.ly/DevCenterMetro• Metro Style App Samples • http://bit.ly/MetroAppSamples• MSDN Forums • http://bit.ly/MSDNForumsMetro Nivo 300
  15. 15. VPRAŠANJA?Po zaključku predavanja, prosimo, izpolnite vprašalnik.Vprašalniki bodo poslani na vaš e-naslov, dostopni pa bodo tudipreko profila na spletnem portalu konference www.ntk.si.Najlepša hvala! Nivo 300

×