mirror of
https://gitlab.futo.org/videostreaming/grayjay.git
synced 2025-08-16 07:20:59 +00:00
Merge branch 'master' of gitlab.futo.org:videostreaming/grayjay
This commit is contained in:
commit
23d7e8e5b6
10 changed files with 18 additions and 18 deletions
|
@ -290,8 +290,8 @@ class SubscriptionGroupFragment : MainFragment() {
|
||||||
image.setImageView(_imageGroup);
|
image.setImageView(_imageGroup);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
_imageGroupBackground.setImageResource(0);
|
_imageGroupBackground.setImageDrawable(null);
|
||||||
_imageGroup.setImageResource(0);
|
_imageGroup.setImageDrawable(null);
|
||||||
}
|
}
|
||||||
updateMeta();
|
updateMeta();
|
||||||
reloadCreators(group);
|
reloadCreators(group);
|
||||||
|
|
|
@ -383,7 +383,7 @@ class StateDownloads {
|
||||||
}
|
}
|
||||||
private fun validateDownload(videoState: VideoDownload) {
|
private fun validateDownload(videoState: VideoDownload) {
|
||||||
if(_downloading.hasItem { it.videoEither.url == videoState.videoEither.url })
|
if(_downloading.hasItem { it.videoEither.url == videoState.videoEither.url })
|
||||||
throw IllegalStateException("Video [${videoState.name}] is already queued for dowload");
|
throw IllegalStateException("Video [${videoState.name}] is already queued for download");
|
||||||
|
|
||||||
val existing = getCachedVideo(videoState.id);
|
val existing = getCachedVideo(videoState.id);
|
||||||
if(existing != null) {
|
if(existing != null) {
|
||||||
|
|
|
@ -126,7 +126,7 @@ open class PlaylistView : LinearLayout {
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
currentPlaylist = null;
|
currentPlaylist = null;
|
||||||
_imageThumbnail.setImageResource(0);
|
_imageThumbnail.setImageDrawable(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -76,8 +76,8 @@ class PreviewLockedView : LinearLayout {
|
||||||
_textLockedUrl.text = content.unlockUrl ?: "";
|
_textLockedUrl.text = content.unlockUrl ?: "";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
_imageChannelThumbnail.setImageResource(0);
|
_imageChannelThumbnail.setImageDrawable(null);
|
||||||
_imageVideoThumbnail.setImageResource(0);
|
_imageVideoThumbnail.setImageDrawable(null);
|
||||||
_textLockedDescription.text = "";
|
_textLockedDescription.text = "";
|
||||||
_textLockedUrl.text = "";
|
_textLockedUrl.text = "";
|
||||||
}
|
}
|
||||||
|
|
|
@ -233,7 +233,7 @@ open class PreviewVideoView : LinearLayout {
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
currentVideo = null;
|
currentVideo = null;
|
||||||
_imageVideo.setImageResource(0);
|
_imageVideo.setImageDrawable(null);
|
||||||
_containerDuration.visibility = GONE;
|
_containerDuration.visibility = GONE;
|
||||||
_containerLive.visibility = GONE;
|
_containerLive.visibility = GONE;
|
||||||
_timeBar?.visibility = GONE;
|
_timeBar?.visibility = GONE;
|
||||||
|
|
|
@ -47,7 +47,7 @@ class SubscriptionGroupBarViewHolder(private val _viewGroup: ViewGroup) : AnyAda
|
||||||
if(img != null) {
|
if(img != null) {
|
||||||
img.setImageView(_image)
|
img.setImageView(_image)
|
||||||
} else {
|
} else {
|
||||||
_image.setImageResource(0);
|
_image.setImageDrawable(null);
|
||||||
|
|
||||||
if(value is SubscriptionGroup.Add)
|
if(value is SubscriptionGroup.Add)
|
||||||
_image.setBackgroundColor(Color.DKGRAY);
|
_image.setBackgroundColor(Color.DKGRAY);
|
||||||
|
|
|
@ -88,7 +88,7 @@ class SubscriptionGroupListViewHolder(private val _viewGroup: ViewGroup) : AnyAd
|
||||||
if(img != null)
|
if(img != null)
|
||||||
img.setImageView(_image)
|
img.setImageView(_image)
|
||||||
else {
|
else {
|
||||||
_image.setImageResource(0);
|
_image.setImageDrawable(null);
|
||||||
|
|
||||||
if(value is SubscriptionGroup.Add)
|
if(value is SubscriptionGroup.Add)
|
||||||
_image.setBackgroundColor(Color.DKGRAY);
|
_image.setBackgroundColor(Color.DKGRAY);
|
||||||
|
|
|
@ -9,28 +9,28 @@ class PlatformIndicator : androidx.appcompat.widget.AppCompatImageView {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun clearPlatform() {
|
fun clearPlatform() {
|
||||||
setImageResource(0);
|
setImageDrawable(null);
|
||||||
}
|
}
|
||||||
fun setPlatformFromClientID(platformType : String?) {
|
fun setPlatformFromClientID(platformType : String?) {
|
||||||
if(platformType == null)
|
if(platformType == null)
|
||||||
setImageResource(0);
|
setImageDrawable(null);
|
||||||
else {
|
else {
|
||||||
val result = StatePlatform.instance.getPlatformIcon(platformType);
|
val result = StatePlatform.instance.getPlatformIcon(platformType);
|
||||||
if (result != null)
|
if (result != null)
|
||||||
result.setImageView(this);
|
result.setImageView(this);
|
||||||
else
|
else
|
||||||
setImageResource(0);
|
setImageDrawable(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
fun setPlatformFromClientName(name: String?) {
|
fun setPlatformFromClientName(name: String?) {
|
||||||
if(name == null)
|
if(name == null)
|
||||||
setImageResource(0);
|
setImageDrawable(null);
|
||||||
else {
|
else {
|
||||||
val result = StatePlatform.instance.getPlatformIconByName(name);
|
val result = StatePlatform.instance.getPlatformIconByName(name);
|
||||||
if (result != null)
|
if (result != null)
|
||||||
result.setImageView(this);
|
result.setImageView(this);
|
||||||
else
|
else
|
||||||
setImageResource(0);
|
setImageDrawable(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,6 +1,6 @@
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="65dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="52dp"
|
android:layout_height="52dp"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
|
@ -9,14 +9,14 @@
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/image_button"
|
android:id="@+id/image_button"
|
||||||
android:layout_width="25dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="25dp"
|
android:layout_height="25dp"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
tools:srcCompat="@drawable/ic_sources"/>
|
tools:srcCompat="@drawable/ic_sources"/>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/text_button"
|
android:id="@+id/text_button"
|
||||||
android:layout_width="65dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
tools:text="Home"
|
tools:text="Home"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 21afe43dffed9d4c7864420a7eb955f63d335d51
|
Subproject commit 3e99ed522a16300874e931bbcb86899aaebf1013
|
Loading…
Add table
Add a link
Reference in a new issue