Kaku
Kaku copied to clipboard
Isn't there a clear interface to interact with the player ?
Feature
Idea
isn't there a JS class that lets you hook to the existing player and control it ? like play videos from other sources that the already existing (I implemented local video file playing) ?
What is your Kaku version?
2.0.2
What is your OS (with version number)?
Mac 10.14.1
@moda20 I don't understand your meaning, any example ?
@EragonJ I mean is there a global class or object that I can access to handle the play in the app from my own new js file or are all the controls linked to the the built in controls. basically tell me what should I do in js code if I want to play a video from a given URI. give me a simple body of a function like this :
function playFromURI(pathToFile){
}
are all the controls linked to the the built in controls.
Yes, when you are using the play media
key in your keyboard, it will trigger the play logic in Kaku. So maybe in your js file, you can try to watch whether there is play media
key got pressed ?
But I don't think this will be precise enough because maybe for some special case, Kaku will not run (for example, if there is no track in your playlist)
https://github.com/EragonJ/Kaku/blob/master/src/views/modules/Player.js#L463-L471
This is the main code that triggers player to play media. (the most correct one, so you can hook your js here)
@moda20 Did my response answer your question :) ? If yes, I'll close this issue