From 7dacaa70d945c966045a7f36091b1f8dfa92b868 Mon Sep 17 00:00:00 2001 From: Christopher Date: Fri, 21 Apr 2017 22:55:17 +0100 Subject: [PATCH] Fixed Cmd+Left Click doesn't register as right click on OSX #595 --- .../Fungus/Scripts/Editor/FlowchartWindow.cs | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs b/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs index 5281d60a..110ea949 100644 --- a/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs +++ b/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs @@ -610,6 +610,16 @@ namespace Fungus.EditorUtils { var hitBlock = GetBlockAtPoint(e.mousePosition); + // Convert Ctrl+Left click to a right click on mac + if (Application.platform == RuntimePlatform.OSXEditor) + { + if (e.button == MouseButton.Left && + e.control) + { + e.button = MouseButton.Right; + } + } + switch(e.button) { case MouseButton.Left: @@ -760,6 +770,16 @@ namespace Fungus.EditorUtils { var hitBlock = GetBlockAtPoint(e.mousePosition); + // Convert Ctrl+Left click to a right click on mac + if (Application.platform == RuntimePlatform.OSXEditor) + { + if (e.button == MouseButton.Left && + e.control) + { + e.button = MouseButton.Right; + } + } + switch (e.button) { case MouseButton.Left: