Skip to content

Commit

Permalink
major view adjustments, change to Live365
Browse files Browse the repository at this point in the history
  • Loading branch information
rorpage committed Aug 16, 2019
1 parent cce3596 commit 40825c5
Show file tree
Hide file tree
Showing 11 changed files with 108 additions and 196 deletions.
2 changes: 1 addition & 1 deletion components/HomeScene.brs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ end sub
function ShowView(selectedIndex as integer)
viewToShow = "NTunesScene"

if selectedIndex = 0 then
if selectedIndex = 0 or selectedIndex = 1 then
updateTheme("0x121212FF")
end if

Expand Down
2 changes: 1 addition & 1 deletion components/HorizonsScene.brs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ sub OnWasShown()
m.left_side_row_2_status = m.top.findNode("left_side_row_2_status")

audiocontent = createObject("RoSGNode", "ContentNode")
audiocontent.url = "https://cdn3.wdwnt.com/music/Epcot%20-%20Horizons%20(Full%20Audio).mp3"
audiocontent.url = "https://appcdn.wdwnt.com/roku/music/Epcot%20-%20Horizons%20(Full%20Audio).mp3"

m.audio = m.top.findNode("audio")
m.audio.content = audiocontent
Expand Down
6 changes: 1 addition & 5 deletions components/NTunesScene.brs
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ function setUpLabels() as void
m.current_track_artist_name = m.top.findNode("current_track_artist_name")
m.current_show_name = m.top.findNode("current_show_name")
m.current_show_image_path = m.top.findNode("current_show_image_path")
m.next_track_title = m.top.findNode("next_track_title")
m.next_track_artist_name = m.top.findNode("next_track_artist_name")

m.audio_indicator = m.top.findNode("audio_indicator")
end function
Expand All @@ -40,7 +38,7 @@ end function

function setUpAudio() as void
audiocontent = createObject("RoSGNode", "ContentNode")
audiocontent.url = "https://wdwnt.out.airtime.pro/wdwnt_a"
audiocontent.url = "https://streaming.live365.com/a31769"

m.audio = m.top.findNode("audio_player")
m.audio.content = audiocontent
Expand Down Expand Up @@ -79,6 +77,4 @@ sub onCurrentInfoChanged()
m.current_track_artist_name.text = current_info.current_track_artist_name
m.current_show_name.text = current_info.current_show_name
m.current_show_image_path.uri = current_info.current_show_image_path
m.next_track_title.text = current_info.next_track_title
m.next_track_artist_name.text = current_info.next_track_artist_name
end sub
141 changes: 60 additions & 81 deletions components/NTunesScene.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,88 +2,67 @@
<component name="NTunesScene" extends="SGDEXComponent" xsi:noNamespaceSchemaLocation="https://devtools.web.roku.com/schema/RokuSceneGraph.xsd" initialFocus="audio_control_button">
<script type="text/brightscript" uri="pkg:/components/NTunesScene.brs" />
<children>
<Group id="ntunesGroup">
<Group id="artwork">
<Poster
id="current_show_image_path"
width="500"
height="500"
translation="[100, 100]" />
</Group>
<Group id="song_info" translation="[700, 100]">
<Label id="title" text="Now Playing" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_85_heavy_latin.ttf"
id="avenir-light"
size="80"
/>
</Label>
<LayoutGroup translation="[0, 120]">
<Label id="current_show_name" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30"
/>
</Label>
<Label id="current_track_title" text="Loading..." color="0xFFFFFFFF" width="1200" wrap="true">
<Font
role="font"
uri="pkg:/components/fonts/avenir_45_book_latin.ttf"
id="avenir-light"
size="65"
/>
</Label>
<Label id="current_track_artist_name" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="40"
/>
</Label>
</LayoutGroup>
<LayoutGroup translation="[0, 400]">
<Label id="next_track_info_title" text="Up Next" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_45_book_latin.ttf"
id="avenir-light"
size="45"
/>
</Label>
<Label id="next_track_title" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30"
/>
</Label>
<Label id="next_track_artist_name" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30"
/>
</Label>
</LayoutGroup>
</Group>
<Group id="audio_indicator_group" translation="[960, 900]">
<Label id="audio_indicator" text="N" color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/sosa-regular-webfont.ttf"
id="sosa-regular"
size="150"
/>
</Label>
</Group>
<Label id="title"
text="Now Playing"
color="0xFFFFFFFF"
translation="[20, 20]">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30"
/>
</Label>
<Poster
id="current_show_image_path"
width="500"
height="500"
translation="[710, 100]" />
<LayoutGroup translation="[0, 650]">
<Label id="current_show_name"
color="0xFFFFFFFF"
horizAlign="center"
width="1920">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30"
/>
</Label>
<Label id="current_track_title" text="Loading..."
color="0xFFFFFFFF"
horizAlign="center"
width="1920"
wrap="true">
<Font
role="font"
uri="pkg:/components/fonts/avenir_85_heavy_latin.ttf"
id="avenir-heavy-latin"
size="65"
/>
</Label>
<Label id="current_track_artist_name"
color="0xFFFFFFFF"
horizAlign="center"
width="1920">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="40"
/>
</Label>
<Label id="audio_indicator" text="N" color="0xFFFFFFFF" horizAlign="center" width="1920">
<Font
role="font"
uri="pkg:/components/fonts/sosa-regular-webfont.ttf"
id="sosa-regular"
size="150"
/>
</Label>
<Audio id="audio_player" />
<Timer id="refresh_timer" repeat="true" duration="10" />
</Group>
</LayoutGroup>
</children>
</component>
40 changes: 19 additions & 21 deletions components/PodcastScene.brs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ end sub

