mirror of
https://gitlab.futo.org/videostreaming/grayjay.git
synced 2025-04-20 11:35:46 +00:00
Open channel/playlist urls through search
This commit is contained in:
parent
c4bd5626f3
commit
d79e8b1339
1 changed files with 8 additions and 2 deletions
|
@ -154,8 +154,14 @@ class ContentSearchResultsFragment : MainFragment() {
|
|||
};
|
||||
|
||||
onSearch.subscribe(this) {
|
||||
if(it.isHttpUrl())
|
||||
navigate<VideoDetailFragment>(it);
|
||||
if(it.isHttpUrl()) {
|
||||
if(StatePlatform.instance.hasEnabledPlaylistClient(it))
|
||||
navigate<PlaylistFragment>(it);
|
||||
else if(StatePlatform.instance.hasEnabledChannelClient(it))
|
||||
navigate<ChannelFragment>(it);
|
||||
else
|
||||
navigate<VideoDetailFragment>(it);
|
||||
}
|
||||
else
|
||||
setQuery(it, true);
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue