Skip to content

Commit fdaf8b8

Browse files
author
Michael Hoffman
committed
Indent code
1 parent 290cce4 commit fdaf8b8

File tree

4 files changed

+27
-21
lines changed

4 files changed

+27
-21
lines changed

microsoft-edge/webview2/get-started/win32.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -376,12 +376,12 @@ Now to do the above, in the callback, you'll:
376376

377377
1. In `HelloWebView.cpp`, locate the following code:
378378

379-
```cpp
380-
UpdateWindow(hWnd);
381-
382-
// <-- WebView2 sample code starts here -->
383-
```
384-
379+
```cpp
380+
UpdateWindow(hWnd);
381+
382+
// <-- WebView2 sample code starts here -->
383+
```
384+
385385
1. If the following code isn't already present, paste the following code into `HelloWebView.cpp`. Paste the code in between the lines `// <-- WebView2 sample code starts here -->` and `// <-- WebView2 sample code ends here -->`:
386386
387387
```cpp

microsoft-edge/webview2/get-started/winui.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ This article covers how to set up your development tools and create an initial W
1414

1515
In this tutorial, you use the **Blank App, Packaged (WinUI in Desktop)** Visual Studio project template to create a blank WinUI 3 project. That project template uses the WindowsAppSDK, which includes the WebView2 SDK. You add a WebView2 control. You then add an address bar and logic to display a warning dialog when the user tries to navigate to a URL with an `http://` prefix.
1616

17+
![Sample app displaying the Bing website](winui-images/getting-started-bing.png)
18+
1719

1820
#### Completed project
1921

25.9 KB
Loading

microsoft-edge/webview2/samples/webview2apissample.md

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ ms.author: msedgedevrel
66
ms.topic: conceptual
77
ms.prod: microsoft-edge
88
ms.technology: webview
9-
ms.date: 04/27/2022
9+
ms.date: 07/29/2022
1010
---
1111
# Win32 sample app (WebView2APISample)
1212

@@ -42,45 +42,49 @@ For details of events and API handlers in WebView2, see [WebView2 API Reference]
4242

4343

4444
<!-- ====================================================================== -->
45-
## Step 1 - Install Visual Studio
45+
## Step 1 - Prerequisite: Install a preview channel of Microsoft Edge
4646

47-
Microsoft Visual Studio is required. Microsoft Visual Studio Code is not supported for this sample. This repo sample is a Visual Studio 2019 project.
47+
Next, make sure a preview channel of Microsoft Edge in installed, on a supported OS. Currently we recommend the latest version of the Canary channel.
4848

49-
1. If Visual Studio (minimum required version) is not already installed with C++ support, in a separate window or tab, see [Install Visual Studio](../how-to/machine-setup.md#install-visual-studio) in _Set up your Dev environment for WebView2_. Follow the steps in that section to install Visual Studio with C++ support, and then return to this page and continue the steps below.
49+
1. If a preview channel of Microsoft Edge (Beta, Dev, or Canary) is not already installed, in a separate window or tab, see [Install a preview channel of Microsoft Edge](../how-to/machine-setup.md#install-a-preview-channel-of-microsoft-edge) in _Set up your Dev environment for WebView2_. Follow the steps in that section, and then return to this page and continue the steps below.
5050

51-
If you want to use Visual Studio 2017, after you open the solution in Visual Studio 2017, change the project's Platform Toolset in **Project Properties > Configuration properties > General > Platform Toolset**.
5251

53-
To use Visual Studio 2017, you might also need to install a recent Windows SDK on your machine.
52+
<!-- ====================================================================== -->
53+
## Step 2 - Prerequisite: Install Visual Studio 2019
5454

55+
Microsoft Visual Studio is required. Microsoft Visual Studio Code is not supported for this sample. This repo sample is a Visual Studio 2019 project.
5556

56-
<!-- ====================================================================== -->
57-
## Step 2 - Install a preview channel of Microsoft Edge
57+
1. If Visual Studio 2019 (minimum required version) is not already installed with C++ support, in a separate window or tab, see [Install Visual Studio](../how-to/machine-setup.md#install-visual-studio) in _Set up your Dev environment for WebView2_. Follow the steps in that section to install Visual Studio 2019 with C++ support, and then return to this page and continue the steps below.
5858

59-
Next, make sure a preview channel of Microsoft Edge in installed, on a supported OS. Currently we recommend the latest version of the Canary channel.
59+
If you want to use Visual Studio 2017, after you open the solution in Visual Studio 2017, change the project's Platform Toolset in **Project Properties > Configuration properties > General > Platform Toolset**.
6060

61-
1. If a preview channel of Microsoft Edge (Beta, Dev, or Canary) is not already installed, in a separate window or tab, see [Install a preview channel of Microsoft Edge](../how-to/machine-setup.md#install-a-preview-channel-of-microsoft-edge) in _Set up your Dev environment for WebView2_. Follow the steps in that section, and then return to this page and continue the steps below.
61+
To use Visual Studio 2017, you might also need to install a recent Windows SDK on your machine.
6262

6363

6464
<!-- ====================================================================== -->
65-
## Step 3 - Clone or download the WebView2Samples repo
65+
## Step 3 - Clone the WebView2Samples repo
6666

67-
1. If not done already, clone or download the `WebView2Sample` repo to your local drive. In a separate window or tab, see [Download the WebView2Samples repo](../how-to/machine-setup.md#download-the-webview2samples-repo) in _Set up your Dev environment for WebView2_. Follow the steps in that section, and then return to this page and continue below.
67+
1. If not done already, clone the `WebView2Sample` repo to your local drive. In a separate window or tab, see [Download the WebView2Samples repo](../how-to/machine-setup.md#download-the-webview2samples-repo) in _Set up your Dev environment for WebView2_. Follow the steps in that section, and then return to this page and continue below.
6868

6969
1. If you previously cloned the repo, pull the latest commits to your local copy of the repo.
7070

7171

7272
<!-- ====================================================================== -->
73-
## Step 4 - Open .sln in Visual Studio
73+
## Step 4 - Open the solution in Visual Studio
7474

75-
1. On your local drive, open the `.sln` file in Visual Studio.
75+
1. On your local drive, open the `.sln` file in Visual Studio:
7676

7777
* `<your-repos-directory>/WebView2Samples/SampleApps/WebView2Samples.sln`
7878

7979
or:
8080

8181
* `<your-repos-directory>/WebView2Samples-main/SampleApps/WebView2Samples.sln`
8282

83-
Unlike some other samples, the `.sln` file is not in the sample repo directory that contains this sample's Readme. Instead, the `.sln` file for this sample is in the parent directory.
83+
The **WebView2APISample** sample and project is the main Win32 sample.
84+
85+
Unlike some other samples, there's not a dedicated `.sln` file in the sample repo directory that contains this sample's Readme. Instead, the `.sln` file for this sample (including other sample projects as well) is in the parent directory.
86+
87+
![All projects in the solution in Solution Explorer](./webview2apissample-images/all-projects-in-solution-explorer.png)
8488

8589

8690
<!-- ====================================================================== -->

0 commit comments

Comments
 (0)