MicrosoftEdge / MicrosoftEdge/WebView2Feedback
Context menu - Separator
Nobody has claimed this yet.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
So I am trying to insert a separator. So far I tried:
CHECK_FAILURE(webviewEnvironment->CreateContextMenuItem(
L"", nullptr,
COREWEBVIEW2_CONTEXT_MENU_ITEM_KIND_SEPARATOR,
&m_separatorContextSubMenuItem));
CHECK_FAILURE(items->InsertValueAtIndex(
itemsCount, m_separatorContextSubMenuItem.get()));
But I see no separator?
For me personally, could we have a sample that shows us using our own menu template? All the samples seem to "build" a menu. I already have a menu. Although it was designed for IE so thinks like "View Source" will need changing in some way.
But I digress. What is the right way to add a separator to the custom context menu? Eg, just before "New Sub Menu" in the sample code.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the WebView2 custom context-menu sample and the CreateContextMenuItem and InsertValueAtIndex calls shown in the issue. Verify how a separator should be inserted into an existing menu, then update the sample or guidance so the separator appears before "New Sub Menu" and the completed behavior is demonstrable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- desktop
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100