Run formatter

This commit is contained in:
Joshua Granick
2021-03-10 12:48:55 -08:00
parent 2c563b7809
commit 8c9808b038
38 changed files with 116 additions and 100 deletions

View File

@@ -60,7 +60,6 @@ class HTML5AudioSource
#else
setCurrentTime(time);
#end
#end
}

View File

@@ -536,8 +536,7 @@ class HTML5Window
// In order to ensure that the browser will fire clipboard events, we always need to have something selected.
// Therefore, `value` cannot be "".
if(inputing)
return;
if (inputing) return;
if (textInput.value != dummyCharacter)
{
@@ -1164,16 +1163,17 @@ class HTML5Window
private var inputing = false;
public function handleCompositionstartEvent(e):Void{
public function handleCompositionstartEvent(e):Void
{
inputing = true;
}
public function handleCompositionendEvent(e):Void{
public function handleCompositionendEvent(e):Void
{
inputing = false;
handleInputEvent(e);
}
public function setTitle(value:String):String
{
if (value != null)

View File

@@ -6779,17 +6779,20 @@ class NativeCFFI
return 0;
}
@:hlNative("lime", "lime_vorbis_file_pcm_seek_lap") private static function lime_vorbis_file_pcm_seek_lap(vorbisFile:CFFIPointer, posLow:Int, posHigh:Int):Int
@:hlNative("lime", "lime_vorbis_file_pcm_seek_lap") private static function lime_vorbis_file_pcm_seek_lap(vorbisFile:CFFIPointer, posLow:Int,
posHigh:Int):Int
{
return 0;
}
@:hlNative("lime", "lime_vorbis_file_pcm_seek_page") private static function lime_vorbis_file_pcm_seek_page(vorbisFile:CFFIPointer, posLow:Int, posHigh:Int):Int
@:hlNative("lime", "lime_vorbis_file_pcm_seek_page") private static function lime_vorbis_file_pcm_seek_page(vorbisFile:CFFIPointer, posLow:Int,
posHigh:Int):Int
{
return 0;
}
@:hlNative("lime", "lime_vorbis_file_pcm_seek_page_lap") private static function lime_vorbis_file_pcm_seek_page_lap(vorbisFile:CFFIPointer, posLow:Int, posHigh:Int):Int
@:hlNative("lime", "lime_vorbis_file_pcm_seek_page_lap") private static function lime_vorbis_file_pcm_seek_page_lap(vorbisFile:CFFIPointer, posLow:Int,
posHigh:Int):Int
{
return 0;
}
@@ -6799,7 +6802,8 @@ class NativeCFFI
return 0;
}
@:hlNative("lime", "lime_vorbis_file_raw_seek_lap") private static function lime_vorbis_file_raw_seek_lap(vorbisFile:CFFIPointer, posLow:Int, posHigh:Int):Int
@:hlNative("lime", "lime_vorbis_file_raw_seek_lap") private static function lime_vorbis_file_raw_seek_lap(vorbisFile:CFFIPointer, posLow:Int,
posHigh:Int):Int
{
return 0;
}
@@ -6824,12 +6828,14 @@ class NativeCFFI
return null;
}
@:hlNative("lime", "lime_vorbis_file_read") private static function lime_vorbis_file_read(vorbisFile:CFFIPointer, buffer:Bytes, position:Int, length:Int, bigendianp:Bool, word:Int, signed:Bool):Dynamic
@:hlNative("lime", "lime_vorbis_file_read") private static function lime_vorbis_file_read(vorbisFile:CFFIPointer, buffer:Bytes, position:Int, length:Int,
bigendianp:Bool, word:Int, signed:Bool):Dynamic
{
return null;
}
@:hlNative("lime", "lime_vorbis_file_read_float") private static function lime_vorbis_file_read_float(vorbisFile:CFFIPointer, pcmChannels:Bytes, samples:Int):Dynamic
@:hlNative("lime", "lime_vorbis_file_read_float") private static function lime_vorbis_file_read_float(vorbisFile:CFFIPointer, pcmChannels:Bytes,
samples:Int):Dynamic
{
return null;
}

View File

@@ -167,7 +167,6 @@ class Event<T>
__listeners.splice(0, len);
__priorities.splice(0, len);
__repeat.splice(0, len);
#end
}
}

View File

