|
| | FakeTable (std::shared_ptr< RecordStore > store, std::string kind, ContainerWidget const *parent) |
| | Records the new table, appended to parent, and logs its creation.
|
| | ~FakeTable () override |
| | Removes the hook that points at this table, so nothing calls it once the table is gone, even if the record outlives it because recording the destruction failed.
|
|
| FakeTable (FakeTable const &)=delete |
|
FakeTable & | operator= (FakeTable const &)=delete |
|
| FakeTable (FakeTable &&)=delete |
|
FakeTable & | operator= (FakeTable &&)=delete |
| void | setColumns (std::vector< TableColumn > const &columns) override |
| | Records property columns, each as its escaped caption, a colon and its width.
|
| void | setShowHeader (bool shown) override |
| | Records property showHeader.
|
| void | setSelectionMode (SelectionMode mode) override |
| | Records property selectionMode, which RecordingBackend::selectRows enforces.
|
| void | setRowKey (Widget &row, Key const &key) override |
| | Records property rowKey on row, and marks the row when its key is requested.
|
| void | setRowTone (Widget &row, std::optional< Tone > tone) override |
| | Records the row's property tone (none for no tone).
|
| void | setSelection (std::vector< Key > const &keys) override |
| | Requests the rows with keys, and records property selection as the rows it marks.
|
| void | setOnSelectionChange (std::function< void(std::vector< Key >)> onSelectionChange) override |
| | Stores the handler RecordingBackend::selectRows calls.
|
| void | setOnActivate (std::function< void(Key)> onActivate) override |
| | Stores the handler RecordingBackend::activateRow calls.
|
| void | setRealizedWindow (std::size_t first, std::size_t count, std::size_t total) override |
| | Records property realizedWindow as <first>+<count>/<total>.
|
| void | setOnVisibleRangeChanged (std::function< void(std::size_t, std::size_t)> onVisibleRangeChanged) override |
| | Stores the handler RecordingBackend::scrollTable calls.
|
| void | scrollTo (std::size_t first, std::size_t count) |
| | Simulates the backend reporting a scroll: calls the handler setOnVisibleRangeChanged stored, as a real backend's own scroll callback would. Does nothing if nothing is subscribed (a table below its virtualization threshold never calls setOnVisibleRangeChanged, so this is a silent no-op for it, matching a real backend that never virtualizes).
|
| SelectionMode | mode () const noexcept |
| | The selection mode last set.
|
| std::optional< int > | rowOf (Key const &key) const |
| | The current row with key.
|
| void | selectByUser (std::vector< Key > const &keys) |
| | Marks the rows the user selected, as the requested keys; nothing is logged.
|
| void | moveChild (Widget &child, std::size_t index) override |
| | Moves a child among its siblings and logs it.
|
| | FakeLeaf (std::shared_ptr< RecordStore > store, std::string kind, ContainerWidget const *parent, PropList initial={}) |
| | Records the new widget, appended to parent, and logs its creation.
|
| | ~FakeLeaf () override |
| | Forgets the widget and logs its destruction; its remaining children become roots.
|
|
FakeLeaf & | operator= (FakeLeaf const &)=delete |
| void | setVisible (bool visible) override |
| | Records property visible.
|
| void | setEnabled (bool enabled) override |
| | Records property enabled.
|
| void | setLayout (LayoutHints const &hints) override |
| | Records property layout, as formatLayout gives it.
|
| void | setDragKey (std::optional< Key > const &key) override |
| | Records property dragKey and keeps the key for RecordingBackend::drag.
|
| void | setDropHandler (std::function< bool(Key const &)> accepts, std::function< void(Key)> onDrop) override |
| | Records property drop=handler and keeps both handlers for RecordingBackend::drag.
|
| void | setAccessibleName (std::string_view name) override |
| | Records property a11yName.
|
| void | setAccessibleRole (std::string_view role) override |
| | Records property a11yRole.
|
| void | setTestId (std::string_view testId) override |
| | Records property testId.
|
| void | setTooltip (std::string_view text) override |
| | Records property tooltip.
|
| void | setSurface (std::string_view surface) override |
| | Records property surface.
|
| void | setKeys (std::vector< std::string > const &chords, std::function< void(std::string)> onChord) override |
| | Records property keys, the chords joined by commas, and keeps the chords and the handler for RecordingBackend::press.
|
| void | focus () override |
| | Moves the backend's recorded focus here, and logs focus.
|
| void | setOnHover (std::function< void()> onHover) override |
| | Keeps the handler for RecordingBackend::hover.
|
| virtual void | setExistingKeys (std::vector< Key > const &keys) |
| | Tells the backend every key currently in the table's data, realized or not – called whenever that set changes (a data change, or a scroll that dewindows or re-realizes a row). A virtualized backend needs this to know a selected key still exists in the data when it has no realized row for it right now (setRowKey alone cannot say that, since it is only ever called for a realized row): without it, a backend that reconstructs "does this key still exist" purely from its realized children would silently drop a selected key's membership the moment its row scrolls out of view. A backend that never virtualizes may ignore this – every key it cares about already has a realized row, by definition, so setRowKey alone already tells it everything this call would add.
|
|
| Widget (Widget const &)=delete |
|
Widget & | operator= (Widget const &)=delete |
|
| Widget (Widget &&)=delete |
|
Widget & | operator= (Widget &&)=delete |
A fake TableWidget: properties columns, selectionMode, selection, and rowKey on a row.
selection shows the rows the widget marks: the requested keys, in the order requested, that one of its current rows has. The requested keys are kept, so a row that arrives with one of them is marked and a row that goes is unmarked; that re-marking is the widget's own doing and is not logged.
Definition at line 1376 of file recording_backend.hpp.