diff options
author | Docile-Alligator <25734209+Docile-Alligator@users.noreply.github.com> | 2024-05-14 21:11:37 +0000 |
---|---|---|
committer | Docile-Alligator <25734209+Docile-Alligator@users.noreply.github.com> | 2024-05-14 21:11:37 +0000 |
commit | cc9880cadd93cccfc211fde90a73a4ce2113da81 (patch) | |
tree | 61d53295889dd0966cb0f280e3c997bdfe0a5c60 /app | |
parent | 9b6033b2dbfb750a8f8afc4ce86532b913abc434 (diff) | |
download | infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar.gz infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar.bz2 infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar.lz infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar.xz infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.tar.zst infinity-for-reddit-cc9880cadd93cccfc211fde90a73a4ce2113da81.zip |
Fix mute and resolution buttons not shown and not able to swipe vertically to finish in ViewVideoActivity.
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/ml/docilealligator/infinityforreddit/activities/ViewVideoActivity.java | 15 | ||||
-rw-r--r-- | app/src/main/res/layout/exo_playback_control_view.xml | 2 |
2 files changed, 14 insertions, 3 deletions
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/ViewVideoActivity.java b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/ViewVideoActivity.java index e6aa4e3f..bc5d96c0 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/ViewVideoActivity.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/ViewVideoActivity.java @@ -23,6 +23,7 @@ import android.os.Build; import android.os.Bundle; import android.os.Handler; import android.provider.Settings; +import android.util.Log; import android.view.Menu; import android.view.MenuItem; import android.view.OrientationEventListener; @@ -83,6 +84,7 @@ import javax.inject.Named; import javax.inject.Provider; import app.futured.hauler.DragDirection; +import app.futured.hauler.OnDragActivityListener; import ml.docilealligator.infinityforreddit.CustomFontReceiver; import ml.docilealligator.infinityforreddit.FetchRedgifsVideoLinks; import ml.docilealligator.infinityforreddit.FetchStreamableVideo; @@ -269,10 +271,10 @@ public class ViewVideoActivity extends AppCompatActivity implements CustomFontRe boolean zoomable = mSharedPreferences.getBoolean(SharedPreferencesUtils.PINCH_TO_ZOOM_VIDEO, false); if (zoomable) { binding = new ViewVideoActivityBindingAdapter(ActivityViewVideoZoomableBinding.inflate(getLayoutInflater())); - setContentView(R.layout.activity_view_video_zoomable); + setContentView(binding.getRoot()); } else { binding = new ViewVideoActivityBindingAdapter(ActivityViewVideoBinding.inflate(getLayoutInflater())); - setContentView(R.layout.activity_view_video); + setContentView(binding.getRoot()); } setVolumeControlStream(AudioManager.STREAM_MUSIC); @@ -346,6 +348,15 @@ public class ViewVideoActivity extends AppCompatActivity implements CustomFontRe }); } + + + binding.getRoot().setOnDragActivityListener(new OnDragActivityListener() { + @Override + public void onDrag(float v, float v1) { + Log.i("asdfasdf", "v " + v + " v1 " + v1); + } + }); + binding.getRoot().setOnDragDismissedListener(dragDirection -> { int slide = dragDirection == DragDirection.UP ? R.anim.slide_out_up : R.anim.slide_out_down; finish(); diff --git a/app/src/main/res/layout/exo_playback_control_view.xml b/app/src/main/res/layout/exo_playback_control_view.xml index 3f0fa176..0eb790ac 100644 --- a/app/src/main/res/layout/exo_playback_control_view.xml +++ b/app/src/main/res/layout/exo_playback_control_view.xml @@ -37,7 +37,7 @@ app:strokeWidth="0dp" app:iconSize="24dp" app:iconTint="@null" - app:backgroundTint="#10FFFFFF" + app:backgroundTint="#444141" android:visibility="gone" app:layout_constraintTop_toTopOf="parent" app:layout_constraintBottom_toBottomOf="parent" |