Portals0.7.0 · dev (544a5c68c72e · 2026-11-28 UTC)
Loading...
Searching...
No Matches
portals::ui::detail::MountContext Struct Reference

Stack-owned transaction bookkeeping, discarded after one description mount. More...

#include <ui_recipe_context.hpp>

Classes

struct  PendingRef
 Same-attempt Ref reservation used by cold graph finalization before publication. More...
struct  CaptionFinalizer
 Transaction-local dependency; it never survives mount or schedules runtime work. More...

Public Member Functions

 ~MountContext ()
 Release attempt-owned resources and ref reservations after publication or rollback.

Public Attributes

ControlContext controls {}
 Immutable owning defaults for this mount transaction.
std::size_t controlLeaves {}
 Effective settings counted across the complete transaction.
bool controlPrepared {}
 Only the current constructor received already resolved resource settings.
const TextResolver * themeSelectorResolver {}
 Constructor-only selector fallback, cleared before internal children.
const TextResolver * messageResolver {}
 Opted-in MessageBox constructor-only fallback; cleared before children.
const TextResolver * dataStateResolver {}
 Native fallback constructor-only borrow; never ambient to body/setup.
const ControlSettings * controlSettings {}
 Constructor-only borrowed settings; restored before setup/children.
Description< Widget > * messageBody {}
 Constructor-scoped owning cold source, never retained after mount.
const ControlSettings * frameSettings {}
 Current source frame patch only; never inherited by children.
const FrameOptions * frameOptions {}
 Current native ScrollArea constructor only; never inherited by children.
Node< Widget > mountedOuter
 Last synchronous mount's actual layout root, including through type erasure.
Node< Widget > root
 First created node; identifies the subtree to retire on failure.
std::vector< Node< Widget > > nodes
 Created observers checked for liveness before publication.
std::vector< portals::detail::MoveOnlyFunction< void()> > publish
 Nonthrowing assignments publishing reserved refs.
std::vector< portals::detail::MoveOnlyFunction< void()> > release
 Nonthrowing releases of temporary ref reservations.
std::vector< PendingRef > pending = std::vector<PendingRef>(0)
 Private same-attempt reservations.
std::vector< CaptionFinalizer > captions
 Fallible checked-STL construction stays inside mount's error boundary.
std::vector< portals::detail::MoveOnlyFunction< std::expected< void, ManagedError >()> > finalize
 Pure cold graph completion.
std::vector< portals::detail::MoveOnlyFunction< void()> > rollback
 Explicit attempt-owned resources, never numeric checkpoints.
bool committed {}
 True only after every finalizer and node check succeeds.

Detailed Description

Stack-owned transaction bookkeeping, discarded after one description mount.

Member Data Documentation

◆ captions

std::vector<CaptionFinalizer> portals::ui::detail::MountContext::captions
Initial value:
=
std::vector<CaptionFinalizer>(0)

Fallible checked-STL construction stays inside mount's error boundary.

◆ finalize

std::vector<portals::detail::MoveOnlyFunction<std::expected<void, ManagedError>()> > portals::ui::detail::MountContext::finalize
Initial value:
=
std::vector<portals::detail::MoveOnlyFunction<std::expected<void, ManagedError>()>>(
0)

Pure cold graph completion.

◆ nodes

std::vector<Node<Widget> > portals::ui::detail::MountContext::nodes
Initial value:
=
std::vector<Node<Widget>>(0)

Created observers checked for liveness before publication.

◆ publish

std::vector<portals::detail::MoveOnlyFunction<void()> > portals::ui::detail::MountContext::publish
Initial value:
=
std::vector<portals::detail::MoveOnlyFunction<void()>>(0)

Nonthrowing assignments publishing reserved refs.

◆ release

std::vector<portals::detail::MoveOnlyFunction<void()> > portals::ui::detail::MountContext::release
Initial value:
=
std::vector<portals::detail::MoveOnlyFunction<void()>>(0)

Nonthrowing releases of temporary ref reservations.

◆ rollback

std::vector<portals::detail::MoveOnlyFunction<void()> > portals::ui::detail::MountContext::rollback
Initial value:
=
std::vector<portals::detail::MoveOnlyFunction<void()>>(
0)

Explicit attempt-owned resources, never numeric checkpoints.


The documentation for this struct was generated from the following file: