Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove position property from Player #18

Merged
merged 1 commit into from Mar 5, 2019

Conversation

acrisci
Copy link
Member

@acrisci acrisci commented Mar 5, 2019

Rationale: this property is hard to support for implementing players as
a property they must keep up-to-date because it continuously changes
over time measured in microseconds.

Player#seeked() now takes the absolute position instead of a delta for
consistency with the mpris interface and because we no longer store
position on the player to do this calculation.

The 'seeked' event on the Player now emits with the offset to seek only
for a similar reason.

add Player#getPosition() to be overridden by the user to be called
whenver this property is gotten by the properties interface.

Rationale: this property is hard to support for implementing players as
a property they must keep up-to-date because it continuously changes
over time measured in microseconds.

Player#seeked() now takes the absolute position instead of a delta for
consistency with the mpris interface and because we no longer store
position on the player to do this calculation.

The 'seeked' event on the Player now emits with the offset to seek only
for a similar reason.

add Player#getPosition() to be overridden by the user to be called
whenver this property is gotten by the properties interface.
@acrisci
Copy link
Member Author

acrisci commented Mar 5, 2019

Breaking change.

@emersion emersion merged commit d38d2ed into dbusjs:master Mar 5, 2019
@emersion
Copy link
Collaborator

emersion commented Mar 5, 2019

Indeed, makes sense.

Thanks!

@fcastilloec
Copy link

Can you guys update the README with this new functionality? The example is not obvious enough, and I doubt people will be checking the source code and commit messages to get how this works.

@acrisci acrisci deleted the position-changes branch March 5, 2019 21:18
@acrisci
Copy link
Member Author

acrisci commented Mar 5, 2019

We should probably host the output of npm run doc with github pages or something.

emersion added a commit that referenced this pull request Mar 5, 2019
@emersion
Copy link
Collaborator

emersion commented Mar 5, 2019

Done in 26fcd12

@emersion
Copy link
Collaborator

emersion commented Mar 5, 2019

We should probably host the output of npm run doc with github pages or something.

This should probably come with the CI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants