Skip to content

Commit

Permalink
fix: Use a copy of Java's Supplier to support MobiVM.
Browse files Browse the repository at this point in the history
  • Loading branch information
crykn committed Mar 5, 2024
1 parent 8781fa4 commit 0bb0df6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/de/eskalon/commons/screen/ScreenManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@

import java.util.LinkedList;
import java.util.Queue;
import java.util.function.Supplier;

import org.jspecify.annotations.Nullable;

Expand All @@ -40,6 +39,7 @@
import de.eskalon.commons.screen.transition.ScreenTransition;
import de.eskalon.commons.utils.BasicInputMultiplexer;
import de.eskalon.commons.utils.ScreenFboUtils;
import de.eskalon.commons.utils.Supplier;

/**
* A screen manager that handles the different screens of a game and their
Expand Down
11 changes: 11 additions & 0 deletions src/main/java/de/eskalon/commons/utils/Supplier.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package de.eskalon.commons.utils;

/**
*
* A copy of Java's Supplier for pre-Java 8 support.
*/
@FunctionalInterface
public interface Supplier<T> {

T get();
}

0 comments on commit 0bb0df6

Please sign in to comment.