Skip to content

Commit

Permalink
Forward the signals from m_backend lxqttakcarwaylandbacked.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
marcusbritanicus committed Mar 27, 2024
1 parent a01b215 commit 6ed1031
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
11 changes: 11 additions & 0 deletions panel/backends/wayland/lxqttaskbarbackendwayland.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,17 @@ LXQtTaskbarWaylandBackend::LXQtTaskbarWaylandBackend(QObject *parent)
if ( m_backend == nullptr ) {
qDebug() << "--------------> Using dummy backend. No window management will be done";
}

else {
connect(m_backend, &ILXQtTaskbarAbstractBackend::reloaded, this, &ILXQtTaskbarAbstractBackend::reloaded );
connect(m_backend, &ILXQtTaskbarAbstractBackend::windowAdded, this, &ILXQtTaskbarAbstractBackend::windowAdded );
connect(m_backend, &ILXQtTaskbarAbstractBackend::windowRemoved, this, &ILXQtTaskbarAbstractBackend::windowRemoved );
connect(m_backend, &ILXQtTaskbarAbstractBackend::windowPropertyChanged, this, &ILXQtTaskbarAbstractBackend::windowPropertyChanged );
connect(m_backend, &ILXQtTaskbarAbstractBackend::workspacesCountChanged, this, &ILXQtTaskbarAbstractBackend::workspacesCountChanged );
connect(m_backend, &ILXQtTaskbarAbstractBackend::workspaceNameChanged, this, &ILXQtTaskbarAbstractBackend::workspaceNameChanged );
connect(m_backend, &ILXQtTaskbarAbstractBackend::currentWorkspaceChanged, this, &ILXQtTaskbarAbstractBackend::currentWorkspaceChanged );
connect(m_backend, &ILXQtTaskbarAbstractBackend::activeWindowChanged, this, &ILXQtTaskbarAbstractBackend::activeWindowChanged );
}
}


Expand Down
6 changes: 5 additions & 1 deletion plugin-taskbar/lxqttaskbar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,11 @@ LXQtTaskBar::LXQtTaskBar(ILXQtPanelPlugin *plugin, QWidget *parent) :
QTimer::singleShot(0, this, &LXQtTaskBar::registerShortcuts);

connect(mBackend, &ILXQtTaskbarAbstractBackend::windowPropertyChanged, this, &LXQtTaskBar::onWindowChanged);
connect(mBackend, &ILXQtTaskbarAbstractBackend::windowAdded, this, &LXQtTaskBar::onWindowAdded);
// connect(mBackend, &ILXQtTaskbarAbstractBackend::windowAdded, this, &LXQtTaskBar::onWindowAdded);
qDebug() << connect(mBackend, &ILXQtTaskbarAbstractBackend::windowAdded, [=](WId window){
qDebug() << "--------------> onWindowAdded" << window;
onWindowAdded(window);
});
connect(mBackend, &ILXQtTaskbarAbstractBackend::windowRemoved, this, &LXQtTaskBar::onWindowRemoved);

// Consider already fetched windows
Expand Down

0 comments on commit 6ed1031

Please sign in to comment.