Update FileDialog.hx
FileDialog.browse fixed for OPEN_FILE, OPEN_DIRECTORY. I changed formatting of the null check on SAVE to match the formatting in the file.
This commit is contained in:
committed by
Josh Tynjala
parent
770bf0e296
commit
d5bac69ff7
@@ -112,7 +112,10 @@ class FileDialog
|
|||||||
var path = null;
|
var path = null;
|
||||||
#if hl
|
#if hl
|
||||||
var bytes = NativeCFFI.lime_file_dialog_open_file(title, filter, defaultPath);
|
var bytes = NativeCFFI.lime_file_dialog_open_file(title, filter, defaultPath);
|
||||||
path = @:privateAccess String.fromUTF8(cast bytes);
|
if (bytes != null)
|
||||||
|
{
|
||||||
|
path = @:privateAccess String.fromUTF8(cast bytes);
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
path = NativeCFFI.lime_file_dialog_open_file(title, filter, defaultPath);
|
path = NativeCFFI.lime_file_dialog_open_file(title, filter, defaultPath);
|
||||||
#end
|
#end
|
||||||
@@ -149,7 +152,10 @@ class FileDialog
|
|||||||
var path = null;
|
var path = null;
|
||||||
#if hl
|
#if hl
|
||||||
var bytes = NativeCFFI.lime_file_dialog_open_directory(title, filter, defaultPath);
|
var bytes = NativeCFFI.lime_file_dialog_open_directory(title, filter, defaultPath);
|
||||||
path = @:privateAccess String.fromUTF8(cast bytes);
|
if (bytes != null)
|
||||||
|
{
|
||||||
|
path = @:privateAccess String.fromUTF8(cast bytes);
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
path = NativeCFFI.lime_file_dialog_open_directory(title, filter, defaultPath);
|
path = NativeCFFI.lime_file_dialog_open_directory(title, filter, defaultPath);
|
||||||
#end
|
#end
|
||||||
@@ -164,7 +170,10 @@ class FileDialog
|
|||||||
var path = null;
|
var path = null;
|
||||||
#if hl
|
#if hl
|
||||||
var bytes = NativeCFFI.lime_file_dialog_save_file(title, filter, defaultPath);
|
var bytes = NativeCFFI.lime_file_dialog_save_file(title, filter, defaultPath);
|
||||||
if (bytes != null) path = @:privateAccess String.fromUTF8(cast bytes);
|
if (bytes != null)
|
||||||
|
{
|
||||||
|
path = @:privateAccess String.fromUTF8(cast bytes);
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
path = NativeCFFI.lime_file_dialog_save_file(title, filter, defaultPath);
|
path = NativeCFFI.lime_file_dialog_save_file(title, filter, defaultPath);
|
||||||
#end
|
#end
|
||||||
|
|||||||
Reference in New Issue
Block a user