@@ -39,8 +39,7 @@ import lime.utils.Log;
@:fileXml('tags="haxe,release"')
@:noDebug
#end
@:allow(lime.app.Promise) /*@:generic*/
class Future<T>
@:allow(lime.app.Promise) /*@:generic*/ class Future<T>
{
/**
If the `Future` has finished with an error state, the `error` value

View File

@@ -226,16 +226,16 @@ class AIRHelper
System.runCommand("", "killall", ["iPhone Simulator"], true, true);
}
System.runCommand(workingDirectory, project.defines.get("AIR_SDK") + "/bin/adt", ["-uninstallApp"]
.concat(args).concat(["-appid", project.meta.packageName]), true, true);
System.runCommand(workingDirectory, project.defines.get("AIR_SDK") + "/bin/adt",
["-uninstallApp"].concat(args).concat(["-appid", project.meta.packageName]), true, true);
System.runCommand(workingDirectory, project.defines.get("AIR_SDK") + "/bin/adt", ["-installApp"].concat(args).concat(["-package",
FileSystem.fullPath(workingDirectory)
+ "/"
+ (rootDirectory != null ? rootDirectory + "/" : "")
+ project.app.file
+ ".ipa"]));
System.runCommand(workingDirectory, project.defines.get("AIR_SDK") + "/bin/adt", ["-launchApp"]
.concat(args).concat(["-appid", project.meta.packageName]), true, true);
System.runCommand(workingDirectory, project.defines.get("AIR_SDK") + "/bin/adt",
["-launchApp"].concat(args).concat(["-appid", project.meta.packageName]), true, true);
if (project.targetFlags.exists("simulator"))
{

View File

@@ -13,7 +13,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract Float32Array(JSFloat32Array) from JSFloat32Array to JSFloat32Array
{
@:to function toArrayBufferView ():ArrayBufferView return this;
@:to function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 4;

View File

@@ -12,7 +12,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract Float64Array(JSFloat64Array) from JSFloat64Array to JSFloat64Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 8;

View File

@@ -12,7 +12,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract Int16Array(JSInt16Array) from JSInt16Array to JSInt16Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 2;

View File

@@ -12,7 +12,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract Int32Array(JSInt32Array) from JSInt32Array to JSInt32Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 4;

View File

@@ -12,7 +12,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract Int8Array(JSInt8Array) from JSInt8Array to JSInt8Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 1;

View File

@@ -12,7 +12,8 @@ import js.html.Uint16Array as JSUInt16Array;
@:transitive
abstract UInt16Array(JSUInt16Array) from JSUInt16Array to JSUInt16Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 2;

View File

@@ -12,7 +12,8 @@ import js.html.Uint32Array as JSUInt32Array;
@:transitive
abstract UInt32Array(JSUInt32Array) from JSUInt32Array to JSUInt32Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 4;

View File

@@ -10,7 +10,8 @@ import js.html.Uint8Array as JSUInt8Array;
@:transitive
abstract UInt8Array(JSUInt8Array) from JSUInt8Array to JSUInt8Array
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 1;

View File

@@ -12,7 +12,8 @@ import js.html.Uint8ClampedArray as JSUInt8ClampedArray;
@:transitive
abstract UInt8ClampedArray(JSUInt8ClampedArray) from JSUInt8ClampedArray to JSUInt8ClampedArray
{
@:to inline function toArrayBufferView ():ArrayBufferView return this;
@:to inline function toArrayBufferView():ArrayBufferView
return this;
public inline static var BYTES_PER_ELEMENT:Int = 1;

View File

@@ -683,11 +683,18 @@ class IOSPlatform extends PlatformTarget
false);
// Merge plist files
var plistFiles = System.readDirectory(projectDirectory).filter(function(fileName:String){
var plistFiles = System.readDirectory(projectDirectory).filter(function(fileName:String)
{
return fileName.substr(-11) == "-Info.plist" && fileName != projectDirectory + "/" + project.app.file + "-Info.plist";
});
for(plist in plistFiles){
System.runCommand(project.workingDirectory, "/usr/libexec/PlistBuddy", ["-x", "-c", "Merge " + plist, projectDirectory + "/" + project.app.file + "-Info.plist"]);
for (plist in plistFiles)
{
System.runCommand(project.workingDirectory, "/usr/libexec/PlistBuddy", [
"-x",
"-c",
"Merge " + plist,
projectDirectory + "/" + project.app.file + "-Info.plist"
]);
}
System.mkdir(projectDirectory + "/lib");

View File

@@ -210,8 +210,9 @@ class WindowsPlatform extends PlatformTarget
var command = #if lime "lime" #else "hxp" #end;
Log.warn("You must define HL_PATH to copy HashLink dependencies, please run '" + command + " setup hl' first");
}else{
}
else
{
System.copyFile(project.environment.get("HL_PATH") + '/ssl.hdll', applicationDirectory + '/ssl.hdll');
}
}

View File

@@ -1103,7 +1103,6 @@ class PlatformSetup
if (answer == YES || answer == ALWAYS)
{
if (System.hostPlatform == MAC)
{
try
@@ -1191,14 +1190,11 @@ class PlatformSetup
Log.println("We recommend using version \"1.10.0\"");
Log.println("available as a free download from Github.\x1b[0m");
var answer = CLIHelper.ask("Would you like to visit the download page now?");
if (answer == YES || answer == ALWAYS)
{
System.openURL(hashlinkURL);
}
getDefineValue("HL_PATH", "Path to Hashlink binaries.");