2012-05-23, 01:26
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
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