diff --git a/windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs b/windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs index 2b2fa52e5f..32b2ba747e 100644 --- a/windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs +++ b/windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs @@ -125,7 +125,7 @@ async void OnDeferredImageRequestedHandler(DataProviderRequest request) } } // - // + // protected override void OnNavigatedTo(NavigationEventArgs e) { } diff --git a/windows.applicationmodel.datatransfer/datapackage_resourcemap.md b/windows.applicationmodel.datatransfer/datapackage_resourcemap.md index e2897092d8..6cbb418718 100644 --- a/windows.applicationmodel.datatransfer/datapackage_resourcemap.md +++ b/windows.applicationmodel.datatransfer/datapackage_resourcemap.md @@ -21,7 +21,7 @@ HTML content often contains references to other files. The most common example i ## -examples -[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml)] +[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml_CS)] [!code-js[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/javascript/js/ShareHtml.js#SnippetHowToShareHtml)] diff --git a/windows.applicationmodel.datatransfer/datapackage_setdataprovider_375548563.md b/windows.applicationmodel.datatransfer/datapackage_setdataprovider_375548563.md index 53d8efacab..8cebd6af70 100644 --- a/windows.applicationmodel.datatransfer/datapackage_setdataprovider_375548563.md +++ b/windows.applicationmodel.datatransfer/datapackage_setdataprovider_375548563.md @@ -33,7 +33,7 @@ The **SetDataProvider** method is different from the [GetDeferral](datarequest_g ## -examples -[!code-cs[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs#SnippetHowToShareFiles)] +[!code-cs[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs#SnippetHowToShareFiles_CS)] [!code-js[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/javascript/js/ShareFiles.js#SnippetHowToShareFiles)] diff --git a/windows.applicationmodel.datatransfer/datapackage_sethtmlformat_1162235403.md b/windows.applicationmodel.datatransfer/datapackage_sethtmlformat_1162235403.md index 7b6057d635..ca84be69f7 100644 --- a/windows.applicationmodel.datatransfer/datapackage_sethtmlformat_1162235403.md +++ b/windows.applicationmodel.datatransfer/datapackage_sethtmlformat_1162235403.md @@ -24,7 +24,7 @@ If your app supports selection or copying/pasting of HTML content that contains ## -examples -[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml)] +[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml_CS)] [!code-js[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/javascript/js/ShareHtml.js#SnippetHowToShareHtml)] diff --git a/windows.applicationmodel.datatransfer/htmlformathelper_createhtmlformat_180504809.md b/windows.applicationmodel.datatransfer/htmlformathelper_createhtmlformat_180504809.md index fca6aa54d1..a4309c9a47 100644 --- a/windows.applicationmodel.datatransfer/htmlformathelper_createhtmlformat_180504809.md +++ b/windows.applicationmodel.datatransfer/htmlformathelper_createhtmlformat_180504809.md @@ -24,7 +24,7 @@ A string representing the formatted HTML. ## -examples -[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml)] +[!code-cs[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareHTML.xaml.cs#SnippetHowToShareHtml_CS)] [!code-js[HowToShareHtml](../windows.applicationmodel.datatransfer/code/ShareMainBeta/javascript/js/ShareHtml.js#SnippetHowToShareHtml)] diff --git a/windows.applicationmodel.datatransfer/standarddataformats_storageitems.md b/windows.applicationmodel.datatransfer/standarddataformats_storageitems.md index 55c7049bdd..69c12618c5 100644 --- a/windows.applicationmodel.datatransfer/standarddataformats_storageitems.md +++ b/windows.applicationmodel.datatransfer/standarddataformats_storageitems.md @@ -22,7 +22,7 @@ This example demonstrates the use of the **StorageItems** property. To use the c -[!code-cs[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs#SnippetHowToShareFiles)] +[!code-cs[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/cs/ShareFiles.xaml.cs#SnippetHowToShareFiles_CS)] [!code-js[HowToShareFiles](../windows.applicationmodel.datatransfer/code/ShareMainBeta/javascript/js/ShareFiles.js#SnippetHowToShareFiles)] diff --git a/windows.devices.pointofservice/code/BarcodeScanner/cpp/Scenario1.xaml.cpp b/windows.devices.pointofservice/code/BarcodeScanner/cpp/Scenario1.xaml.cpp index 6ecfc2ba2f..ae1175ca77 100644 --- a/windows.devices.pointofservice/code/BarcodeScanner/cpp/Scenario1.xaml.cpp +++ b/windows.devices.pointofservice/code/BarcodeScanner/cpp/Scenario1.xaml.cpp @@ -141,7 +141,7 @@ void Scenario1::ScenarioStartScanButton_Click(Platform::Object^ sender, Windows: } // -/ + /// /// Event handler for the Release Device Requested event fired when barcode scanner receives Claim request from another application diff --git a/windows.devices.wifidirect/wifidirectdevice.md b/windows.devices.wifidirect/wifidirectdevice.md index 5e27d7cdd4..1ae2b96026 100644 --- a/windows.devices.wifidirect/wifidirectdevice.md +++ b/windows.devices.wifidirect/wifidirectdevice.md @@ -26,8 +26,6 @@ You must enable the **Proximity** capability to communicate with Wi-Fi Direct de [!code-cs[2](../windows.devices.wifidirect/code/WiFiDirect_Device/cs/MainPage.xaml.cs#Snippet2)] -[!code-js[2](../windows.devices.wifidirect/code/WiFiDirect_Device/js/default.js#Snippet2)] - [!code-js[2_JS](../windows.devices.wifidirect/code/WiFiDirect_Device/js/default.js#Snippet2_JS)] ## -see-also diff --git a/windows.media.capture/mediacapture.md b/windows.media.capture/mediacapture.md index b87bbf61a1..fd664a6a24 100644 --- a/windows.media.capture/mediacapture.md +++ b/windows.media.capture/mediacapture.md @@ -56,7 +56,7 @@ The following code sample shows how to create and initialize a **MediaCapture** -[!code-cs[MediaCaptureVideo_InitMCobject](../windows.media.capture/code/MediaCaptureVideo/csharp/MainPage.xaml.cs#SnippetMediaCaptureVideo_InitMCobject)] +[!code-cs[MediaCaptureVideo_InitMCobject](../windows.media.capture/code/MediaCaptureVideo/csharp/MainPage.xaml.cs#SnippetMediaCaptureVideo_InitMCobjectCS)] [!code-js[MediaCaptureVideo_InitMCobject](../windows.media.capture/code/MediaCaptureVideo/javascript/default.js#SnippetMediaCaptureVideo_InitMCobject)] diff --git a/windows.media.capture/mediacaptureinitializationsettings.md b/windows.media.capture/mediacaptureinitializationsettings.md index 99566445b7..ea16d23f34 100644 --- a/windows.media.capture/mediacaptureinitializationsettings.md +++ b/windows.media.capture/mediacaptureinitializationsettings.md @@ -20,7 +20,7 @@ The following example initializes the **MediaCaptureInitializationSettings**. Ca -[!code-cs[MediaCaptureVideo_InitSettings](../windows.media.capture/code/MediaCaptureVideo/csharp/MainPage.xaml.cs#SnippetMediaCaptureVideo_InitSettings)] +[!code-cs[MediaCaptureVideo_InitSettings](../windows.media.capture/code/MediaCaptureVideo/csharp/MainPage.xaml.cs#SnippetMediaCaptureVideo_InitSettingsCS)] [!code-js[MediaCaptureVideo_InitSettings](../windows.media.capture/code/MediaCaptureVideo/javascript/default.js#SnippetMediaCaptureVideo_InitSettings)] diff --git a/windows.media.playto/playtosource.md b/windows.media.playto/playtosource.md index 64457448d3..09094ba378 100644 --- a/windows.media.playto/playtosource.md +++ b/windows.media.playto/playtosource.md @@ -19,13 +19,13 @@ For an example of using the [PlayToSource](playtosource.md) class, see [Streamin ## -examples -[!code-cs[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetSlideShow)] +[!code-cs[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetSlideShow_CS)] [!code-js[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/javascript/default.js#SnippetSlideShow)] -[!code-vb[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetSlideShow)] +[!code-vb[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetSlideShow_CS)] -[!code-cs[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetPlayToContract)] +[!code-cs[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetPlayToContract_CS)] [!code-js[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/javascript/default.js#SnippetPlayToContract)] diff --git a/windows.media.playto/playtosource_next.md b/windows.media.playto/playtosource_next.md index fcb75c2910..a394a021ff 100644 --- a/windows.media.playto/playtosource_next.md +++ b/windows.media.playto/playtosource_next.md @@ -22,11 +22,11 @@ For an example of using the [Next](playtosource_next.md) property, see [Streamin ## -examples -[!code-cs[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetPlayToContract)] +[!code-cs[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetPlayToContract_CS)] [!code-js[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/javascript/default.js#SnippetPlayToContract)] -[!code-vb[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetPlayToContract)] +[!code-vb[PlayToContract](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetPlayToContract_CS)] ## -see-also [Play To sample](http://go.microsoft.com/fwlink/p/?linkid=245166), [PlayToReceiver sample](http://go.microsoft.com/fwlink/p/?linkid=245167), [Media Server sample](http://go.microsoft.com/fwlink/p/?linkid=245168) diff --git a/windows.media.playto/playtosource_playnext_1668020201.md b/windows.media.playto/playtosource_playnext_1668020201.md index e7a0d29c91..e1d080e024 100644 --- a/windows.media.playto/playtosource_playnext_1668020201.md +++ b/windows.media.playto/playtosource_playnext_1668020201.md @@ -21,11 +21,11 @@ For an example of using the [Next](playtosource_next.md) property, see [Streamin ## -examples -[!code-cs[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetSlideShow)] +[!code-cs[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/csharp/MainPage.xaml.cs#SnippetSlideShow_CS)] [!code-js[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/javascript/default.js#SnippetSlideShow)] -[!code-vb[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetSlideShow)] +[!code-vb[SlideShow](../windows.media.playto/code/PlayTo_SlideShow1/vbnet/MainPage.xaml.vb#SnippetSlideShow_CS)] ## -see-also [Play To sample](http://go.microsoft.com/fwlink/p/?linkid=245166), [PlayToReceiver sample](http://go.microsoft.com/fwlink/p/?linkid=245167), [Media Server sample](http://go.microsoft.com/fwlink/p/?linkid=245168) diff --git a/windows.networking.proximity/peerfinder_createwatcher_1506431823.md b/windows.networking.proximity/peerfinder_createwatcher_1506431823.md index 8f95a0149d..7b4bba0c44 100644 --- a/windows.networking.proximity/peerfinder_createwatcher_1506431823.md +++ b/windows.networking.proximity/peerfinder_createwatcher_1506431823.md @@ -24,8 +24,6 @@ If you call the [CreateWatcher](peerfinder_createwatcher.md) method multiple tim [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] - [!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] ## -examples diff --git a/windows.networking.proximity/peerfinder_discoverydata.md b/windows.networking.proximity/peerfinder_discoverydata.md index 6b3b534ec2..70066df9b4 100644 --- a/windows.networking.proximity/peerfinder_discoverydata.md +++ b/windows.networking.proximity/peerfinder_discoverydata.md @@ -23,7 +23,6 @@ User or device data to include during device discovery. Must be less than 32 byt [!code-cs[PeerRole_CS](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole_CS)] -[!code-cs[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole)] [!code-js[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/js/peerrole.js#SnippetPeerRole)] diff --git a/windows.networking.proximity/peerfinder_role.md b/windows.networking.proximity/peerfinder_role.md index fd768ae71e..d507b9a90f 100644 --- a/windows.networking.proximity/peerfinder_role.md +++ b/windows.networking.proximity/peerfinder_role.md @@ -25,7 +25,6 @@ In a multi-peer app scenario, the Role identifies the capability of the apps to [!code-cs[PeerRole_CS](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole_CS)] -[!code-cs[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole)] [!code-js[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/js/peerrole.js#SnippetPeerRole)] diff --git a/windows.networking.proximity/peerrole.md b/windows.networking.proximity/peerrole.md index e0982554ca..65b1862bae 100644 --- a/windows.networking.proximity/peerrole.md +++ b/windows.networking.proximity/peerrole.md @@ -33,8 +33,6 @@ In a multi-peer app scenario, the Role identifies the capability of the apps to [!code-cs[PeerRole_CS](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole_CS)] -[!code-cs[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/csharp/PeerRole.xaml.cs#SnippetPeerRole)] - [!code-js[PeerRole](../windows.networking.proximity/code/Proximity_FindAllPeersAsync1/js/peerrole.js#SnippetPeerRole)] ## -see-also diff --git a/windows.networking.proximity/peerwatcher.md b/windows.networking.proximity/peerwatcher.md index f5d9ea9861..5a726b7433 100644 --- a/windows.networking.proximity/peerwatcher.md +++ b/windows.networking.proximity/peerwatcher.md @@ -26,7 +26,6 @@ To create an instance of the [PeerWatcher](peerwatcher.md) class, call the [Peer [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] [!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] diff --git a/windows.networking.proximity/peerwatcher_added.md b/windows.networking.proximity/peerwatcher_added.md index ca17be8717..f8d374d0c6 100644 --- a/windows.networking.proximity/peerwatcher_added.md +++ b/windows.networking.proximity/peerwatcher_added.md @@ -24,13 +24,13 @@ After you start the [PeerWatcher](peerwatcher.md)by calling the [Start](peerfind [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_PeerWatcherAdded](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_PeerWatcherAdded)] -[!code-js[_PeerWatcherAdded](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherAdded)] +[!code-js[_PeerWatcherAdded](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherAdded_JS)] + -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-js[_PeerWatcherAdded_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherAdded_JS)] diff --git a/windows.networking.proximity/peerwatcher_enumerationcompleted.md b/windows.networking.proximity/peerwatcher_enumerationcompleted.md index c635656335..ce9328ffe0 100644 --- a/windows.networking.proximity/peerwatcher_enumerationcompleted.md +++ b/windows.networking.proximity/peerwatcher_enumerationcompleted.md @@ -24,13 +24,10 @@ Occurs after a scan operation is complete and all peer apps within wireless rang [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_PeerWatcherEnumerationCompleted](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_PeerWatcherEnumerationCompleted)] -[!code-js[_PeerWatcherEnumerationCompleted](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherEnumerationCompleted)] - -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-js[_PeerWatcherEnumerationCompleted_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherEnumerationCompleted_JS)] diff --git a/windows.networking.proximity/peerwatcher_removed.md b/windows.networking.proximity/peerwatcher_removed.md index c2731fbf00..fbdf68a00d 100644 --- a/windows.networking.proximity/peerwatcher_removed.md +++ b/windows.networking.proximity/peerwatcher_removed.md @@ -21,14 +21,10 @@ The [Removed](peerwatcher_removed.md) event is raised when a peer app is removed [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_PeerWatcherRemoved](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_PeerWatcherRemoved)] -[!code-js[_PeerWatcherRemoved](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherRemoved)] - -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] - [!code-js[_PeerWatcherRemoved_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherRemoved_JS)] ## -examples diff --git a/windows.networking.proximity/peerwatcher_start_1587696324.md b/windows.networking.proximity/peerwatcher_start_1587696324.md index 62bb90b840..7f1bbbc0b9 100644 --- a/windows.networking.proximity/peerwatcher_start_1587696324.md +++ b/windows.networking.proximity/peerwatcher_start_1587696324.md @@ -25,8 +25,6 @@ You can use the [Status](peerwatcher_status.md) property to determine the status [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] - [!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] ## -examples diff --git a/windows.networking.proximity/peerwatcher_stop_1201535524.md b/windows.networking.proximity/peerwatcher_stop_1201535524.md index 7a83557306..33c3f0f6ff 100644 --- a/windows.networking.proximity/peerwatcher_stop_1201535524.md +++ b/windows.networking.proximity/peerwatcher_stop_1201535524.md @@ -19,13 +19,13 @@ Stop dynamically searching for peer apps within wireless range. [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_StopPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StopPeerWatcher)] [!code-js[_StopPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StopPeerWatcher)] -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] + [!code-js[_StopPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StopPeerWatcher_JS)] diff --git a/windows.networking.proximity/peerwatcher_stopped.md b/windows.networking.proximity/peerwatcher_stopped.md index fa075a5e11..7958e72658 100644 --- a/windows.networking.proximity/peerwatcher_stopped.md +++ b/windows.networking.proximity/peerwatcher_stopped.md @@ -21,14 +21,10 @@ You can call the [Stop](peerwatcher_stop.md) method to stop the [PeerWatcher](pe [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_PeerWatcherStopped](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_PeerWatcherStopped)] -[!code-js[_PeerWatcherStopped](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherStopped)] - -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] - [!code-js[_PeerWatcherStopped_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherStopped_JS)] ## -examples diff --git a/windows.networking.proximity/peerwatcher_updated.md b/windows.networking.proximity/peerwatcher_updated.md index 4383c4d5bc..aabdd6b16e 100644 --- a/windows.networking.proximity/peerwatcher_updated.md +++ b/windows.networking.proximity/peerwatcher_updated.md @@ -24,14 +24,10 @@ The [Updated](peerwatcher_updated.md) event is raised when the [DisplayName](pee [!code-cs[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_StartPeerWatcher)] -[!code-js[_StartPeerWatcher](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher)] +[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] [!code-cs[_PeerWatcherUpdated](../windows.networking.proximity/code/Proximity_PeerWatcher/cs/MainPage.xaml.cs#Snippet_PeerWatcherUpdated)] -[!code-js[_PeerWatcherUpdated](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherUpdated)] - -[!code-js[_StartPeerWatcher_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_StartPeerWatcher_JS)] - [!code-js[_PeerWatcherUpdated_JS](../windows.networking.proximity/code/Proximity_PeerWatcher/js/default.js#Snippet_PeerWatcherUpdated_JS)] ## -examples diff --git a/windows.security.credentials.ui/userconsentverificationresult.md b/windows.security.credentials.ui/userconsentverificationresult.md index 4aa8a35142..9e2614838b 100644 --- a/windows.security.credentials.ui/userconsentverificationresult.md +++ b/windows.security.credentials.ui/userconsentverificationresult.md @@ -44,7 +44,6 @@ The following example shows a method that requests fingerprint verification and [!code-cs[2](../windows.security.credentials.ui/code/BiometricAuth/cs/MainPage.xaml.cs#Snippet2)] -[!code-js[2](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet2)] [!code-js[2_JS](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet2_JS)] diff --git a/windows.security.credentials.ui/userconsentverifier.md b/windows.security.credentials.ui/userconsentverifier.md index f871c2fb2b..36f43219ca 100644 --- a/windows.security.credentials.ui/userconsentverifier.md +++ b/windows.security.credentials.ui/userconsentverifier.md @@ -23,7 +23,6 @@ The following example shows a method that requests fingerprint verification and [!code-cs[2](../windows.security.credentials.ui/code/BiometricAuth/cs/MainPage.xaml.cs#Snippet2)] -[!code-js[2](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet2)] [!code-js[2_JS](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet2_JS)] diff --git a/windows.security.credentials.ui/userconsentverifieravailability.md b/windows.security.credentials.ui/userconsentverifieravailability.md index f962221ebc..416a1600ff 100644 --- a/windows.security.credentials.ui/userconsentverifieravailability.md +++ b/windows.security.credentials.ui/userconsentverifieravailability.md @@ -40,7 +40,6 @@ The following example shows a method that checks to see if fingerprint authentic [!code-cs[1](../windows.security.credentials.ui/code/BiometricAuth/cs/MainPage.xaml.cs#Snippet1)] -[!code-js[1](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet1)] [!code-js[1_JS](../windows.security.credentials.ui/code/BiometricAuth/js/default.js#Snippet1_JS)] diff --git a/windows.security.enterprisedata/filerevocationmanager_copyprotectionasync_491662270.md b/windows.security.enterprisedata/filerevocationmanager_copyprotectionasync_491662270.md index fba284e62e..225e98c3f0 100644 --- a/windows.security.enterprisedata/filerevocationmanager_copyprotectionasync_491662270.md +++ b/windows.security.enterprisedata/filerevocationmanager_copyprotectionasync_491662270.md @@ -37,8 +37,6 @@ If you save a new copy of a file as the result of a "save as" operation, the sel [!code-cs[_CopyProtection](../windows.security.enterprisedata/code/SelectiveWipeSnippets/cs/MainPage.xaml.cs#Snippet_CopyProtection)] -[!code-js[_CopyProtection](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_CopyProtection)] - [!code-js[_CopyProtection_JS](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_CopyProtection_JS)] diff --git a/windows.security.enterprisedata/filerevocationmanager_getstatusasync_872885170.md b/windows.security.enterprisedata/filerevocationmanager_getstatusasync_872885170.md index 2755fb459e..fe473ec667 100644 --- a/windows.security.enterprisedata/filerevocationmanager_getstatusasync_872885170.md +++ b/windows.security.enterprisedata/filerevocationmanager_getstatusasync_872885170.md @@ -34,11 +34,10 @@ You can use the [GetStatusAsync](filerevocationmanager_getstatusasync.md) method [!code-cs[_Global](../windows.security.enterprisedata/code/SelectiveWipeSnippets/cs/MainPage.xaml.cs#Snippet_Global)] -[!code-js[_Global](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_Global)] [!code-cs[_GetStatus](../windows.security.enterprisedata/code/SelectiveWipeSnippets/cs/MainPage.xaml.cs#Snippet_GetStatus)] -[!code-js[_GetStatus](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_GetStatus)] + diff --git a/windows.security.enterprisedata/filerevocationmanager_protectasync_1331169532.md b/windows.security.enterprisedata/filerevocationmanager_protectasync_1331169532.md index 87501adb33..9cd079d4a4 100644 --- a/windows.security.enterprisedata/filerevocationmanager_protectasync_1331169532.md +++ b/windows.security.enterprisedata/filerevocationmanager_protectasync_1331169532.md @@ -37,13 +37,9 @@ You can use the [ProtectAsync](filerevocationmanager_protectasync.md) method to [!code-cs[_Global](../windows.security.enterprisedata/code/SelectiveWipeSnippets/cs/MainPage.xaml.cs#Snippet_Global)] -[!code-js[_Global](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_Global)] [!code-cs[_Protect](../windows.security.enterprisedata/code/SelectiveWipeSnippets/cs/MainPage.xaml.cs#Snippet_Protect)] -[!code-js[_Protect](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_Protect)] - - [!code-js[_Global_JS](../windows.security.enterprisedata/code/SelectiveWipeSnippets/js/default.js#Snippet_Global_JS)] diff --git a/windows.ui.xaml.media/timelinemarker.md b/windows.ui.xaml.media/timelinemarker.md index cfb331a023..594498288b 100644 --- a/windows.ui.xaml.media/timelinemarker.md +++ b/windows.ui.xaml.media/timelinemarker.md @@ -22,7 +22,7 @@ The following example creates a [MediaElement](../windows.ui.xaml.controls/media [!code-xml[TimelineMarkerXAML](../windows.ui.xaml.media/code/MediaXamlSnippets/csharp/MainPage.xaml#SnippetTimelineMarkerXAML)] -[!code-xml[TimelineMarker](../windows.ui.xaml.media/code/MediaXamlSnippets/csharp/MainPage.xaml#SnippetTimelineMarker)] +[!code-xml[TimelineMarker](../windows.ui.xaml.media/code/MediaXamlSnippets/csharp/MainPage.xaml.cs#SnippetTimelineMarker)] ## -see-also [DependencyObject](../windows.ui.xaml/dependencyobject.md) diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml b/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml new file mode 100644 index 0000000000..60cbc7007a --- /dev/null +++ b/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml.cs b/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml.cs new file mode 100644 index 0000000000..7449ea9949 --- /dev/null +++ b/windows.ui.xaml/code/MediaXamlSnippets/csharp/App.xaml.cs @@ -0,0 +1,118 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using Windows.ApplicationModel; +using Windows.ApplicationModel.Activation; +using Windows.Foundation; +using Windows.Foundation.Collections; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; +using Windows.UI.Xaml.Data; +using Windows.UI.Xaml.Input; +using Windows.UI.Xaml.Media; +using Windows.UI.Xaml.Navigation; +using Windows.Media.Capture; +using System.Threading.Tasks; + +// The Blank Application template is documented at http://go.microsoft.com/fwlink/?LinkId=234227 + +namespace MediaXamlSnippets +{ + /// + /// Provides application-specific behavior to supplement the default Application class. + /// + sealed partial class App : Application + { + /// + /// Initializes the singleton application object. This is the first line of authored code + /// executed, and as such is the logical equivalent of main() or WinMain(). + /// + public App() + { + this.InitializeComponent(); + this.Suspending += OnSuspending; + } + + /// + /// Invoked when the application is launched normally by the end user. Other entry points + /// will be used when the application is launched to open a specific file, to display + /// search results, and so forth. + /// + /// Details about the launch request and process. + protected override void OnLaunched(LaunchActivatedEventArgs args) + { + // Do not repeat app initialization when already running, just ensure that + // the window is active + if (args.PreviousExecutionState == ApplicationExecutionState.Running) + { + Window.Current.Activate(); + return; + } + + if (args.PreviousExecutionState == ApplicationExecutionState.Terminated) + { + //TODO: Load state from previously suspended application + } + + // Create a Frame to act navigation context and navigate to the first page + var rootFrame = new Frame(); + if (!rootFrame.Navigate(typeof(MainPage))) + { + throw new Exception("Failed to create initial page"); + } + + // Place the frame in the current Window and ensure that it is active + Window.Current.Content = rootFrame; + Window.Current.Activate(); + } + + /// + /// Invoked when application execution is being suspended. Application state is saved + /// without knowing whether the application will be terminated or resumed with the contents + /// of memory still intact. + /// + /// The source of the suspend request. + /// Details about the suspend request. + + private async void OnSuspending(object sender, SuspendingEventArgs e) + { + var deferral = e.SuspendingOperation.GetDeferral(); + + //cleanup camera resources + await CleanupCaptureResources(); + + deferral.Complete(); + } + + public MediaCapture MediaCapture { get; set; } + public CaptureElement PreviewElement { get; set; } + public bool IsRecording { get; set; } + public bool IsPreviewing { get; set; } + + public async Task CleanupCaptureResources() + { + if (IsRecording && MediaCapture != null) + { + await MediaCapture.StopRecordAsync(); + IsRecording = false; + } + if (IsPreviewing && MediaCapture != null) + { + await MediaCapture.StopPreviewAsync(); + IsPreviewing = false; + } + + if (MediaCapture != null) + { + if (PreviewElement != null) + { + PreviewElement.Source = null; + } + MediaCapture.Dispose(); + } + } + + } +} diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/Logo.png b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/Logo.png new file mode 100644 index 0000000000..c559a6435c Binary files /dev/null and b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/Logo.png differ diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SmallLogo.png b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SmallLogo.png new file mode 100644 index 0000000000..0853f153a4 Binary files /dev/null and b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SmallLogo.png differ diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SplashScreen.png b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SplashScreen.png new file mode 100644 index 0000000000..e120fef4e7 Binary files /dev/null and b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/SplashScreen.png differ diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/StoreLogo.png b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/StoreLogo.png new file mode 100644 index 0000000000..3d92b51f62 Binary files /dev/null and b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Assets/StoreLogo.png differ diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/Common/StandardStyles.xaml b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Common/StandardStyles.xaml new file mode 100644 index 0000000000..81fb398ea2 --- /dev/null +++ b/windows.ui.xaml/code/MediaXamlSnippets/csharp/Common/StandardStyles.xaml @@ -0,0 +1,1007 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Mouse + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/windows.ui.xaml/code/MediaXamlSnippets/csharp/MainPage.xaml b/windows.ui.xaml/code/MediaXamlSnippets/csharp/MainPage.xaml new file mode 100644 index 0000000000..49d2982ad4 --- /dev/null +++ b/windows.ui.xaml/code/MediaXamlSnippets/csharp/MainPage.xaml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + +