2013-04-01, 16:58
Hi,
I recently started working on extending the drag&drop functionality of xbmc...
I started with working on "In list drag&drop". By that I mean that the user can just drag an item in a list to another position in that same list. of course that is only available in a few windows. Right now it's implemented in Favorites and the Music/Video Playlists (those are the windows where i know that there are "Move item up/down" context menus. If I missed a window, please let me know.
What should this enhanced bring:
Step 1: In list dragging
Step 2: all guicontrols can act as drop regions.
Let the user define a guicontrol as "dropable" via some sort of <dropable>KIND_OF_DROPABLE</dropable> and allow the skinner to execute a function when a listitem gets dropped over it via <ondrop>AddToFavourites</ondrop>
Also it might be nice, if the skinner could change the appearance of the drag handle depending on where the user is hovering right now... that way he could add a little plus sign to indicate the dragged item would be added to the favourites, if released right now.
Here is an example screenshot
So, this thread is basically just an FYI that I'm working on this and also to get some feedback if anyone has suggestions on additonal ideas (can't promise, that I will do them).
Btw: I have applied for GSoC 2013, so is this an appropriate application task?
Here is the branch: https://github.com/Fice/xbmc/commits/in_list_dragging
I recently started working on extending the drag&drop functionality of xbmc...
I started with working on "In list drag&drop". By that I mean that the user can just drag an item in a list to another position in that same list. of course that is only available in a few windows. Right now it's implemented in Favorites and the Music/Video Playlists (those are the windows where i know that there are "Move item up/down" context menus. If I missed a window, please let me know.
What should this enhanced bring:
Step 1: In list dragging
- Actually move the file item that has been dragged (Already working)
- Let the skinner define a "drag handle" - that should be a visible representation of the item being dragged and will automatically follow the users mouse pointer. (Already working. In the screenshot that's the little thumbnail under the mouse)
- Let the skinner define a "drag hint" - that should be an indication on where the item would be dropped right now, if the user released the mouse. (Right now that's a hardcoded DrawRect(), so it still needs to be made skinnable. Also there is a bug in calculated the correct position of this item)
- Let the skinner change the visual appearence of the list item being dragged. (already working. In the skin I just added "...draging" to the label, but I'm sure there are more useful things that could be done
Step 2: all guicontrols can act as drop regions.
Let the user define a guicontrol as "dropable" via some sort of <dropable>KIND_OF_DROPABLE</dropable> and allow the skinner to execute a function when a listitem gets dropped over it via <ondrop>AddToFavourites</ondrop>
Also it might be nice, if the skinner could change the appearance of the drag handle depending on where the user is hovering right now... that way he could add a little plus sign to indicate the dragged item would be added to the favourites, if released right now.
Here is an example screenshot
So, this thread is basically just an FYI that I'm working on this and also to get some feedback if anyone has suggestions on additonal ideas (can't promise, that I will do them).
Btw: I have applied for GSoC 2013, so is this an appropriate application task?
Here is the branch: https://github.com/Fice/xbmc/commits/in_list_dragging