You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: hub/apps/develop/data-binding/data-binding-in-depth.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -38,15 +38,15 @@ You can use data binding to simply display values from a data source when the UI
38
38
39
39
Independent of mode, there are two kinds of binding, and you typically declare both in UI markup. You can choose to use either the [{x:Bind} markup extension](/windows/apps/develop/platform/xaml/x-bind-markup-extension) or the [{Binding} markup extension](/windows/apps/develop/platform/xaml/binding-markup-extension). You can even use a mixture of the two in the same app—even on the same UI element. `{x:Bind}` was new in UWP for Windows 10 and it has better performance. All the details described in this topic apply to both kinds of binding unless we explicitly say otherwise.
- Download the [UWP Bookstore1](https://codeload.github.com/MicrosoftDocs/windows-topic-specific-samples/zip/Bookstore1Universal_10) app.
49
+
- Download the [Bookstore1](https://codeload.github.com/MicrosoftDocs/windows-topic-specific-samples/zip/Bookstore1Universal_10) app.
50
50
- Download the [Bookstore2](https://codeload.github.com/MicrosoftDocs/windows-topic-specific-samples/zip/Bookstore2Universal_10) app.
51
51
52
52
## Every binding involves these pieces
@@ -654,7 +654,7 @@ You can bind a ListView's **DoubleTapped** event to a method in the **MainWindow
654
654
655
655
You can't use overloaded methods to handle an event with this technique. Also, if the method that handles the event has parameters, then all of them must be assignable from the types of all of the event's parameters, respectively. In this case, `ListViewDoubleTapped` isn't overloaded and it has no parameters (but it would still be valid even if it took two `object` parameters).
656
656
657
-
The event binding technique is similar to implementing and consuming commands. A command is a property that returns an object that implements the [**ICommand**](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.input.icommand) interface. Both [{x:Bind}](/windows/apps/develop/platform/xaml/x-bind-markup-extension) and [{Binding}](/windows/apps/develop/platform/xaml/binding-markup-extension) work with commands. So that you don't have to implement the command pattern multiple times, you can use the `DelegateCommand` helper class that you find in the [QuizGame](https://github.com/microsoft/Windows-appsample-networkhelper)UWP sample (in the "Common" folder).
657
+
The event binding technique is similar to implementing and consuming commands. A command is a property that returns an object that implements the [**ICommand**](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.input.icommand) interface. Both [{x:Bind}](/windows/apps/develop/platform/xaml/x-bind-markup-extension) and [{Binding}](/windows/apps/develop/platform/xaml/binding-markup-extension) work with commands. So that you don't have to implement the command pattern multiple times, you can use the `DelegateCommand` helper class that you find in the [QuizGame](https://github.com/microsoft/Windows-appsample-networkhelper) sample (in the "Common" folder).
658
658
659
659
## Binding to a collection of folders or files
660
660
@@ -776,7 +776,7 @@ Remember that when using [{x:Bind}](/windows/apps/develop/platform/xaml/x-bind-m
776
776
</GridView>
777
777
```
778
778
779
-
A [**SemanticZoom**](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.controls.semanticzoom) control is a great way for your users to view and navigate grouped data. The [Bookstore2](https://codeload.github.com/MicrosoftDocs/windows-topic-specific-samples/zip/Bookstore2Universal_10)UWP sample app illustrates how to use the `SemanticZoom`. In that app, you can view a list of books grouped by author (the zoomed-in view) or you can zoom out to see a jump list of authors (the zoomed-out view). The jump list affords much quicker navigation than scrolling through the list of books. The zoomed-in and zoomed-out views are actually `ListView` or `GridView` controls bound to the same `CollectionViewSource`.
779
+
A [**SemanticZoom**](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.controls.semanticzoom) control is a great way for your users to view and navigate grouped data. The [Bookstore2](https://codeload.github.com/MicrosoftDocs/windows-topic-specific-samples/zip/Bookstore2Universal_10) sample app illustrates how to use the `SemanticZoom`. In that app, you can view a list of books grouped by author (the zoomed-in view) or you can zoom out to see a jump list of authors (the zoomed-out view). The jump list affords much quicker navigation than scrolling through the list of books. The zoomed-in and zoomed-out views are actually `ListView` or `GridView` controls bound to the same `CollectionViewSource`.
780
780
781
781

Copy file name to clipboardExpand all lines: hub/apps/develop/devices-sensors/print-from-your-app.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -26,7 +26,7 @@ The first step to add printing to your app is to register for printing by gettin
26
26
Your app must do this on every screen from which you want your user to be able to print. Only the screen that is displayed to the user can be registered for printing. If one screen of your app has registered for printing, it must unregister for printing when it exits. If it is replaced by another screen, the next screen must register for printing when it opens.
27
27
28
28
> [!TIP]
29
-
> If you need to support printing from more than one page in your app, you can put this print code in a common helper class and have your app pages reuse it. For an example of how to do this, see the `PrintHelper` class in the [UWP print sample](https://github.com/Microsoft/Windows-universal-samples/tree/main/Samples/Printing).
29
+
> If you need to support printing from more than one page in your app, you can put this print code in a common helper class and have your app pages reuse it. For an example of how to do this, see the `PrintHelper` class in the [Print sample](https://github.com/Microsoft/Windows-universal-samples/tree/main/Samples/Printing).
30
30
31
31
After a user has initiated printing, you use a [PrintDocument](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.printing.printdocument) to prepare the pages to be sent to the printer.The `PrintDocument` type is in the [**Microsoft.UI.Xaml.Printing**](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.printing) namespace along with other types that support preparing XAML content for printing.
> In UWP printing examples, it's recommended to register for printing from the OnNavigatedTo method override. You need to use the window handle in the PrintManagerInterop.GetForWindow call, so you should use the Loaded event to ensure that the window handle is not `null`, which might be the case in OnNavigatedTo.
65
+
> In printing examples, it's recommended to register for printing from the OnNavigatedTo method override. You need to use the window handle in the PrintManagerInterop.GetForWindow call, so you should use the Loaded event to ensure that the window handle is not `null`, which might be the case in OnNavigatedTo.
66
66
67
67
Here, the event handlers are unregistered in the `UnregisterForPrinting` method, which is called from the [OnNavigatedFrom](/windows/windows-app-sdk/api/winrt/microsoft.ui.xaml.controls.page.onnavigatedfrom) method.
0 commit comments