4#ifndef QWASMWINDOWTREENODE_INC
5#define QWASMWINDOWTREENODE_INC
21 auto *
window = asWasmWindow();
23 previousParent->m_childStack.removeWindow(
window);
26 currentParent->m_childStack.pushWindow(
window, positionPreference);
46 parentNode()->m_childStack.windowPositionPreferenceChanged(asWasmWindow(),
55 parentNode()->setActiveChildNode(asWasmWindow());
58 m_activeIndex = ++s_nextActiveIndex;
66 parentNode()->m_childStack.raise(asWasmWindow());
67 parentNode()->bringToTop();
75 parentNode()->m_childStack.lower(asWasmWindow());
79void QWasmWindowTreeNode<Window>::onTopWindowChanged()
81 constexpr int zOrderForElementInFrontOfScreen = 3;
82 int z = zOrderForElementInFrontOfScreen;
83 std::for_each(m_childStack.rbegin(), m_childStack.rend(),
84 [
this, &
z](
Window *
window) { setWindowZOrder(window, z++); });
88void QWasmWindowTreeNode<Window>::setActiveChildNode(
Window *activeChild)
90 for (
auto *
child : m_childStack)
91 child->onActivationChanged(
child == activeChild);
virtual void setWindowZOrder(Window *window, int z)
void onPositionPreferenceChanged(typename QWasmWindowStack< Window >::PositionPreference positionPreference)
virtual Window * asWasmWindow()
virtual ~QWasmWindowTreeNode()
virtual void onParentChanged(QWasmWindowTreeNode *previous, QWasmWindowTreeNode *current, typename QWasmWindowStack< Window >::PositionPreference positionPreference)
[Window class with invokable method]
GLuint GLfloat GLfloat GLfloat GLfloat GLfloat z
socketLayer bind(QHostAddress::Any, 4000)