feat(wasm-dom): Phase 5 baselines + visual notes (menus/toolbars/tooltips)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
|
@ -113,3 +113,21 @@ slider/statline/statbox wired:
|
|||
- **Polish items (open):** generic wxSpinCtrl's text field collapses
|
||||
beside the spin pair; Event Log textarea lacks the univ scrollbar
|
||||
gutter (native scrollbars appear on overflow instead).
|
||||
|
||||
## Phase 5 (2026-06-10) — menus, toolbars, tooltips
|
||||
|
||||
- **Working as native DOM:** menubar strip (File/Edit/View/Tools/Help) with
|
||||
popup menus — items, separators, check marks, submenu expansion, hover
|
||||
highlight, outside-click dismissal, drop shadow (`menu-03-file-clicked`
|
||||
is a close twin of the canvas popup); toolbar strips with PNG icon
|
||||
buttons, toggle state, separators; tooltips as native `title`
|
||||
attributes (wxUSE_TOOLTIPS re-enabled for the DOM build).
|
||||
- **Compatibility:** menu titles register as rendered elements
|
||||
(`menuitem`/`menubar`), popup items as `menuitem`, tools as `tool` —
|
||||
`clickMenuBarItem`/`findRenderedByType`-based specs pass unchanged
|
||||
(menu.spec 7/7, toolbar.spec 6/6).
|
||||
- **Architecture note:** menu structures serialize C++→JS as JSON
|
||||
(wxDomMenuSetStructure); activation routes back via
|
||||
wxDomGetLastCommandId + wxDOM_EVENT_MENU → wxMenu::SendEvent. Toolbar
|
||||
identical shape (wxDomToolbarSetTools / wxDOM_EVENT_TOOL →
|
||||
wxToolBarBase::OnLeftClick with radio-group + veto handling).
|
||||
|
|
|
|||
|
|
@ -46,9 +46,8 @@ if [ "$DOM_BUILD" = "1" ]; then
|
|||
BUILD_DIR="$PROJECT_ROOT/build-wasm/wxwidgets-dom"
|
||||
# Native (non-universal) widget set: controls are real DOM elements.
|
||||
UNIVERSAL_FLAG=""
|
||||
# Tooltips will be DOM title attributes (dom-phase-5); no wxToolTip yet.
|
||||
# (Universal mode auto-disables them; native mode must do it explicitly.)
|
||||
PORT_EXTRA_FLAGS="--disable-tooltips"
|
||||
# Tooltips are DOM title attributes (wx/wasm/tooltip.h).
|
||||
PORT_EXTRA_FLAGS=""
|
||||
WXLIB_PREFIX="libwx_wasmu"
|
||||
else
|
||||
BUILD_DIR="$PROJECT_ROOT/build-wasm/wxwidgets-universal"
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 38 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 29 KiB |
BIN
tests/baseline-screenshots-dom/menu-03-file-clicked.png
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
tests/baseline-screenshots-dom/menu-04-edit-clicked.png
Normal file
|
After Width: | Height: | Size: 29 KiB |
BIN
tests/baseline-screenshots-dom/menu-05-all-menus.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 28 KiB |
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 28 KiB |
BIN
tests/baseline-screenshots-dom/toolbar-03-new-clicked.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
tests/baseline-screenshots-dom/toolbar-04-zoom.png
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
tests/baseline-screenshots-dom/toolbar-05-toggle-on.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
tests/baseline-screenshots-dom/toolbar-06-toggle-off.png
Normal file
|
After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 28 KiB |
BIN
tests/baseline-screenshots-dom/toolbar-08-all-buttons.png
Normal file
|
After Width: | Height: | Size: 41 KiB |
|
|
@ -1 +1 @@
|
|||
Subproject commit a93ce9187cb0b482897ca502c314ee5aca68b52c
|
||||
Subproject commit 5de7b0f072d2dd26c83347190d0587121a9df39e
|
||||