DialogSubtitles default focus
#1
I am trying to change the default focus in the DialogSubtitles service but whatever i've try the dialog keeps focusing on the subtitles services list.
Anyone has an idea ?

Why this is the default behavior ?. Would be more logical if the default focus was on the subtitles search results list ?

Cheers
Nessus
Reply
#2
What have you tried?

<defaultcontrol always="true"> or <onload>SetFocus(ID)>
Reply
#3
I've try defaultcontrol, onload setfocus and hidden fake button. None of them is working

Before Gotham i was opening the subtitles search results list and you could press left/right to bring up the subtitles services so you can choose another service. Now it loads the subtitles services options first and if i change the animation order so to show the subtitles search results first the results list shows fine but the focus is still goes on the subtitles services options.

Here is my code if anyone wants to take a look and in case that i am doing something wrong... http://pastebin.com/NdcNZKh9

Cheers
Nessus
Reply
#4
Its because id=120 (subs list) doesn't have any content on window load because it has to grab the content from the subtitle add-on.

I'm guessing the difference is that before xbmc would call the subs addon/script first and the .xml was skinning the script window, whereas now xbmc loads the DialogSubtitles.xml window and only uses the subtitle addons as content providers (that's my basic understanding anyway).

As 120 doesn't exist on load, the best you could do is put the manual search button (id160) at the top of the subs list and set that as the default control and have an <ondown>120</ondown> in it so you can press down to go to the subs once they load.
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#5
Thanks jurialmunkey. Unfortunately that doesn't work either.
The way that this thing is working now it needs to have always visible the services (id120) list. You cannot have it hidden by default and if you do you will loose focus. This means that we have to load and fill the screen with both list's at the same time.
Not looking good and IMHO not makes any sense to have the services list always visible. The user will set the default service once and he will change it only if no subtitle is available which for me happened rare times.

Is there any chance that this can be changed for Gotham ?

Cheers
Nessus
Reply
#6
If i hide id=150 (available subtitle services) then id="120" the available subtitles gets focus when it gets filled.
Code:
<defaultcontrol>120</defaultcontrol>

<control type="list" id="150"><!-- subtitle services list -->
    <visible>!IsEmpty(Container(120).ListItem.Label)</visible>
</control>
You could also try to open a custom dialog onload to re-apply focus.
Image [RELEASE] Metroid
Image [RELEASE] IrcChat
Reply
#7
MassIV... did you try to navigate up/down to the subtitles result list (id120)?. Because it looks like it has the focus (focus texture is visible) but actually the focus is on the hidden services list (id150).

If i am doing something wrong, please share your code ?

Cheers
Nessus
Reply
#8
I will work on this in core, we think its best to focus id 120 once we fill it in with results. so no xml mod is needed but you can always override it in skin if you dont like it.
Reply
#9
Thanks Amet. I agree with you. The best behavior is to focus on the id120 (subs search results) by default. If there were no subtitles available (empty id120 list) then the focus automatically goes to the subtitles services list (id150). After all that was the default behavior of the addon before Gotham.

Cheers
Nessus
Reply
#10
yes, and I'll add the PR for it tonight... hopefully it will make it into Gotham RC/beta 5 as it is bugfix rather than a feature
Reply
#11
Sweet Wink Looking forward for RC/beta 5 then.

Cheers
Nessus
Reply
#12
not going to happen -> https://github.com/xbmc/xbmc/pull/4591 sorry folks
Reply
#13
I'd suggest you all start complaining on github if not merged
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#14
(2014-04-23, 12:53)nessus Wrote: MassIV... did you try to navigate up/down to the subtitles result list (id120)?. Because it looks like it has the focus (focus texture is visible) but actually the focus is on the hidden services list (id150).

If i am doing something wrong, please share your code ?

Cheers
Nessus

Yeah, works for me on beta 4 on Windows.
https://github.com/MassIV/skin.metroid/b...titles.xml
Image [RELEASE] Metroid
Image [RELEASE] IrcChat
Reply
#15
Looks like (thanks to JM) this has made it to Gotham after all Smile

Thanks a lot guys.


Cheers
Nessus
Reply

Logout Mark Read Team Forum Stats Members Help
DialogSubtitles default focus0