Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::view::ScopedDeferredDocumentLoad Class Reference

View-first editor opening. More...

#include <scripted_ui.hpp>

Public Member Functions

 ScopedDeferredDocumentLoad () noexcept
 ~ScopedDeferredDocumentLoad ()
 ScopedDeferredDocumentLoad (const ScopedDeferredDocumentLoad &)=delete
ScopedDeferredDocumentLoad & operator= (const ScopedDeferredDocumentLoad &)=delete

Static Public Member Functions

static bool active () noexcept
 Whether a guard is alive on this thread.

Detailed Description

View-first editor opening.

A plug-in host creates the editor view synchronously and shows nothing of it – in Logic, a header-only plug-in window – until that call returns. While one of these is alive on the calling thread, ScriptedUiSession::load_deferrable() does not evaluate the document: it checks the script can be read, returns true, and evaluates it from the session's second poll(), so the host gets a correctly sized view at once and the first frame paints before the document mounts. ViewBridge::open() holds one for every host-embedded editor (ViewBridge::Options::hosted_editor()), around both create_view() and the default scripted editor. A plain load() inside one still evaluates immediately – its caller may read bridge() next – but warns once when that blocks the host. Standalone hosts and in-process harnesses never hold one, so their document is mounted when either returns.

Constructor & Destructor Documentation

◆ ScopedDeferredDocumentLoad() [1/2]

pulp::view::ScopedDeferredDocumentLoad::ScopedDeferredDocumentLoad ( )
inlinenoexcept

◆ ~ScopedDeferredDocumentLoad()

pulp::view::ScopedDeferredDocumentLoad::~ScopedDeferredDocumentLoad ( )
inline

◆ ScopedDeferredDocumentLoad() [2/2]

pulp::view::ScopedDeferredDocumentLoad::ScopedDeferredDocumentLoad ( const ScopedDeferredDocumentLoad & )
delete

Member Function Documentation

◆ active()

bool pulp::view::ScopedDeferredDocumentLoad::active ( )
inlinestaticnoexcept

Whether a guard is alive on this thread.

◆ operator=()

ScopedDeferredDocumentLoad & pulp::view::ScopedDeferredDocumentLoad::operator= ( const ScopedDeferredDocumentLoad & )
delete

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