From nobody Tue Nov 4 15:22:41 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=gmail.com Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1530591307850735.477995076085; Mon, 2 Jul 2018 21:15:07 -0700 (PDT) Received: from localhost ([::1]:37722 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1faCiR-00046u-LT for importer@patchew.org; Tue, 03 Jul 2018 00:14:59 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53599) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1faChZ-0003gE-Ta for qemu-devel@nongnu.org; Tue, 03 Jul 2018 00:14:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1faChU-0004Yx-UZ for qemu-devel@nongnu.org; Tue, 03 Jul 2018 00:14:05 -0400 Received: from mail-it0-x243.google.com ([2607:f8b0:4001:c0b::243]:54625) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1faChU-0004Ye-QF for qemu-devel@nongnu.org; Tue, 03 Jul 2018 00:14:00 -0400 Received: by mail-it0-x243.google.com with SMTP id s7-v6so1257412itb.4 for ; Mon, 02 Jul 2018 21:14:00 -0700 (PDT) Received: from localhost.localdomain ([69.14.184.20]) by smtp.gmail.com with ESMTPSA id v128-v6sm74632ioe.34.2018.07.02.21.13.58 (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 02 Jul 2018 21:13:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=7nrr+xKIxLU2VZ4smYcBWb9QjQNv62NrZAZoELrLelA=; b=SWIHRkhyyq1bTlI1UEupjrDp0SOHmve0Mc8skMXMlKaQ5/pCWaRi8b6aR4JP4qIq2d UsYaYclKtSa3tkdbnDILD4NQJ0Hh+50BbvUi652fl6lTZKb6ebF9cichoOE1+SLGdW28 yxkRSD07fpxB0wZCj2u6pSxn8bf3N/3v8DX2707V5rf7bcj7TKDgCp80GCB1P8Tmj/2P lYQcST6o9ulKUy8Y6WjE0MUL+bd3P3qvFx6ZLOl9VK5Nwu2H5hraQFmhgfUdsNm9zbM4 3OQmSB7Xs/HomOuPGNTsf9mTvfXLXxjGC8wK0rfJtw8OaXEgycR6nYTZpyE11Fs/0heX E5wQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=7nrr+xKIxLU2VZ4smYcBWb9QjQNv62NrZAZoELrLelA=; b=DVlwrDLxyKiQjEXM6xrzkj4/cycFWTGHY5qDMBwazBMOPfYnB8L2GxlX6j5wO3Y9PV Tn2V4xFVs8S/pEx8Q9mJYHNcR+mLpmmyECU2NlC+v7xt9B+G1hMbuh8C22lvhGG/XbLQ DUTjbVTyO+APNBKLZQ5v7JG9YVejRjUMVPO0KvdUUe9AMZJhxvHM3NK9pPsiiLpW3LER kRKBnxrpCx1U+/DdeVAywcaciMMcaLIZNn11kGDg9TbabliUo4LVfKwBIaaI5tNRv+ZV GDyWq8Wnl+Wfa91xBvP8f5PLaYgke66jbt69IM9yKaQisQRkyZ5yN41UL3Ld0To54+i2 Ayqw== X-Gm-Message-State: APt69E2ksrjQE/y0bvFw8QdfurAW5SwOo53MkYnYkkQSDSSFhrY3pF2n 2nvj0Sw9Iiefe1uZOnDdNz8= X-Google-Smtp-Source: AAOMgpcclAqJ652Zb0OAWw8JV20YTrfRfClDqnTKppUBG6rnBFqY26FoSrmoSEiJpZXn5rT7igufOA== X-Received: by 2002:a24:4587:: with SMTP id c7-v6mr8576844itd.151.1530591240079; Mon, 02 Jul 2018 21:14:00 -0700 (PDT) From: John Arbuckle To: peter.maydell@linaro.org, qemu-devel@nongnu.org Date: Tue, 3 Jul 2018 00:13:43 -0400 Message-Id: <20180703041343.2014-1-programmingkidx@gmail.com> X-Mailer: git-send-email 2.14.3 (Apple Git-98) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c0b::243 Subject: [Qemu-devel] [PATCH] ui/cocoa.m: replace scrollingDeltaY with deltaY X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: John Arbuckle Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" The NSEvent class method scrollingDeltaY is available for Mac OS 10.7 and n= ewer. Since QEMU supports Mac OS 10.5 and up, we need to be using a method = that is available on these version of Mac OS X. The deltaY method is a meth= od that does the same thing as scrollingDeltaY and is available on Mac OS 1= 0.5 and up. So we simply replace scrollingDeltaY with deltaY. Signed-off-by: John Arbuckle --- ui/cocoa.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/cocoa.m b/ui/cocoa.m index 2991ed4f19..e34714081d 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -803,7 +803,7 @@ - (void) handleEvent:(NSEvent *)event */ =20 /* Determine if this is a scroll up or scroll down event */ - buttons =3D ([event scrollingDeltaY] > 0) ? + buttons =3D ([event deltaY] > 0) ? INPUT_BUTTON_WHEEL_UP : INPUT_BUTTON_WHEEL_DOWN; qemu_input_queue_btn(dcl->con, buttons, true); qemu_input_event_sync(); --=20 2.14.3 (Apple Git-98)