-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[GSoC] Advanced Library Filtering #1399
Conversation
I've been waiting for this :-) |
a few oddities i came across after using it for some time:
|
@ronie: Thanks a lot for taking the time to test this. You're the first person to provide any real feedback and I'm grateful.
|
Damn sent to early. Now I was able to reproduce your description of the navigation. If you filter a list, then press ESC to get back to the home screen and then go back into the list it goes like this: Very odd. I'll have to look into it. What would you expect to happen with the filtered list when you hit ESC? Should the filter still be applied next time you enter the same list or should it be discareded and show the full list again? I guess these kind of behaviours need to be discussed a bit more. |
I pushed an update which fixes the "Clear" button not working and which also fixes the odd navigation issua ronie pointed out. |
After talking to @ronie and @cptspiff about how to integrate the old filtering and the advanced filtering into skins we realized that we can't get away with using the same button for both the old and the advanced filtering. On request of cptspiff I've added 3 new info booleans on Container level: Container.CanFilter, Container.CanFilterAdvanced and Container.Filtered which can be used by skins in visibility conditions for the two filter buttons. Furthermore the advanced filtering functionality is no longer tied to a specific button/control ID but can be triggered using the new "filter" action (which will either bring up the dialog for the old or the advanced filtering). |
And yet another update. I've known that staying on the currently selected item when changing a filter wasn't working because when changing the filter the path of every item changes (it always contains the current filter) but we use the path to identify the currently selected item. I added some code that should take care of this problem so when you filter (or clear a filter) it should just stay on the same item (unless the item doesn't match the filter anymore). |
@jmarshallnz Would be grateful if you could take a look at the code as you were/are the mentor of my project and let me know if it's ok for October or not (obviously after a rebase). |
Assigned to me |
Rebased onto latest master. |
Once again rebased. Still waiting on final review and/or "good to go". |
|
||
// don't create the filter if there's no real range | ||
if (min == max) | ||
break; |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
OK I have squashed the fix commits into the original ones (except for the ACTION_SELECT_ITEM one) and rebased onto latest master. There are two things left to do:
Any opinions on what is more intuitive for the navigation within the slider/range selector? My initial implementation followed the second option i.e. doing everything with "move up/down" keys and I've used that for a while now so I can't really judge if using Select/Enter/OK is more intuitive/easier to use. |
as mentioned on IRC I gave the navigation/handling of sliders a thought and have another proposal on how navigating them could work. It's just a proposal and I'm also fine with the "press select to switch between controls" thingy. Idea 1:This one will only work if we would add checkboxes to enable/disable filters. Disabled filters could be greyed out and their options probably also hidden until they are enabled. Given this, up/down will by default scroll through the list as they always do. Once a slider filter is enabled, left/right can be used to move between checkbox and the two slider handles. When focused on a slider handle, up/down can be used to indrease/decrease the value (move the slider). To scroll up/down in the list again one has to focus the checkbox (unfocus the slider handles). Idea 2:This also works without the additional checkboxes. up/down always navigate the list. When focusing a slider item, the first handle is focused. Switching between the handles can be done with left/right, just as expected. To move a handle it has to be "activated" by pressing enter (status needs to be visually indicated) . Once "activated" left/right can be used to move the slider - up/down will still navigate the list. To "deactivate" and switch to the other handle one has to either press select or back and can then switch between the handles with left/right again. The benefit of this behavior would be that it's almost like draging with the mouse - so click'n'drag (select = mouse-down, left/right = drag, second select/back = mouse up). Are just proposals/ideas - nothing more. Don't want to block this PR. |
I wonder whether up/down to move a left/right slider is counter-intuitive? I think it would be OK if there was a clear "click to activate" where the slider nib very clearly came into focus. However, it's not obvious to me that a further click would deactivate the slider, whilst still keeping it in effect (I might be tempted to hit BACK instead?) The click technique seemed natural enough when I first tried the UI, but as pointed out above - once you know, you know :) |
this is gonna be a long shot.... that being said, i'm fine with the current implementation as well. |
@ronie |
…s like genre, actors, studios etc
…list There are three new Container info booleans for skins: Container.CanFilter, Container.CanFilterAdvanced and Container.Filtered where CanFilter and CanFilterAdvanced are mutually exclusive. These can be used for visibility conditions of the existing "Filter" button and a new "Filter" button for advanced filtering. Furthermore a new action "filter" is available which will open the respective filter dialog depending on whether the container/list supports simple or advanced filtering.
…to a filtered list
OK jmarshall and I have decided that we will use the Select/Enter/OK button to switch between the range sliders for now as it requires less special handling. I have squashed that commit into the CGUISliderControl commit and everything should be merge-ready now. Anything else to squash down? |
{ | ||
hasNewItems = false; | ||
|
||
CFileItemList resultItems; |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
[GSoC] Advanced Library Filtering
Currently de slider for addon settings is broken |
Looks alright to me :-P Thanks for the report, I'll look into it. |
I checked all the addons I have installed (very few) and I only found two settings using a slider, both from screensavers (with a percentage value) and they work perfectly fine for me. Could you provide me with whatever addon shows that problem for you? |
something's wrong with this. When navigating to "recently added" the list first loads with the recently added items. The GetFilteredItems then overrides that by loading the complete movie list. Funny thing is that the real "recent" items get their thumb loaded - the others stay blank. The issue seems to be that the XPlaylist is not taking into account that this was just the "recently added" list, but thinks it's the entire movie list. |
Yeah I'm aware of the issue and have already fixed it locally. Still testing if there's any other odd behaviour because of the fix. |
Montellese, there's still something funky going on with the set thumbs. Especially, when you enter a set, not all thumbs get loaded, and then get back out of it, the set thumb is gone. So are the other sets... When you move the cursor, thumbs appear one at a time. |
Montellese, another issue: when you change the setting "group movies in sets", it only takes effect on the movie list when restarting xbmc. That used to work before. |
I have to look onto the thumb loading (again). |
Fixed the artwork problem (see cadede2) although it had nothing to do with this PR but with @jmarshallnz artwork changes. Don't go blaming everything on me :-P |
And 05593e4 takes care of the issue when changing the "Group movies in sets" setting. |
thanks so much for both fixes and apologies for the 'blame' - I was so focused on testing the filtering update that I forgot about the other major changes that had gone in. |
This caused some restricted connections to be dropped since a connection could have both CONNECTION_MYPLEX and CONNECTION_DISCOVERED set. Now we just check if we have token for the connection instead, it should give the same result, hiding discovered servers that doesn’t have a mapping. Related to xbmc#1399
Well this is it, the last PR from my GSoC 2012 work which will add the Advanced Library Filtering dialog to movie, tvshow, epsidode, musicvideo, artist, album and song views.
For team members: It's still with the "crappy" GUI integration. I've implemented the request to show the number of possible options for filters like genre, actors, directors etc next to the filter name so if there are 25 genres available to choose from for the current list of movies it will show "Genre [25]".