mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-29 15:03:09 +00:00
Some changes
- uncomment to make it frameless window hint - set window state to fullscreen
This commit is contained in:
parent
02fd43edb8
commit
0d626dc7ad
1 changed files with 5 additions and 7 deletions
|
|
@ -35,8 +35,8 @@
|
||||||
FullScreenPanel::FullScreenPanel(QQuickWindow *parent)
|
FullScreenPanel::FullScreenPanel(QQuickWindow *parent)
|
||||||
: QQuickWindow(parent)
|
: QQuickWindow(parent)
|
||||||
{
|
{
|
||||||
//setFlags(Qt::FramelessWindowHint);
|
setFlags(Qt::FramelessWindowHint);
|
||||||
//setWindowState(Qt::WindowFullScreen);
|
setWindowState(Qt::WindowFullScreen);
|
||||||
// connect(this, &FullScreenPanel::activeFocusItemChanged, this, [this]() {qWarning()<<"hide()";});
|
// connect(this, &FullScreenPanel::activeFocusItemChanged, this, [this]() {qWarning()<<"hide()";});
|
||||||
connect(this, &QWindow::activeChanged, this, &FullScreenPanel::activeChanged);
|
connect(this, &QWindow::activeChanged, this, &FullScreenPanel::activeChanged);
|
||||||
initWayland();
|
initWayland();
|
||||||
|
|
@ -72,6 +72,7 @@ void FullScreenPanel::initWayland()
|
||||||
m_plasmaShellSurface->setSkipTaskbar(true);
|
m_plasmaShellSurface->setSkipTaskbar(true);
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
/*
|
||||||
connect(registry, &Registry::shellAnnounced, this,
|
connect(registry, &Registry::shellAnnounced, this,
|
||||||
[this, registry] (quint32 name, quint32 version) {
|
[this, registry] (quint32 name, quint32 version) {
|
||||||
|
|
||||||
|
|
@ -85,7 +86,7 @@ void FullScreenPanel::initWayland()
|
||||||
//Additionally, errno was set to 71: Protocol error
|
//Additionally, errno was set to 71: Protocol error
|
||||||
m_shellSurface = m_shellInterface->createSurface(m_surface, this);
|
m_shellSurface = m_shellInterface->createSurface(m_surface, this);
|
||||||
}
|
}
|
||||||
);
|
);*/
|
||||||
registry->setup();
|
registry->setup();
|
||||||
connection->roundtrip();
|
connection->roundtrip();
|
||||||
}
|
}
|
||||||
|
|
@ -94,10 +95,7 @@ void FullScreenPanel::showEvent(QShowEvent *event)
|
||||||
{
|
{
|
||||||
using namespace KWayland::Client;
|
using namespace KWayland::Client;
|
||||||
QQuickWindow::showEvent(event);
|
QQuickWindow::showEvent(event);
|
||||||
|
setWindowState(Qt::WindowFullScreen);
|
||||||
if (m_shellSurface) {
|
|
||||||
m_shellSurface->setFullscreen();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue