You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to build a Chrome extension for controlling Google Play Music. I have a content script that includes the gmusic.js library. I'm able to successfully call playback.playPause(), playback.getCurrentTrack(), and extras.getTrackURL(), but playback.setCurrentTime() doesn't seem to be working as expected.
When I run the following code, I expect the playback time to be set to 60 seconds:
gmusic = new GMusic();
gmusic.playback.setPlaybackTime(60000);
Instead, I hear a momentary disruption in play, and it continues to play from where it was before.
The console does not show any JavaScript errors.
Any idea what I could be doing wrong?
The text was updated successfully, but these errors were encountered:
I'm still interested in getting gmusic.js working from a Chrome extension. I figured I should give you an example instead of just complaining. I've attached a sample, barebones Chrome extension with gmusic.js.
notice that the console logs "Setting current time to 1 minute..." and then the song skips a moment and continues playing from it's current position. The code has called gmusic.playback.setPlaybackTime(60000); at this point, and the track should be playing from the 1m mark.
I am running Chrome 56.0.2924.87 (64-bit) on macOS Sierra 10.12.3
I'm trying to build a Chrome extension for controlling Google Play Music. I have a content script that includes the gmusic.js library. I'm able to successfully call
playback.playPause()
,playback.getCurrentTrack()
, andextras.getTrackURL()
, butplayback.setCurrentTime()
doesn't seem to be working as expected.When I run the following code, I expect the playback time to be set to 60 seconds:
Instead, I hear a momentary disruption in play, and it continues to play from where it was before.
The console does not show any JavaScript errors.
Any idea what I could be doing wrong?
The text was updated successfully, but these errors were encountered: