2011-04-03, 21:14
I'd like to prompt the user when a tv show ends or is stopped. Is there a way to create a dialog that appears when "stop" is pressed while a tv show is playing or if the tv show ends?
Window.Previous(FullScreenVideo) + !Player.HasVideo
<control type="radiobutton" id="2003">
<width>900</width>
<height>40</height>
<font>Simplicity_20</font>
<label>Enable "Delete" Prompt After Watching TV Episodes</label>
<textcolor>white</textcolor>
<focusedcolor>white</focusedcolor>
<radiowidth>83</radiowidth>
<radioheight>67</radioheight>
<textureradiofocus>simplicity/settings-radiobutton-on.png</textureradiofocus>
<textureradionofocus>simplicity/settings-radiobutton-off.png</textureradionofocus>
<texturefocus border="0,2,0,2">simplicity/button-focus.png</texturefocus>
<texturenofocus border="0,2,0,2">simplicity/menuitemnf.png</texturenofocus>
<onclick>Skin.ToggleSetting(DeleteEps)</onclick>
<selected>Skin.HasSetting(DeleteEps)</selected>
</control>
<control type="button" id="9999">
<description>trigger</description>
<include condition="!Skin.HasSetting(UseTvTunes)">No_TV_Tunes</include>
<include condition="Skin.HasSetting(UseTvTunes)">Use_TV_Tunes</include>
<include condition="Window.Previous(FullScreenVideo) + !Skin.HasSetting(DeleteEps)">No_Delete_Eps</include>
<include condition="Window.Previous(FullScreenVideo) + Skin.HasSetting(DeleteEps)">Delete_Eps</include>
<texturenofocus>-</texturenofocus>
<texturefocus>-</texturefocus>
</control>
<include name="No_Delete_Eps">
<onfocus>SetFocus(50)</onfocus>
</include>
<include name="Delete_Eps">
<visible>Container.Content(Episodes)</visible>
<onfocus>Delete</onfocus>
<onfocus>SetFocus(50)</onfocus>
</include>
wannabegt4 Wrote:What happens when someone isn't watching in fullscreen and presses stop? For instance I'm watching a video and decide to go back and look at the episode list while it's playing in the background.
wannabegt4 Wrote:Couldn't you just add the !Player.HasVideo to the condition that Jezz suggested that way it won't come up until stop is pressed. Also, What if the previous window isn't full screen video like I went to the home menu and pressed stop? Would you still get your dialog? Would you still want it to be available throughout the skin? That's the only reason I had thought about using the custom skin setting in the hidden control.
EDIT: You know; I'm probably over complicating things. I'm sure it's fine the way you have it now.
<onload condition="Container.Content(Episodes) + Window.Previous(FullScreenVideo) + Skin.HasSetting(DeleteEps)">Delete</onload>
<onload condition="Container.Content(Episodes) + Window.Previous(FullScreenVideo) + Skin.HasSetting(DeleteEps)">SetFocus(50)</onload>
(2011-04-05, 06:07)igotdvds Wrote:wannabegt4 Wrote:What happens when someone isn't watching in fullscreen and presses stop? For instance I'm watching a video and decide to go back and look at the episode list while it's playing in the background.
It will ask them if they want to delete. This is a rough way of getting what I wanted, I wish I could say "If episode is 100% finished or Episode is playing and user presses "stop"" Then prompt to delete. But I cant get that exactly, so I use a hack.
IntegerGreaterThan(ListItem.PercentPlayed,95)
<onload condition="Container.Content(Episodes) + Window.Previous(FullScreenVideo) + !Player.HasVideo + Skin.HasSetting(DeleteEps)">Delete</onload>
<onload condition="Container.Content(Episodes) + Window.Previous(FullScreenVideo) + !Player.HasVideo + Skin.HasSetting(DeleteEps)">SetFocus(50)</onload>