From 5c88787401d074289e3c48e2871943ae0fe40900 Mon Sep 17 00:00:00 2001 From: True Zhuanjia Date: Wed, 12 Jun 2024 09:16:17 +0800 Subject: [PATCH] fix null relative coordinate when pointerVelocityfactor is 100% --- Limelight/Input/NativeTouchHandler.m | 12 +++++------- Moonlight.xcodeproj/project.pbxproj | 12 ++++++------ 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/Limelight/Input/NativeTouchHandler.m b/Limelight/Input/NativeTouchHandler.m index ff347d6b..f2c2461a 100644 --- a/Limelight/Input/NativeTouchHandler.m +++ b/Limelight/Input/NativeTouchHandler.m @@ -54,13 +54,11 @@ StreamView *streamView; - (void)updatePointerCoords:(UITouch *)touch{ previousPoint = latestPoint; latestPoint = [touch locationInView:streamView]; - if (pointerVelocityFactor != 1.0f){ - velocityX = latestPoint.x - previousPoint.x; - velocityY = latestPoint.y - previousPoint.y; - previousRelativePoint = latestRelativePoint; - latestRelativePoint.x = previousRelativePoint.x + pointerVelocityFactor * velocityX; - latestRelativePoint.y = previousRelativePoint.y + pointerVelocityFactor * velocityY; - } + velocityX = latestPoint.x - previousPoint.x; + velocityY = latestPoint.y - previousPoint.y; + previousRelativePoint = latestRelativePoint; + latestRelativePoint.x = previousRelativePoint.x + pointerVelocityFactor * velocityX; + latestRelativePoint.y = previousRelativePoint.y + pointerVelocityFactor * velocityY; } + (void)initContextWith:(StreamView *)view{ diff --git a/Moonlight.xcodeproj/project.pbxproj b/Moonlight.xcodeproj/project.pbxproj index ca4ebc5b..ed23738a 100644 --- a/Moonlight.xcodeproj/project.pbxproj +++ b/Moonlight.xcodeproj/project.pbxproj @@ -1213,7 +1213,7 @@ "$(PROJECT_DIR)/libs/SDL2/lib/tvOS-Sim", "$(PROJECT_DIR)/libs/FFmpeg/lib/tvOS-Sim", ); - MARKETING_VERSION = 9.0.0; + MARKETING_VERSION = 9.0.2; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_BUNDLE_IDENTIFIER = "com.moonlight-stream.Moonlight"; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -1269,7 +1269,7 @@ "$(PROJECT_DIR)/libs/SDL2/lib/tvOS-Sim", "$(PROJECT_DIR)/libs/FFmpeg/lib/tvOS-Sim", ); - MARKETING_VERSION = 9.0.0; + MARKETING_VERSION = 9.0.2; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_BUNDLE_IDENTIFIER = "com.moonlight-stream.Moonlight"; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -1410,7 +1410,7 @@ "$(PROJECT_DIR)/libs/**", ); INFOPLIST_FILE = "Limelight/Limelight-Info.plist"; - INFOPLIST_KEY_CFBundleDisplayName = MoonlightAXI; + INFOPLIST_KEY_CFBundleDisplayName = MoonlightZWM; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.games"; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", @@ -1428,7 +1428,7 @@ "$(PROJECT_DIR)/libs/SDL2/lib/iOS-Sim", "$(PROJECT_DIR)/libs/FFmpeg/lib/iOS-Sim", ); - MARKETING_VERSION = 9.0.0; + MARKETING_VERSION = 9.0.2; PRODUCT_BUNDLE_IDENTIFIER = "com.moonlight-zwm-updated.iPadOS"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; @@ -1461,7 +1461,7 @@ "$(PROJECT_DIR)/libs/**", ); INFOPLIST_FILE = "Limelight/Limelight-Info.plist"; - INFOPLIST_KEY_CFBundleDisplayName = MoonlightAXI; + INFOPLIST_KEY_CFBundleDisplayName = MoonlightZWM; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.games"; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", @@ -1479,7 +1479,7 @@ "$(PROJECT_DIR)/libs/SDL2/lib/iOS-Sim", "$(PROJECT_DIR)/libs/FFmpeg/lib/iOS-Sim", ); - MARKETING_VERSION = 9.0.0; + MARKETING_VERSION = 9.0.2; PRODUCT_BUNDLE_IDENTIFIER = "com.moonlight-zwm-updated.iPadOS"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = "";