Commit Graph

5386 Commits

Author SHA1 Message Date
player-03
c00589c189 Use original haxe.Timer in macros.
During macros, `System.getTimer()` falls through to `Sys.time()`, which is the same thing the original `haxe.Timer` uses. Therefore this change produces the same behavior but reduces the number of classes imported, which may help prevent errors.
2023-04-15 20:29:33 -04:00
player-03
88b6a7e14b Remove @:generic from Promise at macro time.
This prevents an inconsistent "Field has no new expression" bug.
2023-04-15 14:57:19 -04:00
Josh Tynjala
f8ec10b969 AIRHelper: allow listen=port in <config:air/> to use USB debugging instead of wifi debugging for Adobe AIR apps on Android or iOS 2023-04-13 15:42:05 -07:00
Josh Tynjala
1ac0810895 XcodeHelper: search for default iPhone simulator device id with a regular expression instead of a specific string
Previously, the value was "iphone-11". Now the regex is ~/iphone-\d+/g

As long as the naming scheme stays the same, this should choose the newest iPhone supported by Xcode, and we won't need to update manually anymore, like in commit 72dd60f1c8
2023-04-11 16:02:17 -07:00
Josh Tynjala
04b69a9cef AIRHelper: display a warning when no selected iOS simulator is found when building AIR for iOS app
Ideally, we'd always get a simulator name, but better to fail gracefully
2023-04-11 15:51:56 -07:00
Josh Tynjala
2e19898c28 XCodeHelper: fix null exception when trying to get the ID or name of the selected iOS simulator
Ideally, it shouldn't return null, but if it does, fail gracefully
2023-04-11 15:50:53 -07:00
Josh Tynjala
e753c5c933 AIRHelper: fix failed Adobe AIR for iOS build on Windows
It was incorrectly trying to list simulators from Xcode (and Xcode, obviously, doesn't exist on Windows)
2023-04-11 15:21:55 -07:00
Josh Tynjala
f07e94708b Window: minWidth/minHeight/setMinSize and maxWidth/maxHeight/setMaxSize 2023-04-11 09:46:10 -07:00
player-03
bd810c888d Merge pull request #1658 from player-03/setup-java-v2
Update actions/setup-java
2023-04-10 21:20:23 -04:00
player-03
8825d27cb2 Use version 3 of actions/setup-java.
Version 2 wasn't even the latest version, and still used Node 12.
2023-04-10 19:06:56 -04:00
Josh Tynjala
f34b595e70 IOSPlatform: remove armv7 from default iOS architectures because latest Xcode reports error
Fixes error: The armv7 architecture is deprecated. You should update your ARCHS build setting to remove the armv7 architecture. (in target 'Build Haxe' from project 'MyProject')
2023-04-10 15:20:50 -07:00
Josh Tynjala
72db242720 IOSPlatform: be explicit about armv6, just in case the default architecture used by hxcpp changes in the future
The default changed recently for the x86 simulator, so best to be safe
2023-04-10 15:03:45 -07:00
Josh Tynjala
1e6d883baf IOSPlatform: when building liblime.iphonesim.a, explicitly add -DHXCPP_M32
It looks like the new hxcpp update defaults to 64-bit now, so we need to be explicit
2023-04-10 14:58:24 -07:00
player-03
dc1a11bdac Use version 2 of actions/setup-java
GitHub is deprecating Node 12, forcing us to update any actions that rely on it. https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/

actions/setup-java@v2 now requires us to specify a distribution. v1 used Zulu, so we'll just stick with that for now.
2023-04-10 17:26:00 -04:00
Josh Tynjala
f43173b942 Application: call __unregisterLimeModule on exit, similar to match the call to __registerLimeModule in the constructor
For some reason, this method was never called.
2023-04-10 13:41:14 -07:00
Josh Tynjala
ea8ed5bbe4 HTML5Window: clean up canvas/div and event listeners on window close() 2023-04-10 13:36:52 -07:00
Josh Tynjala
e9a085311e AIRApplication: check for null with Application.current 2023-04-10 13:31:40 -07:00
Josh Tynjala
906492a5b1 Application: fix handling of canceled when onExit is dispatched 2023-04-10 13:31:02 -07:00
Josh Tynjala
82ec709831 Application: on exit, clear Application.current if it is equal to this
This matches setting Application.current in the constructor, and helps avoid memory leaks
2023-04-10 12:54:48 -07:00
Josh Tynjala
23bafb2035 System: exit() on html5 "closes" the main application window 2023-04-10 12:54:37 -07:00
Josh Tynjala
48dc64373b Application: let AIR handle checking for all windows closed with its own autoExit behavior 2023-04-10 10:40:25 -07:00
player-03
780ec7e837 Merge pull request #1615 from player-03/eval_tools
Add the `-eval` flag to run Lime tools using Eval.
2023-04-06 19:34:24 -04:00
player-03
adda161ec6 Use "password" text input only on Android.
Using `userAgent` to tell whether the app is running on Android. This isn't foolproof, but will work more often than the previous approach (where you chose at compile time and your choice applied to all devices). Resolves #1655.
2023-04-05 16:36:36 -04:00
Josh Tynjala
0f694662f9 HTML5HTTPRequst: status 400 should be considered an error 2023-04-04 09:00:28 -07:00
player-03
4d3ae39d50 Use forward slashes to load lime.ndll.
`substr(7)` returns the substring _starting_ at character 7, which will never be "windows". The author meant to type `substr(0, 7)` instead, to get the substring ending at 7.

We could easily make this change, but given that the code has been successfully using forward slashes for several years, I prefer to simplify.
2023-04-01 11:56:41 -04:00
player-03
2026f404ff Initialize variable. 2023-04-01 11:33:20 -04:00
player-03
776db44e37 Add missing type declaration.
Nowadays you're supposed to omit this type declaration, but what I didn't realize is that that feature was added in Haxe 4.1. Since Lime still needs to support earlier versions, we'll just have to do it the old way.
2023-04-01 11:29:35 -04:00
player-03
77f3d4bacf Improve "Could not find NekoAPI interface" message.
This message comes up relatively often when a new user tries to set up Lime, but fails to give any instructions a new user could use.

This commit adds a new message explaining the most common issue and how to solve it. It also provides file paths, which may help with more in-depth debugging.
2023-04-01 11:20:05 -04:00
Josh Tynjala
a68e9c4b8e ExternalInterface: fix error from missing header on Linux in commit 95411acb8c 2023-03-28 13:00:23 -07:00
Josh Tynjala
95411acb8c ExternalInterface: fix conversion of std::wstring to std:string on non-Windows systems for file dialog functions (closes #1622) 2023-03-28 12:06:41 -07:00
Josh Tynjala
2b8e3c439e Merge branch '8.1.0-Dev' into 8.2.0-Dev 2023-03-20 09:44:45 -07:00
jf
aefce3c4ae change hl_al_filteri argument type 2023-03-17 18:14:42 +00:00
Josh Tynjala
33c8a79ddd ExternalInterface: fix lime_window_set_visible on HL (wrong signature) 2023-03-16 09:36:08 -07:00
Josh Tynjala
0160c12311 Window: visible property to show and hide window 2023-03-16 08:41:56 -07:00
Josh Tynjala
4105b97fc8 Window: save the initial title from WindowAttributes
If not saved, the title getter will return the wrong value
2023-03-15 15:03:29 -07:00
Josh Tynjala
589712e29f ApplicationMain: ensure that AIR window initial title is populated
Was incorrectly being set to Lime Application instead
2023-03-15 14:50:47 -07:00
Joseph Cloutier
22032ef6b5 Allow eval for HXP projects.
Plus, do some cleanup. For instance, `nekoOutput` is only used in one
spot, so might as well declare it there.

Aside: I doubt `fullPath()` is needed, but I don't care to test it.
2023-03-13 18:26:44 -04:00
Josh Tynjala
1134122841 Mention different set of packages required to rebuild for Raspberry Pi OS 2023-03-07 14:34:09 -08:00
Chris Speciale
3b5588267b tools.hxml: Remove -D no-inline
The no-inline macro was added previously to fix a compatibility issue with an older version of Haxe. It remains to be seen whether or not it is necessary as it seems to create conflicts with intermittent versions of Haxe. For this purpose we will remove it, unless it is deemed necessary again in the future. See: https://github.com/openfl/lime/discussions/1645 for more info.
2023-03-07 12:03:27 -05:00
player-03
1331e3a4a8 Merge pull request #1643 from player-03/doWork_compatibility
Improve `doWork`'s backwards compatibility.
2023-03-02 17:01:28 -05:00
Joseph Cloutier
5b0e798582 Emulate all of Event's public properties.
Even the `@:noCompletion` ones.
2023-03-02 14:36:39 -05:00
Joseph Cloutier
9b9d433ce8 Add deprecation warning to BackgroundWorker.
I also reworded it, focusing on what to do.
2023-03-02 14:30:23 -05:00
Joseph Cloutier
edc5ab3719 Revert "BackgroundWorker: Depreciate BackgroundWorker"
This reverts commit 4ffc4422b2.
2023-03-02 14:08:17 -05:00
Joseph Cloutier
ec32da4c3e Merge branch '8.2.0-Dev' into doWork_compatibility 2023-03-02 14:06:30 -05:00
Chris Speciale
8de5ddbfbd BackgroundWorker: Update warning
Minor mistake. I'm tired..
2023-03-02 14:02:39 -05:00
Joseph Cloutier
94ecdeb7df Improve doWork's backwards compatibility. 2023-03-02 14:00:37 -05:00
Chris Speciale
4ffc4422b2 BackgroundWorker: Depreciate BackgroundWorker
This revives the BackgroundWorker implementation and adds a depreciation warning.
2023-03-02 13:56:34 -05:00
Patrick Gutlich
82242e2c1c remove define for legacy SDL_VIDEO_DRIVER_RPI 2023-03-02 08:49:58 -08:00
Josh Tynjala
55ca39da44 slightly different compiler flags with Raspberry Pi ARM64 2023-03-01 15:55:55 -08:00
Josh Tynjala
f9b52b7e91 LinuxPlatform: missing HXCPP_ARM64 flag for rpi 64 build 2023-03-01 15:21:46 -08:00