xbmc/xbmc — pull request #4282 by Montellese (2014-02-26 17:21:16+00:00)
Title: Fix "Manage movie sets..." doing nothing when there are no sets available

These commits fix http://trac.xbmc.org/ticket/14922. As stated the problem is that when there are no sets defined yet in the video library, using the "Manage movie sets..." becomes a no-op instead of showing the select dialog with the "Add new movie set" button to allow creating a new set and adding the movie to that new set.

The first commit fixes the behaviour in GroupUtils::Group() to return true when grouping an empty list. IMO this is correct as the empty list has been grouped (nothing to group).

The second commit fixes CGUIDialogVideoInfo::GetSetForMovie() to not fail if there are no sets available.

The last commit fixes the focus problem in CGUIDialogSelect which happens when the dialog is opened with an empty list. By default an item in the list is auto-focused but that doesn't work properly if the list is empty. As a result nothing is focused and using arrow keys to focus something else (the extra button) does not work either. The fix sets focus to the extra button (if visible) if the list is empty.