4#ifndef QARKUI__WINDOW_H
5#define QARKUI__WINDOW_H
7#include <QtCore/private/qnapi_p.h>
8#include <QtCore/private/qohoscommon_p.h>
9#include <QtCore/qglobal.h>
10#include <QtCore/qrect.h>
12#include <qohosdisplayinfo.h>
13#include <qohosplugincore.h>
14#include <qohosutils.h>
38 std::string owningQAbilityInstanceId, JsWindowId windowId,
39 QNapi::Object jsWindow, QtOhos::QObjectThreadSafeRef owningQWindowRef);
50 JsWindowId
id()
const;
54 Result
eval(
const std::string &expr,
const std::vector<QNapi::ValueWrapper> &exprArgs = {})
const;
57 const std::string &expr,
const std::vector<QNapi::ValueWrapper> &exprArgs = {})
const;
62 std::string m_owningQAbilityInstanceId;
63 JsWindowId m_jsWindowId;
64 QNapi::Reference<QNapi::Object> m_jsWindow;
65 QtOhos::QObjectThreadSafeRef m_owningQWindowRef;
68template<
typename Result>
69Result
JsWindowRef::
eval(
const std::string &expr,
const std::vector<QNapi::ValueWrapper> &exprArgs)
const
71 return m_jsWindow.eval<Result>(expr, exprArgs);
75 const std::string &expr,
const std::vector<QNapi::ValueWrapper> &exprArgs)
const
77 return m_jsWindow.evalToPromiseOrRejectOnThrow(expr, exprArgs);
JsWindowRef(JsWindowRef &&)=delete
JsWindowRef(std::string owningQAbilityInstanceId, JsWindowId windowId, QNapi::Object jsWindow, QtOhos::QObjectThreadSafeRef owningQWindowRef)
JsWindowRef(const JsWindowRef &)=delete
QtOhos::QObjectThreadSafeRef owningQWindowRef() const
JsWindowRef & operator=(JsWindowRef &&)=delete
Result eval(const std::string &expr, const std::vector< QNapi::ValueWrapper > &exprArgs={}) const
bool isWindowShown() const
JsWindowRef & operator=(const JsWindowRef &)=delete
const std::string & owningQAbilityInstanceId() const
QNapi::Promise evalToPromiseOrRejectOnThrow(const std::string &expr, const std::vector< QNapi::ValueWrapper > &exprArgs={}) const
std::optional< WindowProperties > tryGetWindowProperties(JsWindowId jsWindowId)
Combined button and popup list for selecting options.
std::optional< QOhosDisplayInfo::JsDisplayId > displayId