From 1a7ba130a6bdff969b1c7c5ec716cb0712fe0b39 Mon Sep 17 00:00:00 2001 From: Josh Tynjala Date: Tue, 9 May 2023 14:35:06 -0700 Subject: [PATCH] NativeProcess, FileStream: some Haxe 3 compatibility fixes --- src/openfl/desktop/NativeProcess.hx | 2 +- src/openfl/filesystem/FileStream.hx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/openfl/desktop/NativeProcess.hx b/src/openfl/desktop/NativeProcess.hx index cb20e85fb2..303bc3d415 100644 --- a/src/openfl/desktop/NativeProcess.hx +++ b/src/openfl/desktop/NativeProcess.hx @@ -863,7 +863,7 @@ private class OutboundPipe implements IDataOutput } } } -#else +#elseif flash #if air typedef NativeProcess = flash.desktop.NativeProcess; #end diff --git a/src/openfl/filesystem/FileStream.hx b/src/openfl/filesystem/FileStream.hx index 5d9182ff36..8cc1f62df6 100644 --- a/src/openfl/filesystem/FileStream.hx +++ b/src/openfl/filesystem/FileStream.hx @@ -1,6 +1,6 @@ package openfl.filesystem; -#if (!flash && sys) +#if (haxe4 && sys && !flash) import haxe.Json; import haxe.Serializer; import haxe.Timer; @@ -1625,7 +1625,7 @@ class FileStream extends EventDispatcher implements IDataInput implements IDataO return position = value; } } -#else +#elseif flash #if air typedef FileStream = flash.filesystem.FileStream; #end