Class FileDialogs

java.lang.Object
meteordevelopment.meteorclient.utils.misc.FileDialogs

public final class FileDialogs extends Object
Native file dialogs. The dialog is asynchronous and its callback runs on SDL's own thread, so the result is handed back on the client thread.
  • Method Details

    • openFile

      public static void openFile(String extensions, Consumer<? super File> onSelected)
      Parameters:
      extensions - SDL filter extensions, e.g. "txt", "txt;json" or "*"
      onSelected - called on the client thread with the picked file
    • saveFile

      public static void saveFile(String extensions, Consumer<? super File> onSelected)
      Parameters:
      extensions - SDL filter extensions, e.g. "png", "txt;json" or "*"
      onSelected - called on the client thread with the picked file