Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update asap to 6.0.3 #24

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
Binary file modified com.wudsn.ide.snd/lib/atari8bit/asap.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion com.wudsn.ide.snd/lib/atari8bit/asap.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
The files "asap.jar" and "asap-6.0.1-java-src.zip" were provided by Fox.
The files "asap.jar" and "asap-6.0.3-java-src.zip" were provided by Fox.
The source is not included in the build.properties to keep the size at the minimum.
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public synchronized void load(String fileName, InputStream inputStream) throws C
try {
asap.load(fileName, module, moduleLen);
asapMusicRoutine = new ASAPMusicRoutine(fileName, module, moduleLen);
} catch (Exception ex) {
} catch (ASAPFormatException|ASAPConversionException ex) {
Copy link
Author

@pfusik pfusik Apr 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ASAPConversionException is thrown from the ASAPMusicRoutine constructor. Consider displaying a separate error message.

// ERROR: Cannot load sound file '{0}'. {1}
IStatus status = new Status(IStatus.ERROR, SoundPlugin.ID,
TextUtility.format(Texts.MESSAGE_E502, fileName, ex.getMessage()));
Expand All @@ -149,8 +149,8 @@ public synchronized void load(String fileName, InputStream inputStream) throws C
// Translate the file type to a human readable text.
try {
info.moduleTypeDescription = ASAPInfo.getExtDescription(info.moduleFileType);
} catch (Exception unknownExtensionException) {
info.moduleTypeDescription = unknownExtensionException.getMessage();
} catch (ASAPFormatException ex) {
info.moduleTypeDescription = ex.getMessage();
}

final List<FileType> supportedExportFileTypes = new ArrayList<FileType>();
Expand Down Expand Up @@ -241,7 +241,7 @@ public synchronized void play(int song, SoundPlayerListener listener) throws Cor
try {
info = asap.getInfo();
asap.playSong(song, info.getLoop(song) ? -1 : info.getDuration(song));
} catch (Exception ex) {
} catch (ASAPArgumentException|ASAPFormatException ex) {
// ERROR: Cannot play song number {0}. {1}
IStatus status = new Status(IStatus.ERROR, SoundPlugin.ID, TextUtility.format(Texts.MESSAGE_E503,
NumberUtility.getLongValueDecimalString(song), ex.getMessage()));
Expand Down Expand Up @@ -283,7 +283,7 @@ public synchronized void seekPosition(int position) {
listenerUpdatedPosition = position;
listener.playerUpdated(SoundPlayerListener.POSITION);
}
} catch (Exception ex) {
} catch (ASAPFormatException ex) {
throw new RuntimeException("Cannot seeek to position " + position, ex);
}
}
Expand Down