Skip to content

Commit

Permalink
Merge pull request #6 from DoubleDee73/2023.11
Browse files Browse the repository at this point in the history
2023.11
  • Loading branch information
DoubleDee73 authored Nov 12, 2023
2 parents b2c5276 + 00a9961 commit a2fd836
Show file tree
Hide file tree
Showing 34 changed files with 3,018 additions and 2,231 deletions.
5 changes: 1 addition & 4 deletions .idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions launch4j.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<launch4jConfig>
<dontWrapJar>false</dontWrapJar>
<headerType>gui</headerType>
<jar>.\target\Yass-Reloaded-2023.7-jar-with-dependencies.jar</jar>
<jar>.\target\Yass-Reloaded-2023.11-jar-with-dependencies.jar</jar>
<outfile>.\target\yass.exe</outfile>
<errTitle></errTitle>
<cmdLine></cmdLine>
Expand All @@ -27,12 +27,12 @@
<timeoutErr>true</timeoutErr>
</splash>
<versionInfo>
<fileVersion>2.4.3.1</fileVersion>
<txtFileVersion>Yass Reloaded 2023.7</txtFileVersion>
<fileVersion>2.5.2.0</fileVersion>
<txtFileVersion>Yass Reloaded 2023.11</txtFileVersion>
<fileDescription>Yass Reloaded - Karaoke Editor</fileDescription>
<copyright>(C)2023 DoubleDee</copyright>
<productVersion>2.4.3.1</productVersion>
<txtProductVersion>2023.7</txtProductVersion>
<productVersion>2.5.2.0</productVersion>
<txtProductVersion>2023.11</txtProductVersion>
<productName>Yass Reloaded</productName>
<companyName>yass-reloaded.com</companyName>
<internalName>yass</internalName>
Expand Down
2 changes: 1 addition & 1 deletion nsis-installer.nsi
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Name "Yass"

OutFile ".\target\yass-installer-2023.7.exe"
OutFile ".\target\yass-installer-2023.11.exe"

Unicode true
SetCompressor lzma
Expand Down
23 changes: 18 additions & 5 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

<groupId>yass</groupId>
<artifactId>Yass-Reloaded</artifactId>
<version>2023.7</version>
<version>2023.11</version>
<dependencies>
<dependency>
<groupId>com.danielreese</groupId>
Expand Down Expand Up @@ -167,7 +167,7 @@
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>32.0.1-jre</version>
<version>32.1.2-jre</version>
</dependency>
<dependency>
<groupId>com.optimaize.languagedetector</groupId>
Expand All @@ -177,14 +177,27 @@
<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-swing</artifactId>
<version>20.0.1</version>
<version>21.0.1</version>
<classifier>linux</classifier>
</dependency>

<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-media</artifactId>
<version>20.0.1</version>
<version>21.0.1</version>
<classifier>linux</classifier>
</dependency>
<dependency>
<groupId>uk.co.caprica</groupId>
<artifactId>vlcj</artifactId>
<version>4.8.2</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.commons/commons-math3 -->
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-math3</artifactId>
<version>3.6.1</version>
</dependency>

</dependencies>

