From nobody Tue Nov 26 06:51:50 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1709636993; cv=none; d=zohomail.com; s=zohoarc; b=jhyv55fW+sYue24r1CdR3XvVVsc6FhOUMBcMJdasaPs/Ys+3Ps/H8gD9OJ7HSxaLTXCFK/dCnUPFgZVFhiXTipTKWH8rcwxCxetx9FcD/FtpCstvdpa7ZQvRbU7KcTY/FVIzxljlyTiR73rCE5iD+udk9q7aXlrxsxm0WjKhG9M= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1709636993; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=BD6Kyo1n9e4Vc/VDtm7XcC1eUkYKmt1UEkhUMSJXsxM=; b=nIIPno3UN3ZgEdVfam9WvirEhF8/jkx+08gNZKlLpyHXkFe9quj5Gucp5SSDMudh5ETo/D9mwRr/PhVdW6AYgWhqLv6NmH1YYGX12YKXWI0outXwRsS+xjgJSqFeADoEGTOcpA/wls2D4UH9b/LpQVCf4YzSgjbOLt8Wm1foZrM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1709636993850492.7789072992497; Tue, 5 Mar 2024 03:09:53 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rhSdT-0008H2-IS; Tue, 05 Mar 2024 06:07:03 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rhSdP-00086E-UT for qemu-devel@nongnu.org; Tue, 05 Mar 2024 06:06:59 -0500 Received: from mail-ed1-x535.google.com ([2a00:1450:4864:20::535]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rhSdK-0002ok-Eo for qemu-devel@nongnu.org; Tue, 05 Mar 2024 06:06:59 -0500 Received: by mail-ed1-x535.google.com with SMTP id 4fb4d7f45d1cf-565a3910f86so8243564a12.3 for ; Tue, 05 Mar 2024 03:06:53 -0800 (PST) Received: from m1x-phil.lan ([176.176.177.70]) by smtp.gmail.com with ESMTPSA id oy29-20020a170907105d00b00a43fe57b2basm5900527ejb.61.2024.03.05.03.06.51 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 05 Mar 2024 03:06:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1709636812; x=1710241612; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=BD6Kyo1n9e4Vc/VDtm7XcC1eUkYKmt1UEkhUMSJXsxM=; b=xdrJFadh+qvjaykMr2xnsPhCk3/QcXp00uRnYuK9LdIKURzVK0wHGow1JHchVetn8x j3nypfBTEj8Gn3euQg1xgdVMHO3RZjLt2g+kjcJm+GGdDgeLti1HraSVg//2wJul/mAl ldRL4efx/BYKxJLCPylHBThLPfBQOdouNOH/RJp/2t4gaAWfYSmQJaE+dzcLru5E2cYz pXfvUy5XE+J8LbnERv9CNarRPvzQ26sgFX8k5R8lUS46eTEUw+3zHqGks+SjqWsGU7Re xV4bis4HZcFp65UVoXW1Q+tbTdL6sBQAJvyOuPteFBGD1ANrh0/cbbutIZyWh2wX5IjJ mNWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709636812; x=1710241612; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BD6Kyo1n9e4Vc/VDtm7XcC1eUkYKmt1UEkhUMSJXsxM=; b=hs5swByPx2uJcC/s/eJUKS4mw9F1yI8saaI9uuIwy3pPTFwjlV/Mn3CfkqVWYUYsgc jqJroHuhsJh6UtfOSY7jJVypvKUdZ9LZonHdkNTIHMD+DmgoktPz7OILaNxpL8B8dH2l Nn1L4eG3ZAUSOMNTAw/KHi83aNcE77UoK4Q7leSvL41JBUnkQQkQRD4+V9tkHQ4TQPy0 yxWzezowYB/Tr692+6935eHErghtsdJUGAlgorSs+DUXGqqAd88pRPC2BJqbiYA8pVig b6NKKAuBFPKm2/3v/g6VqKPX/Gm89KUapUW1kkdKHmLGaISzmynSaxbAHhkVSYZvTl3W 8Gww== X-Gm-Message-State: AOJu0YyLHtDrfcmRE23zeHVD5/y8wQsmW5iA2pO6/ygPXNDlHAH8Eg8q /A4GavL3Cr5sUiWNbpyZYdkC7muaFyVnVkF+13wFq1MfosIalARCPPI3hCRp/Ub7qeSbkwjMZgS h X-Google-Smtp-Source: AGHT+IGosgmIyYyHEy+o53tt6a42tZe3NRYYT8n/KGJzioxo8nzAO8VdUzRfFX8ZLLqr8aJ8sudidg== X-Received: by 2002:a17:906:408d:b0:a45:69f5:c3c9 with SMTP id u13-20020a170906408d00b00a4569f5c3c9mr3176440ejj.6.1709636812815; Tue, 05 Mar 2024 03:06:52 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Akihiko Odaki , Rene Engel , Peter Maydell , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Gerd Hoffmann , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Subject: [PULL 07/12] ui/cocoa: Fix pause label coordinates Date: Tue, 5 Mar 2024 12:06:02 +0100 Message-ID: <20240305110608.21618-8-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240305110608.21618-1-philmd@linaro.org> References: <20240305110608.21618-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::535; envelope-from=philmd@linaro.org; helo=mail-ed1-x535.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1709636995680100005 From: Akihiko Odaki A subview is positioned in the superview so the superview's frame should be used instead of one of the window to determine the coordinates. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-5-e89f70bdda71@daynix.com> Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- ui/cocoa.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/cocoa.m b/ui/cocoa.m index 6e8cd24e88..a2e52ceabc 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -1451,8 +1451,8 @@ - (void)displayPause { /* Coordinates have to be calculated each time because the window can = change its size */ int xCoord, yCoord, width, height; - xCoord =3D ([normalWindow frame].size.width - [pauseLabel frame].size.= width)/2; - yCoord =3D [normalWindow frame].size.height - [pauseLabel frame].size.= height - ([pauseLabel frame].size.height * .5); + xCoord =3D ([cocoaView frame].size.width - [pauseLabel frame].size.wid= th)/2; + yCoord =3D [cocoaView frame].size.height - [pauseLabel frame].size.hei= ght - ([pauseLabel frame].size.height * .5); width =3D [pauseLabel frame].size.width; height =3D [pauseLabel frame].size.height; [pauseLabel setFrame: NSMakeRect(xCoord, yCoord, width, height)]; --=20 2.41.0