Comments (6)
So, I poked around the site a bit. It's quite the complex webapp, as everything is these days.
Play/pause and next/previous, through the UI, work fine. Let's do some seeking then. That's where the problems start.
There is no <audio>
tag to be found in the DOM. Not an insurmountable problem but we have to resort to annoying solutions (monkeypatching the document.createElement
function with our own that tracks <audio>
).
Moreover, SoundCloud don't use normal files but blobs. Now, on its own that is not a problem. However, on seek a new blob is created that is not the full song so the currentTime
and duration
on the <audio>
element are mostly wrong.
So next idea: use the UI for seeking just like everything else. However, my fake MouseEvent
s don't register for whatever reason. From what I can see in SoundCloud's code isTrusted
is never checked so I don't know what the problem is.
I thought of using the API but it can't be used to control the playback on the site itself, only for external playback inside other apps or sites. At least, I don't think it can.
So, in conclusion, I'll make half the site work. It's probably the half most people use anyways through MPRIS2 but it'd still be nice if I could also make seeking work. If someone knows how, feel free to request a pull!
from browser-mpris2.
@mikroskeem @otommod i just tested the soundcloud branch and it works on my machine.
I only tested play/pause and prev/next track and track info
from browser-mpris2.
Checkout the soundcloud branch for a very rough first try.
from browser-mpris2.
Ping; with the recent changes I think this is mostly resolved.
from browser-mpris2.
Ah right, I had to test this. Will do that tomorrow 😄
from browser-mpris2.
ping
from browser-mpris2.
Related Issues (13)
- Make chrome-mpris2 cross platform HOT 1
- Installation instructions for Firefox? HOT 13
- Error: attempting to use a disconnected port object HOT 2
- Unable to invoke extension HOT 7
- Add Support for Youtube Music HOT 9
- Amazon Music Support
- Publish to Chrome Web Store
- Chrome extension fails to load HOT 3
- Shared upstream HOT 3
- Add Spotify Support HOT 1
- Following installation instructions HOT 22
- YouTube video playing but player status says "paused" HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from browser-mpris2.