Jasmine core files should be available to other gems

This commit is contained in:
ragaskar
2011-04-29 22:41:18 -04:00
parent 48c8d2cc1f
commit 995cdd6e3b
16 changed files with 133518 additions and 81 deletions

View File

@@ -0,0 +1,22 @@
function Player() {
}
Player.prototype.play = function(song) {
this.currentlyPlayingSong = song;
this.isPlaying = true;
};
Player.prototype.pause = function() {
this.isPlaying = false;
};
Player.prototype.resume = function() {
if (this.isPlaying) {
throw new Error("song is already playing");
}
this.isPlaying = true;
};
Player.prototype.makeFavorite = function() {
this.currentlyPlayingSong.persistFavoriteStatus(true);
};