Skip to content

Commit 13a31b1

Browse files
Apply suggestions from code review
Co-authored-by: David Risney <[email protected]>
1 parent c8001c1 commit 13a31b1

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

specs/DisableNavigatingBackAndForward.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ CHECK_FAILURE(m_webView->add_NavigationStarting(
3131
{
3232
COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND history_change = COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_OTHER;
3333
CHECK_FAILURE(args3->get_NavigationHistoryChange(&history_change));
34-
if (history_change != COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_OTHER) {
34+
if (history_change != COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_OTHER)
35+
{
3536
CHECK_FAILURE(args->put_Cancel(true));
3637
}
3738
}
@@ -66,19 +67,19 @@ void WebView_NavigationStarting(object sender, CoreWebView2NavigationStartingEve
6667
// Enums and structs
6768
[v1_enum]
6869
typedef enum COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND {
69-
/// go back
70+
/// Indicates a navigation that is going back to a previous entry in the navigation history. For example, a navigation caused by `CoreWebView2.GoBack` or in script `window.history.go(-1)`.
7071
COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_BACK,
71-
/// go forward
72+
/// Indicates a navigation that is going forward to a later entry in the navigation history. For example, a navigation caused by `CoreWebView2.GoForward` or in script `window.history.go(1)`.
7273
COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_FORWARD,
73-
/// other
74+
/// Indicates a navigation that is not going back or forward to an existing entry in the navigation history. For example, a navigation caused by `CoreWebView2.Navigate`, or `CoreWebView2.Reload` or in script `window.location.href = 'https://example.com/'`.
7475
COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND_OTHER,
7576
} COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND;
7677

7778
/// Extend `NavigationStartingEventArgs` by adding more information.
7879
[uuid(39A27807-2365-470B-AF28-885502121049), object, pointer_default(unique)]
7980
interface ICoreWebView2NavigationStartingEventArgs3 : ICoreWebView2NavigationStartingEventArgs2 {
8081

81-
/// Get the history change kind of the navigation
82+
/// Indicates if this navigation is going back or forward to an existing entry in the navigation history.
8283
[propget] HRESULT NavigationHistoryChange([out, retval] COREWEBVIEW2_NAVIGATION_HISTORY_CHANGE_KIND* history_change);
8384
}
8485
}

0 commit comments

Comments
 (0)