From 8ae0e1d2eb6d48a0c3b6cbbb7fc0896f0e26b765 Mon Sep 17 00:00:00 2001 From: Southrop Date: Tue, 10 Jul 2018 11:45:01 +0900 Subject: [PATCH 1/7] mouseDown was depecated A long time ago apparently https://forum.unity.com/threads/event-type-is-obsolete.509502/ --- Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs b/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs index 8645a087b..744e75cb8 100644 --- a/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs +++ b/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs @@ -139,7 +139,7 @@ private void drawListElement(string header, string content, string url) { var rect = GUILayoutUtility.GetLastRect(); EditorGUIUtility.AddCursorRect(rect, MouseCursor.Link); - if (Event.current.type == EventType.mouseDown && rect.Contains(Event.current.mousePosition)) + if (Event.current.type == EventType.MouseDown && rect.Contains(Event.current.mousePosition)) Application.OpenURL(url); } } @@ -185,4 +185,4 @@ private void Awake() hideFlags = HideFlags.HideAndDontSave; } } -} \ No newline at end of file +} From 0f7aceb2e38f45de96664b85bf5c96289a358ed9 Mon Sep 17 00:00:00 2001 From: Southrop Date: Tue, 10 Jul 2018 11:54:18 +0900 Subject: [PATCH 2/7] Samsung TV and WiiU are deprecated SamsungTV was deprecated in 2017.3 and WiiU in 2018.1 --- .../Scripts/Devices/Display/GenericDisplayDevice.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs index 892dd2397..f6ab97186 100644 --- a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs +++ b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs @@ -102,11 +102,15 @@ private void updateNativeResulotion() nativeResolution = new Vector2(res.width, res.height); break; // Probably TVs +#if !UNITY_2017_3_OR_NEWER case RuntimePlatform.SamsungTVPlayer: +#endif #if UNITY_5_6_OR_NEWER case RuntimePlatform.Switch: #endif +#if !UNITY_2018_1_OR_NEWER case RuntimePlatform.WiiU: +#endif case RuntimePlatform.XboxOne: case RuntimePlatform.tvOS: // This has not been tested and is probably wrong. @@ -199,11 +203,15 @@ private void updateNativeDPI() // We just hope that mobiles report their DPI correctly break; // Probably TVs +#if !UNITY_2017_3_OR_NEWER case RuntimePlatform.SamsungTVPlayer: +#endif #if UNITY_5_6_OR_NEWER case RuntimePlatform.Switch: #endif +#if !UNITY_2018_1_OR_NEWER case RuntimePlatform.WiiU: +#endif case RuntimePlatform.XboxOne: case RuntimePlatform.tvOS: // This has not been tested and is probably wrong. @@ -242,4 +250,4 @@ private bool getHighestResolution(out Vector2 resolution) return true; } } -} \ No newline at end of file +} From dc15a8a2453d21d93727f854741e186ace9e58e3 Mon Sep 17 00:00:00 2001 From: Southrop Date: Tue, 10 Jul 2018 12:04:00 +0900 Subject: [PATCH 3/7] EnumMaskField was deprecated in 2017.3 --- Source/Assets/TouchScript/Editor/TouchManagerEditor.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs index b5486f592..9c931032d 100644 --- a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs +++ b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs @@ -207,7 +207,11 @@ private void drawSendMessage() var label = EditorGUI.BeginProperty(r, TEXT_SEND_MESSAGE_EVENTS, sendMessageEvents); EditorGUI.BeginChangeCheck(); r = EditorGUI.PrefixLabel(r, label); - var sMask = (TouchManager.MessageType) EditorGUI.EnumMaskField(r, instance.SendMessageEvents); +#if UNITY_2017_3_OR_NEWER + var sMask = (TouchManager.MessageType)EditorGUI.EnumFlagsField(r, instance.SendMessageEvents); +#else + var sMask = (TouchManager.MessageType)EditorGUI.EnumMaskField(r, instance.SendMessageEvents); +#endif if (EditorGUI.EndChangeCheck()) { instance.SendMessageEvents = sMask; @@ -267,4 +271,4 @@ private void refresh() serializedObject.ApplyModifiedProperties(); } } -} \ No newline at end of file +} From cb5195ac2658fdb5a577eac82edf5d30e87b2241 Mon Sep 17 00:00:00 2001 From: Southrop Date: Tue, 10 Jul 2018 12:10:31 +0900 Subject: [PATCH 4/7] Remove newline at EOF --- Source/Assets/TouchScript/Editor/TouchManagerEditor.cs | 2 +- Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs | 2 +- .../TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs index 9c931032d..42b4d16fb 100644 --- a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs +++ b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs @@ -271,4 +271,4 @@ private void refresh() serializedObject.ApplyModifiedProperties(); } } -} +} \ No newline at end of file diff --git a/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs b/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs index 744e75cb8..be9098cc6 100644 --- a/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs +++ b/Source/Assets/TouchScript/Editor/TouchScriptSettingsWindow.cs @@ -185,4 +185,4 @@ private void Awake() hideFlags = HideFlags.HideAndDontSave; } } -} +} \ No newline at end of file diff --git a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs index f6ab97186..038eaf28a 100644 --- a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs +++ b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs @@ -250,4 +250,4 @@ private bool getHighestResolution(out Vector2 resolution) return true; } } -} +} \ No newline at end of file From 4b389d8ccb80805ed50b2284425addecda1614bc Mon Sep 17 00:00:00 2001 From: Southrop Date: Tue, 10 Jul 2018 12:18:53 +0900 Subject: [PATCH 5/7] Consistency fix --- Source/Assets/TouchScript/Editor/TouchManagerEditor.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs index 42b4d16fb..5065baf83 100644 --- a/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs +++ b/Source/Assets/TouchScript/Editor/TouchManagerEditor.cs @@ -208,9 +208,9 @@ private void drawSendMessage() EditorGUI.BeginChangeCheck(); r = EditorGUI.PrefixLabel(r, label); #if UNITY_2017_3_OR_NEWER - var sMask = (TouchManager.MessageType)EditorGUI.EnumFlagsField(r, instance.SendMessageEvents); + var sMask = (TouchManager.MessageType) EditorGUI.EnumFlagsField(r, instance.SendMessageEvents); #else - var sMask = (TouchManager.MessageType)EditorGUI.EnumMaskField(r, instance.SendMessageEvents); + var sMask = (TouchManager.MessageType) EditorGUI.EnumMaskField(r, instance.SendMessageEvents); #endif if (EditorGUI.EndChangeCheck()) { From 044c5796e2f3955fefc701672a609fc02e76d813 Mon Sep 17 00:00:00 2001 From: Southrop Date: Wed, 11 Jul 2018 18:19:35 +0900 Subject: [PATCH 6/7] Tizen deprecated in 2018.2 --- .../Scripts/Devices/Display/GenericDisplayDevice.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs index 038eaf28a..84780f311 100644 --- a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs +++ b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs @@ -76,7 +76,9 @@ private void updateNativeResulotion() // Mobiles / fullscreen case RuntimePlatform.Android: case RuntimePlatform.IPhonePlayer: +#if !UNITY_2018_2_OR_NEWER case RuntimePlatform.TizenPlayer: +#endif case RuntimePlatform.WSAPlayerARM: case RuntimePlatform.WSAPlayerX64: case RuntimePlatform.WSAPlayerX86: @@ -196,7 +198,9 @@ private void updateNativeDPI() // Mobiles / fullscreen case RuntimePlatform.Android: case RuntimePlatform.IPhonePlayer: +#if !UNITY_2018_2_OR_NEWER case RuntimePlatform.TizenPlayer: +#endif case RuntimePlatform.WSAPlayerARM: case RuntimePlatform.WSAPlayerX64: case RuntimePlatform.WSAPlayerX86: From c4dbbc05d3bccf5e03c80285747baba7763aa4a6 Mon Sep 17 00:00:00 2001 From: Southrop Date: Fri, 14 Dec 2018 11:57:36 +0900 Subject: [PATCH 7/7] PS Vita (PSP2) deprecated as of 2018.3 --- .../Scripts/Devices/Display/GenericDisplayDevice.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs index 84780f311..cd643ca71 100644 --- a/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs +++ b/Source/Assets/TouchScript/Scripts/Devices/Display/GenericDisplayDevice.cs @@ -120,9 +120,11 @@ private void updateNativeResulotion() res = Screen.currentResolution; nativeResolution = new Vector2(res.width, res.height); break; +#if !UNITY_2018_3_OR_NEWER case RuntimePlatform.PSP2: nativeResolution = new Vector2(960, 544); break; +#endif default: // This has not been tested and is probably wrong. if (getHighestResolution(out nativeResolution)) break; @@ -232,9 +234,11 @@ private void updateNativeDPI() nativeDPI = 40; } break; +#if !UNITY_2018_3_OR_NEWER case RuntimePlatform.PSP2: nativeDPI = 220.68f; break; +#endif default: // This has not been tested and is probably wrong. nativeDPI = 160;