Skip to content
Snippets Groups Projects
Unverified Commit dd56ec48 authored by Yarick Yermak's avatar Yarick Yermak Committed by GitHub
Browse files

Merge pull request #242 from yermak/development

OGG Conversion fix and chapter edit
parents 795a7a29 ad669b32
No related branches found
No related tags found
No related merge requests found
......@@ -94,8 +94,11 @@ public class MetadataBuilder {
}
metaData.add("track=" + bookInfo.bookNumber() + "/" + bookInfo.totalTracks());
FlacPicture picture = FlacPicture.load(getArtWorkFile());
metaData.add("metadata_block_picture="+picture.write());
if (!posters.isEmpty()){
FlacPicture picture = FlacPicture.load(posters.get(0).getFileName());
metaData.add("metadata_block_picture="+picture.write());
}
metaData.addAll(convertable.getMetaData(bookInfo));
logger.debug("Saving metadata:" + String.join("\n", metaData));
FileUtils.writeLines(metaFile, "UTF-8", metaData);
......
......@@ -323,6 +323,12 @@ public class FilesController {
}
}
public void editChapter(ActionEvent event){
if (chaptersMode.get()) {
bookStructure.editChapter(event);
}
}
private void launch(ConversionGroup conversionGroup, Book book, ObservableList<MediaInfo> mediaInfos, ProgressComponent progressComponent, String outputDestination) {
if (book == null) {
......
......@@ -71,6 +71,12 @@
</accelerator>
</MenuItem>
<MenuItem text="Edit" onAction="#editChapter">
<accelerator>
<KeyCodeCombination alt="UP" code="F2" control="DOWN" meta="UP" shift="UP" shortcut="UP"/>
</accelerator>
</MenuItem>
<SeparatorMenuItem/>
<MenuItem text="Combine" onAction="#combine">
<accelerator>
<KeyCodeCombination alt="UP" code="PLUS" control="DOWN" meta="UP" shift="UP" shortcut="UP"/>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment