mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-26 13:05:58 +01:00
parent
05eb2d4af2
commit
fc0a7af7ba
1 changed files with 8 additions and 1 deletions
|
@ -57,6 +57,13 @@ void CInputPopup::onMap() {
|
||||||
|
|
||||||
updateBox();
|
updateBox();
|
||||||
damageEntire();
|
damageEntire();
|
||||||
|
|
||||||
|
const auto PMONITOR = g_pCompositor->getMonitorFromVector(globalBox().middle());
|
||||||
|
|
||||||
|
if (!PMONITOR)
|
||||||
|
return;
|
||||||
|
|
||||||
|
g_pProtocolManager->m_pFractionalScaleProtocolManager->setPreferredScaleForSurface(surface.wlr(), PMONITOR->scale);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CInputPopup::onUnmap() {
|
void CInputPopup::onUnmap() {
|
||||||
|
@ -121,7 +128,7 @@ void CInputPopup::updateBox() {
|
||||||
cursorBoxLocal = {0, 0, (int)parentBox.w, (int)parentBox.h};
|
cursorBoxLocal = {0, 0, (int)parentBox.w, (int)parentBox.h};
|
||||||
}
|
}
|
||||||
|
|
||||||
Vector2D currentPopupSize = {surface.wlr()->current.width, surface.wlr()->current.height};
|
Vector2D currentPopupSize = surface.getViewporterCorrectedSize();
|
||||||
|
|
||||||
if (cursorBoxLocal != lastBoxLocal || currentPopupSize != lastPopupSize)
|
if (cursorBoxLocal != lastBoxLocal || currentPopupSize != lastPopupSize)
|
||||||
damageEntire();
|
damageEntire();
|
||||||
|
|
Loading…
Reference in a new issue