<properties>
Expand Down
63 changes: 52 additions & 11 deletions src/yass/YassActions.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@
public class YassActions implements DropTargetListener {

private final YassSheet sheet;
public final static String VERSION = "2023.7";
public final static String DATE = "07/2023";
public final static String VERSION = "2023.11";
public final static String DATE = "11/2023";

static int VIEW_LIBRARY = 1;
static int VIEW_EDIT = 2;
Expand Down Expand Up @@ -262,6 +262,11 @@ public void actionPerformed(ActionEvent e) {
}
}
};
private final Action reHyphenate = new AbstractAction(I18.get("edit_rehyphenate")) {
public void actionPerformed(ActionEvent e) {
table.rehyphenate();
}
};
private final Action findLyrics = new AbstractAction(I18.get("edit_lyrics_find")) {
public void actionPerformed(ActionEvent e) {
lyrics.find();
Expand Down Expand Up @@ -414,6 +419,7 @@ public void actionPerformed(ActionEvent e) {
msg.addElement(YassRow.UNSORTED_COMMENTS);
msg.addElement(YassRow.WRONG_MEDLEY_START_BEAT);
msg.addElement(YassRow.WRONG_MEDLEY_END_BEAT);
msg.addElement(YassRow.BORING_APOSTROPHE);
songList.batchProcess(false, msg);
}
};
Expand Down Expand Up @@ -830,6 +836,20 @@ public void actionPerformed(ActionEvent e) {
bpmField.setText(String.valueOf(table.getBPM()));
}
};
private final Action recalcBpm = new AbstractAction(I18.get("edit_bpm_recalc")) {
public void actionPerformed(ActionEvent e) {
double newBpm = 0;
String strBpm = bpmField.getText().replace(",", ".");
if (bpmField != null && Double.parseDouble(strBpm) > 0) {
newBpm = Double.parseDouble(bpmField.getText());
}
for (YassTable t: getOpenTables(table)) {
t.recalcBPM(newBpm);
}
if (bpmField != null)
bpmField.setText(String.valueOf(table.getBPM()));
}
};
private final Action showLyricsStart = new AbstractAction(I18.get("edit_gap")) {
public void actionPerformed(ActionEvent e) {
updateGap();
Expand Down Expand Up @@ -896,7 +916,12 @@ public void windowClosing(WindowEvent e) {
b.setText("");
b.setIcon(getIcon("rewind24Icon"));
b.setFocusable(false);

panel.add(b = new JButton());
b.setAction(recalcBpm);
b.setToolTipText(b.getText());
b.setText("");
b.setIcon(getIcon("refresh24Icon"));
b.setFocusable(false);
panel.add(b = new JButton());
b.setAction(showOnlineHelpBeat);
b.setToolTipText(b.getText());
Expand Down Expand Up @@ -1455,14 +1480,19 @@ public void actionPerformed(ActionEvent e) {
};
private final Action removePageBreak = new AbstractAction(I18.get("edit_break_remove")) {
public void actionPerformed(ActionEvent e) {
int row = table.getSelectionModel().getMinSelectionIndex() - 1;
if (row < 1) {
return;
}
table.removePageBreak(true);
table.setRowSelectionInterval(row, row);
removePageBreak();
}
};

public void removePageBreak() {
int row = table.getSelectionModel().getMinSelectionIndex() - 1;
if (row < 1) {
return;
}
table.removePageBreak(true);
table.setRowSelectionInterval(row, row);
}

private final Action copyRows = new AbstractAction(I18.get("edit_copy")) {
public void actionPerformed(ActionEvent e) {
interruptPlay();
Expand Down Expand Up @@ -2006,7 +2036,11 @@ public void actionPerformed(ActionEvent e) {
|| isFilterEditing()) {
return;
}
table.setType(":");
if (table.getRowAt(table.getSelectedRow()).getType().equals(":")) {
playSelectionNext(0);
} else {
table.setType(":");
}
}
};
private final Action addEndian = new AbstractAction(I18.get("edit_length_right_inc")) {
Expand Down Expand Up @@ -2797,6 +2831,7 @@ public void closeAllTables() {
lyrics.setTable(null);
sheet.setActiveTable(null);
songList.closeOpened();
mp3.disposeMediaPlayer();

isUpdating = true;
updateLyrics();
Expand Down Expand Up @@ -3583,6 +3618,7 @@ public void mousePressed(MouseEvent e) {
menu.add(space);
menu.addSeparator();

menu.add(reHyphenate);
menu.add(findLyrics);
menu.add(spellLyrics);

Expand Down Expand Up @@ -4995,7 +5031,7 @@ public void propsChanged(YassSheet source) {
songList.requestFocus();
}
menuHolder.repaint();
}
}

/**
* Ask user 'cancel' and not lose changes.
Expand Down Expand Up @@ -6174,6 +6210,7 @@ boolean openFiles(Vector<String> files, boolean append) {
Vector<YassTable> singles = new Vector<>();
for (String f : all) {
YassTable t = new YassTable();
t.init(prop);
t.loadFile(f);
int multi = t.getMaxP();
if (multi > 1) {
Expand Down Expand Up @@ -6924,6 +6961,10 @@ public void registerLibraryActions(JComponent c) {
am.put("findLyrics", findLyrics);
findLyrics.putValue(AbstractAction.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_F, InputEvent.CTRL_MASK));

im.put(KeyStroke.getKeyStroke(KeyEvent.VK_H, InputEvent.CTRL_MASK), "reHyphenate");
am.put("reHyphenate", reHyphenate);
reHyphenate.putValue(AbstractAction.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_H, InputEvent.CTRL_MASK));

im.put(KeyStroke.getKeyStroke(KeyEvent.VK_A, InputEvent.CTRL_MASK), "selectAllSongs");
am.put("selectAllSongs", selectAllSongs);
selectAllSongs.putValue(AbstractAction.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_A, InputEvent.CTRL_MASK));
Expand Down
Loading

0 comments on commit a2fd836

Please sign in to comment.