layout/windowTarget: don't use swar on maximized (#13501)
This commit is contained in:
parent
9f98f7440b
commit
5f650f8ed9
2 changed files with 11 additions and 2 deletions
|
|
@ -28,6 +28,15 @@ static void swar() {
|
|||
EXPECT_CONTAINS(str, "size: 1036,1036");
|
||||
}
|
||||
|
||||
// don't use swar on maximized
|
||||
OK(getFromSocket("/dispatch fullscreen 1"));
|
||||
|
||||
{
|
||||
auto str = getFromSocket("/activewindow");
|
||||
EXPECT_CONTAINS(str, "at: 22,22");
|
||||
EXPECT_CONTAINS(str, "size: 1876,1036");
|
||||
}
|
||||
|
||||
// clean up
|
||||
NLog::log("{}Killing all windows", Colors::YELLOW);
|
||||
Tests::killAllWindows();
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ void CWindowTarget::updatePos() {
|
|||
|
||||
Vector2D ratioPadding;
|
||||
|
||||
if ((*REQUESTEDRATIO).y != 0 && m_space->algorithm()->tiledTargets() <= 1) {
|
||||
if ((*REQUESTEDRATIO).y != 0 && m_space->algorithm()->tiledTargets() <= 1 && fullscreenMode() == FSMODE_NONE) {
|
||||
const Vector2D originalSize = MONITOR_WORKAREA.size();
|
||||
|
||||
const double requestedRatio = (*REQUESTEDRATIO).x / (*REQUESTEDRATIO).y;
|
||||
|
|
@ -137,7 +137,7 @@ void CWindowTarget::updatePos() {
|
|||
calcPos = calcPos + GAPOFFSETTOPLEFT + ratioPadding / 2;
|
||||
calcSize = calcSize - GAPOFFSETTOPLEFT - GAPOFFSETBOTTOMRIGHT - ratioPadding;
|
||||
|
||||
if (isPseudo()) {
|
||||
if (isPseudo() && fullscreenMode() == FSMODE_NONE) {
|
||||
// Calculate pseudo
|
||||
float scale = 1;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue