Permalink
Browse files

Update playlick to use playdar.js 0.5

  • Loading branch information...
1 parent e2e6694 commit 8087934e5330430fe0ba1db259a0896e182d2fe0 @jwheare committed Nov 14, 2009
Showing with 13 additions and 11 deletions.
  1. +3 −0 .gitmodules
  2. +4 −6 public/index.html
  3. +1 −1 public/lib/playdar
  4. +1 −0 public/lib/sm2
  5. +3 −3 src/js/main/playdar.js
  6. +1 −1 src/js/main/strings.js
View
@@ -1,3 +1,6 @@
[submodule "public/lib/playdar"]
path = public/lib/playdar
url = git://github.com/jwheare/playdar.js.git
+[submodule "public/lib/sm2"]
+ path = public/lib/sm2
+ url = git://github.com/jwheare/soundmanager2.git
View
@@ -153,20 +153,18 @@ <h1 id="playlistTitle">Create a new playlist</h1>
<script src="/js/playlick.js"></script>
<!-- Sound Manager 2 -->
- <script src="/lib/playdar/soundmanager2-nodebug-jsmin.js"></script>
+ <script src="/lib/sm2/script/soundmanager2-nodebug-jsmin.js"></script>
<script>
PLAYLICK.init();
Playdar.USE_STATUS_BAR = false;
Playdar.MAX_CONCURRENT_RESOLUTIONS = 20;
- Playdar.setup({
- receiverurl: "/playdar_auth.html"
- });
- Playdar.client.register_listeners(PLAYDAR.playdar_listeners);
+ Playdar.auth_details.receiverurl = Playdar.Util.location_from_url("/playdar_auth.html").href;
+ Playdar.setupClient(PLAYDAR.playdar_listeners);
/* Soundmanager options */
soundManager.waitForWindowLoad = true;
- soundManager.url = '/lib/playdar/soundmanager2_flash9.swf';
+ soundManager.url = '/lib/sm2/swf/soundmanager2_flash9.swf';
// Enable flash 9 features, like mpeg4 support
soundManager.flashVersion = 9;
Submodule sm2 added at 1d6b25
View
@@ -3,8 +3,8 @@ var PLAYDAR = {
soundmanager_ready: function (status) {
if (status.success) {
$('#playdar').html(STRINGS.loading_playdar_text);
- Playdar.setup_player(soundManager); // soundManager is global at this point
- Playdar.client.init();
+ Playdar.setupPlayer(soundManager); // soundManager is global at this point
+ Playdar.client.go();
} else {
$('#playdar').html(STRINGS.loading_flash_error_text);
}
@@ -231,7 +231,7 @@ var PLAYDAR = {
PLAYDAR.load_track_results(playlist_track, track.playdar_response, true);
} else {
var qid = PLAYDAR.track_handler(playlist_track);
- Playdar.client.resolve(track.artist, track.album, track.name, qid, track.url);
+ Playdar.client.resolve(track.artist, track.name, track.album, qid, track.url);
}
}
},
View
@@ -9,7 +9,7 @@ var STRINGS = {
loading_playdar_text: 'Checking for Playdar…',
connect_to_playdar_text: 'Connect to Playdar',
disconnect_from_playdar_text: 'Disconnect from Playdar',
- playdar_unavailable_text: '<a href="http://www.playdar.org/">Playdar unavailable</a>. <a href="#" onclick="$(\'#playdar\').html(STRINGS.loading_playdar_text); Playdar.client.init(); return false;">retry</a>',
+ playdar_unavailable_text: '<a href="http://www.playdar.org/">Playdar unavailable</a>. <a href="#" onclick="$(\'#playdar\').html(STRINGS.loading_playdar_text); Playdar.client.go(); return false;">retry</a>',
create_playlist_title: $('#playlistTitle').html(),
loading_playlists_text: $('#loading_playlists').html()
};

0 comments on commit 8087934

Please sign in to comment.