XBMC loses place in file list when files are added
#1
Setup: XBMC Eden iOS, browsing file share mounted via SAMBA.

Play video, on file server add a file (with a name that sorts before the video being played), stop video and the selected video is not the one playing.
Reply
#2
So you want the cursor where you left it before you added a video file. Surely it's just moved by one position ?

Flirc now has a forum: forum.flirc.tv
Reply
#3
usually it has just moved by one position, but it is annoying.

i'm usually watching a video that gets interrupted b/c of a network glitch and i quickly hit play to restart it and wind up playing a different video.

should be an easy fix?
Reply
#4
XBMC might believe it has come to the end of the file (since the data stopped abruptly, despite the timestamps) and selects the next item?
Reply
#5
No, it's because we keep only the index into the list of items, not the path (or other characteristics). If someone wants to take a look, see GUIMediaWindow.cpp
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#6
(2012-05-11, 22:19)tobiasfunky Wrote: Setup: XBMC Eden iOS, browsing file share mounted via SAMBA.

Play video, on file server add a file (with a name that sorts before the video being played), stop video and the selected video is not the one playing.

I filed a bug on this issue, submitted 3 patches for it. That was 18 months ago, I gave up.
http://trac.xbmc.org/ticket/10493
Reply
#7
Thanks teaguecl - looks like I dropped the ball on this one. I'll pull the patch up to date and see if anything else is needed.

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#8
Thinking through it a bit it's not as simple as the patch makes out unfortunately (relying on path alone fails for cases where the path is the same for multiple items - .cue sheets for example). Will branch and start work, but I don't expect it to be completed quickly.

I'll push the branch up to github once done in case someone else has time.

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#9
Ok, here's the branch:

https://github.com/jmarshallnz/xbmc/comm...elect_path

It needs some work. In particular:

1. Path alone isn't enough for checking items. You need to use something similar to CFileItem::IsSamePath, but there's some issues with that as well (you shouldn't assume that m_lStartOffset is essentail for matching - for video items it's not for example, for music items it is).

2. There will also be an item index being stored by the container itself (GUIBaseContainer subclasses) which will be being restored in CGUIWindow::OnInitWindow. I'm not sure if simply setting the item focus again after there (or indeed, not setting it before and only setting it after) is enough to cause no issues. In particular, there may be issues with lists animating on first entry due to changed focus position which may be noticeable - needs testing.

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply

Logout Mark Read Team Forum Stats Members Help
XBMC loses place in file list when files are added0