Initial commit
This commit is contained in:
21
gui/pom.xml
Normal file
21
gui/pom.xml
Normal file
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.github.gtache.autosubtitle</groupId>
|
||||
<artifactId>autosubtitle</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>autosubtitle-gui</artifactId>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.github.gtache.autosubtitle</groupId>
|
||||
<artifactId>autosubtitle-api</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
@@ -0,0 +1,12 @@
|
||||
package com.github.gtache.autosubtitle.gui;
|
||||
|
||||
import java.nio.file.Path;
|
||||
|
||||
public interface MainController {
|
||||
|
||||
void extractSubtitles();
|
||||
|
||||
void loadVideo(final Path file);
|
||||
|
||||
MainModel model();
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
package com.github.gtache.autosubtitle.gui;
|
||||
|
||||
import com.github.gtache.autosubtitle.subtitle.EditableSubtitle;
|
||||
import com.github.gtache.autosubtitle.Video;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface MainModel {
|
||||
|
||||
Video video();
|
||||
|
||||
List<EditableSubtitle> subtitles();
|
||||
|
||||
EditableSubtitle selectedSubtitle();
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
package com.github.gtache.autosubtitle.gui;
|
||||
|
||||
/**
|
||||
* Controller for the setup view
|
||||
*/
|
||||
public interface SetupController {
|
||||
|
||||
/**
|
||||
* Installs the video converter
|
||||
*/
|
||||
void installVideoConverter();
|
||||
|
||||
/**
|
||||
* Uninstalls the video converter
|
||||
*/
|
||||
void uninstallVideoConverter();
|
||||
|
||||
/**
|
||||
* Updates the video converter
|
||||
*/
|
||||
void updateVideoConverter();
|
||||
|
||||
/**
|
||||
* Reinstalls the video converter
|
||||
*/
|
||||
void reinstallVideoConverter();
|
||||
|
||||
/**
|
||||
* Installs the subtitle extractor
|
||||
*/
|
||||
void installSubtitleExtractor();
|
||||
|
||||
/**
|
||||
* Uninstalls the subtitle extractor
|
||||
*/
|
||||
void uninstallSubtitleExtractor();
|
||||
|
||||
/**
|
||||
* Updates the subtitle extractor
|
||||
*/
|
||||
void updateSubtitleExtractor();
|
||||
|
||||
/**
|
||||
* Reinstalls the subtitle extractor
|
||||
*/
|
||||
void reinstallSubtitleExtractor();
|
||||
|
||||
/**
|
||||
* Installs the translator
|
||||
*/
|
||||
void installTranslator();
|
||||
|
||||
/**
|
||||
* Uninstalls the translator
|
||||
*/
|
||||
void uninstallTranslator();
|
||||
|
||||
/**
|
||||
* Updates the translator
|
||||
*/
|
||||
void updateTranslator();
|
||||
|
||||
/**
|
||||
* Reinstalls the translator
|
||||
*/
|
||||
void reinstallTranslator();
|
||||
|
||||
/**
|
||||
* @return the model
|
||||
*/
|
||||
SetupModel model();
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
package com.github.gtache.autosubtitle.gui;
|
||||
|
||||
/**
|
||||
* Model for the setup view
|
||||
*/
|
||||
public interface SetupModel {
|
||||
|
||||
/**
|
||||
* @return whether the subtitle extractor is installed
|
||||
*/
|
||||
boolean isSubtitleExtractorInstalled();
|
||||
|
||||
/**
|
||||
* Sets whether the subtitle extractor is installed
|
||||
*
|
||||
* @param installed whether the subtitle extractor is installed
|
||||
*/
|
||||
void setSubtitleExtractorInstalled(boolean installed);
|
||||
|
||||
/**
|
||||
* @return whether an update is available for the subtitle extractor
|
||||
*/
|
||||
boolean isSubtitleExtractorUpdateAvailable();
|
||||
|
||||
/**
|
||||
* Sets whether an update is available for the subtitle extractor
|
||||
*
|
||||
* @param updateAvailable whether an update is available for the subtitle extractor
|
||||
*/
|
||||
void setSubtitleExtractorUpdateAvailable(boolean updateAvailable);
|
||||
|
||||
/**
|
||||
* @return whether the video converter is installed
|
||||
*/
|
||||
boolean isVideoConverterInstalled();
|
||||
|
||||
/**
|
||||
* Sets whether the video converter is installed
|
||||
*
|
||||
* @param installed whether the video converter is installed
|
||||
*/
|
||||
void setVideoConverterInstalled(boolean installed);
|
||||
|
||||
/**
|
||||
* @return whether an update is available for the video converter
|
||||
*/
|
||||
boolean isVideoConverterUpdateAvailable();
|
||||
|
||||
/**
|
||||
* Sets whether an update is available for the video converter
|
||||
*
|
||||
* @param updateAvailable whether an update is available for the video converter
|
||||
*/
|
||||
void setVideoConverterUpdateAvailable(boolean updateAvailable);
|
||||
|
||||
/**
|
||||
* @return whether the translator is installed
|
||||
*/
|
||||
boolean isTranslatorInstalled();
|
||||
|
||||
/**
|
||||
* Sets whether the translator is installed
|
||||
*
|
||||
* @param installed whether the translator is installed
|
||||
*/
|
||||
void setTranslatorInstalled(boolean installed);
|
||||
|
||||
/**
|
||||
* @return whether an update is available for the translator
|
||||
*/
|
||||
boolean isTranslatorUpdateAvailable();
|
||||
|
||||
/**
|
||||
* Sets whether an update is available for the translator
|
||||
*
|
||||
* @param updateAvailable whether an update is available for the translator
|
||||
*/
|
||||
void setTranslatorUpdateAvailable(boolean updateAvailable);
|
||||
}
|
||||
4
gui/src/main/resources/MainBundle.properties
Normal file
4
gui/src/main/resources/MainBundle.properties
Normal file
@@ -0,0 +1,4 @@
|
||||
main.button.export.label=Export video...
|
||||
main.button.extract.label=Extract subtitles
|
||||
main.button.file.label=Open file...
|
||||
main.button.reset.label=Reset subtitles
|
||||
1
gui/src/main/resources/MainBundle_fr.properties
Normal file
1
gui/src/main/resources/MainBundle_fr.properties
Normal file
@@ -0,0 +1 @@
|
||||
main.button.file.label=Ouvrir un fichier...
|
||||
Reference in New Issue
Block a user