This repository was archived by the owner on Feb 7, 2019. It is now read-only.
Open
Conversation
Adds the basic structure for the Sound library, and populates it with the first couple (not yet implemented) methods.
Implemented Sound.PlayClick and manually verified that it works!
Adds the documentation for PlayClick.
Adds the strings for the rest of the Sound APIs, as copied from SmallBasic.Web\Content\js\json\generated-output.json
Copy better strings into Sound.Play and Sound.Play.FilePath, per the actual documentation headers in the original code.
Implement the structure of the rest of the Sound APIs, + actually implement the three easy ones (playing sound files like what was already implemented for Click)
Refactor the Sound library to make it more unit testable, and add some basic tests.
Author
|
Notes:
|
OmarTawfik
reviewed
Nov 2, 2018
|
|
||
| public readonly methods: { readonly [name: string]: LibraryMethodInstance } = { | ||
| PlayClick: { execute: this.executePlayStockSound.bind(this, Sound.Click) }, | ||
| PlayClickAndWait: { execute: () => { throw new Error("Not Implemented yet."); } }, |
Member
There was a problem hiding this comment.
I'd suggest not adding the NYI methods until they're actually functional. No need to show it in the UI and crash afterwards if they're not implemented yet.
OmarTawfik
reviewed
Nov 2, 2018
| @@ -0,0 +1,12 @@ | |||
| import { ISoundLibraryPlugin } from "../../../compiler/runtime/libraries/sound"; | |||
|
|
|||
| export class SoundLibraryPlugin implements ISoundLibraryPlugin { | |||
Member
There was a problem hiding this comment.
Can you document where did we get the sound files from?
Author
There was a problem hiding this comment.
The sound files come from the Desktop copy of the code -- do you know where that got it from? I don't recall seeing any comments.
OmarTawfik
reviewed
Nov 2, 2018
Member
OmarTawfik
left a comment
There was a problem hiding this comment.
I left a few comments. Please let me know if you need a second pair of eyes on the sound files that are not playing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds an initial implementation of the Sound library. Contains: