MCPcopy Create free account
hub / github.com/RevoSucks/BM64Recomp / queue_set_text

Method queue_set_text

src/ui/core/ui_context.cpp:560–572  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

558}
559
560void recompui::ContextId::queue_set_text(Element* element, std::string&& text) {
561 // Ensure a context is currently opened by this thread.
562 if (opened_context_id == ContextId::null()) {
563 context_error(*this, ContextErrorType::SetTextElementWithoutContext);
564 }
565
566 // Check that the context that was specified is the same one that's currently open.
567 if (*this != opened_context_id) {
568 context_error(*this, ContextErrorType::SetTextElementInWrongContext);
569 }
570
571 opened_context->to_set_text.emplace_back(std::make_tuple(element, element->resource_id, std::move(text)));
572}
573
574recompui::Style* recompui::ContextId::create_style() {
575 return add_resource_impl(std::make_unique<Style>());

Callers 1

set_textMethod · 0.80

Calls 1

context_errorFunction · 0.85

Tested by

no test coverage detected