forked from quickshell/quickshell
core/window: add QsWindow.devicePixelRatio
This commit is contained in:
parent
bc73d35d03
commit
b336129c34
9 changed files with 48 additions and 0 deletions
|
@ -192,6 +192,7 @@ WaylandPanelInterface::WaylandPanelInterface(QObject* parent)
|
|||
QObject::connect(this->layer, &ProxyWindowBase::backerVisibilityChanged, this, &WaylandPanelInterface::backingWindowVisibleChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::heightChanged, this, &WaylandPanelInterface::heightChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::widthChanged, this, &WaylandPanelInterface::widthChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::devicePixelRatioChanged, this, &WaylandPanelInterface::devicePixelRatioChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::screenChanged, this, &WaylandPanelInterface::screenChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::windowTransformChanged, this, &WaylandPanelInterface::windowTransformChanged);
|
||||
QObject::connect(this->layer, &ProxyWindowBase::colorChanged, this, &WaylandPanelInterface::colorChanged);
|
||||
|
@ -218,10 +219,13 @@ void WaylandPanelInterface::onReload(QObject* oldInstance) {
|
|||
QQmlListProperty<QObject> WaylandPanelInterface::data() { return this->layer->data(); }
|
||||
ProxyWindowBase* WaylandPanelInterface::proxyWindow() const { return this->layer; }
|
||||
QQuickItem* WaylandPanelInterface::contentItem() const { return this->layer->contentItem(); }
|
||||
|
||||
bool WaylandPanelInterface::isBackingWindowVisible() const {
|
||||
return this->layer->isVisibleDirect();
|
||||
}
|
||||
|
||||
qreal WaylandPanelInterface::devicePixelRatio() const { return this->layer->devicePixelRatio(); }
|
||||
|
||||
// NOLINTBEGIN
|
||||
#define proxyPair(type, get, set) \
|
||||
type WaylandPanelInterface::get() const { return this->layer->get(); } \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue