public class GUIMainControl<G extends GameObject<G,A,R>,A extends MapArchObject<A>,R extends Archetype<G,A,R>>
extends java.lang.Object
implements net.sf.japi.util.ThrowableHandler<java.lang.Throwable>
| Constructor and Description |
|---|
GUIMainControl(ProjectModel<G,A,R> projectModel,
EditorSettings editorSettings,
ErrorView errorView,
ResourceIcons resourceIcons,
EditorFactory<G,A,R> editorFactory,
ConfigSourceFactory configSourceFactory)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
handleThrowable(java.lang.Throwable t) |
void |
openFile(java.io.File file)
Loads a map file.
|
void |
openFiles(java.lang.Iterable<java.lang.String> filenames)
Load a list of map files.
|
void |
run(java.lang.Iterable<java.lang.String> args)
Starts the editor: makes the main window visible and opens map files.
|
public GUIMainControl(@NotNull
ProjectModel<G,A,R> projectModel,
@NotNull
EditorSettings editorSettings,
@NotNull
ErrorView errorView,
@NotNull
ResourceIcons resourceIcons,
@NotNull
EditorFactory<G,A,R> editorFactory,
@NotNull
ConfigSourceFactory configSourceFactory)
projectModel - the project model to editeditorSettings - the editor settings instanceerrorView - the error view for reporting errorsresourceIcons - the gui utils for creating iconseditorFactory - the editor factory instanceconfigSourceFactory - the config source factory instancepublic void openFile(@NotNull
java.io.File file)
throws java.io.IOException
file - the file to loadjava.io.IOException - if an I/O error occurspublic void openFiles(java.lang.Iterable<java.lang.String> filenames)
filenames - collection of filenames to loadpublic void handleThrowable(@NotNull
java.lang.Throwable t)
handleThrowable in interface net.sf.japi.util.ThrowableHandler<java.lang.Throwable>public void run(@NotNull
java.lang.Iterable<java.lang.String> args)
args - the map files to open