Comment 13 for bug 1010111

Revision history for this message
Jiří Janoušek (fenryxo) wrote :

Thanks, code review follows.

description.html:

You have forgotten to replace dummy text from template with real text

metadata.conf:

> maintainer_link = https://github.com/ipf/nuvola-soundcloud/

If you would like to ship service integration with Nuvola Player releases, you must use URL of your Launchpad profile.

integration.js

- Add yourself to the list of copyright holders at the top of the file.

- Values of variables can_prev, can_next, state, can_thumbs_up must be set according to real state of
  the web app. For example, state must be Nuvola.STATE_NONE on start-up, Nuvola.STATE_PAUSED
  when song is paused and Nuvola.STATE_PLAYING when music is really playing.

- Is in neccessary to hide hide welcome message or is it only a benefit?

+ if (this.can_thumbs_up !== can_thumbs_up)
+ {
+ this.can_thumbs_up = can_thumbs_up;
+ Nuvola.updateAction(Nuvola.ACTION_THUMBS_UP, can_thumbs_up);
+ }

If thumbs up action in never available you should set it to false only once in Integration constructor.

+ case Nuvola.ACTION_PAUSE:
+ $('.playControl').click();
+ break;

You should add a condition if (this.state == Nuvola.STATE_PLAYING)

+ case Nuvola.ACTION_THUMBS_DOWN:
+ alert("Thumbs down!");
+ break;

Don't use alert().