sub OnWasShown()
m.play_bar = m.top.findNode("play_bar")
m.show_art = m.top.findNode("show_art")
m.Play = m.top.findNode("Play")

' m.global.observeField("FF", "FF")
Expand Down Expand Up @@ -37,7 +36,6 @@ end function
sub updateFocused()
episode = getSelectedEpisode()

m.show_art.uri = episode.hdPosterUrl
m.episode_title.text = episode.title
m.episode_description.text = episode.Description
end sub
Expand All @@ -53,26 +51,26 @@ sub playaudio()
m.Play.text = "O"
end sub

sub controlaudioplay()
if (m.audio.state = "finished")
m.audio.control = "stop"
m.audio.control = "none"
m.Play.text = "N"
end if
end sub
' sub controlaudioplay()
' if (m.audio.state = "finished")
' m.audio.control = "stop"
' m.audio.control = "none"
' m.Play.text = "N"
' end if
' end sub

function onKeyEvent(key as String,press as Boolean) as Boolean
if press then
if key = "back"
if (m.audio.state = "playing")
m.audio.control = "stop"
m.Play.text = "N"
return true
end if
end if
end if
return false
end function
' function onKeyEvent(key as String,press as Boolean) as Boolean
' if press then
' if key = "back"
' if (m.audio.state = "playing")
' m.audio.control = "stop"
' m.Play.text = "N"
' return true
' end if
' end if
' end if
' return false
' end function

' sub FF()
' skip10Seconds(true)
Expand Down
87 changes: 13 additions & 74 deletions components/PodcastScene.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,24 @@
<Group>
<PosterGrid
id="audioLabelList"
translation="[20, 20]"
basePosterSize="[340, 340]"
itemSpacing="[16, 16]"
caption1NumLines="1"
numColumns="3"
numRows="2">
<Font
role="caption1Font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="30" />
height="1000"
translation="[40, 40]"
basePosterSize="[240, 240]"
itemSpacing="[10, 10]"
numColumns="4"
numRows="5">
</PosterGrid>
<LayoutGroup itemSpacings="[0, 40]" translation="[1100, 20]">
<LayoutGroup itemSpacings="[30]" translation="[1100, 40]">
<Label
id="episode_title"
width="800"
wrap="true"
color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="34" />
uri="pkg:/components/fonts/avenir_85_heavy_latin.ttf"
id="avenir-heavy-latin"
size="32" />
</Label>
<Label
id="episode_description"
Expand All @@ -36,67 +31,11 @@
color="0xFFFFFFFF">
<Font
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="28" />
uri="pkg:/components/fonts/avenir_45_book_latin.ttf"
id="avenir-book-latin"
size="24" />
</Label>
</LayoutGroup>
</Group>
<Group translation="[0, -30]">
<Rectangle
id="play_bar"
height="200"
width="1920"
color="0x000000FF"
opacity="0.8"
translation="[0,930]">
<Poster
id="show_art"
height="150"
width="150"
loadWidth="150"
loadHeight="150"
translation="[42, 15]" />
<Label
id="Play"
color="0xFFFFFFFF"
width="100"
height="120"
text="N"
translation="[910, 35]">
<Font
id="Sosa-Regular"
role="font"
uri="pkg:/components/fonts/sosa-regular-webfont.ttf"
size="90" />
</Label>
<Label
id="FF"
color="0xFFFFFFFF"
width="100"
height="120"
text="T"
translation="[810, 35]">
<Font
id="Sosa-Regular"
role="font"
uri="pkg:/components/fonts/sosa-regular-webfont.ttf"
size="90" />
</Label>
<Label
id="Rewind"
color="0xFFFFFFFF"
width="100"
height="120"
text="S"
translation="[1010, 35]">
<Font
id="Sosa-Regular"
role="font"
uri="pkg:/components/fonts/sosa-regular-webfont.ttf"
size="90" />
</Label>
</Rectangle>
</Group>
</children>
</component>
2 changes: 1 addition & 1 deletion components/TodayScene.brs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ end sub

sub changeAudioTrack()
audiocontent = createObject("RoSGNode", "ContentNode")
audiocontent.url = "https://cdn3.wdwnt.com/music/resort_tv/" + m.audio_track_index.ToStr() + ".mp3"
audiocontent.url = "https://appcdn.wdwnt.com/roku/music/resort_tv/" + m.audio_track_index.ToStr() + ".mp3"

m.audio.content = audiocontent
m.audio.control = "play"
Expand Down
2 changes: 1 addition & 1 deletion components/TodayScene.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
role="font"
uri="pkg:/components/fonts/avenir_35_light_latin.ttf"
id="avenir-light"
size="40"
size="30"
/>
</Label>
<Poster id="weather_icon" width="50" height="50" />
Expand Down
Loading

0 comments on commit 40825c5

Please sign in to comment.