jf-roku/source/Main.brs

31 lines
649 B
Plaintext
Raw Normal View History

2019-01-30 04:19:27 +00:00
sub Main()
keepalive = CreateObject("roSGScreen")
keepalive.show()
2019-03-05 04:59:31 +00:00
' First thing to do is validate the ability to use the API
start_login:
if get_setting("server") = invalid then
print "Get server details"
ShowServerSelect()
end if
2019-01-30 04:19:27 +00:00
if get_setting("active_user") = invalid then
print "Get user login"
ShowSigninSelect()
end if
2019-03-02 22:03:11 +00:00
2019-03-05 04:59:31 +00:00
' Confirm the configured server and user work
m.user = AboutMe()
if m.user.id <> get_setting("active_user")
print "Login failed, restart flow"
goto start_login
2019-03-05 04:59:31 +00:00
end if
2019-03-05 04:59:31 +00:00
ShowLibrarySelect()
2019-03-19 04:17:50 +00:00
if get_setting("active_user") = invalid
goto start_login
end if
2019-01-30 04:19:27 +00:00
end sub