Loading app/src/main/java/app/fedilab/android/peertube/activities/PeertubeMainActivity.java +5 −2 Original line number Diff line number Diff line Loading @@ -114,7 +114,10 @@ public class PeertubeMainActivity extends PeertubeBaseMainActivity { public static InstanceData.InstanceConfig instanceConfig; public static TypeOfConnection typeOfConnection = TypeOfConnection.NORMAL; public static int badgeCount; private DisplayVideosFragment recentFragment, locaFragment, trendingFragment, subscriptionFragment, mostLikedFragment; private DisplayVideosFragment recentFragment; private DisplayVideosFragment locaFragment; private DisplayVideosFragment trendingFragment; private DisplayVideosFragment subscriptionFragment; private DisplayOverviewFragment overviewFragment; private ActivityMainPeertubeBinding binding; Loading Loading @@ -259,7 +262,7 @@ public class PeertubeMainActivity extends PeertubeBaseMainActivity { bundle.putSerializable(Helper.TIMELINE_TYPE, TimelineVM.TimelineType.SUBSCRIBTIONS); subscriptionFragment.setArguments(bundle); mostLikedFragment = new DisplayVideosFragment(); DisplayVideosFragment mostLikedFragment = new DisplayVideosFragment(); bundle = new Bundle(); bundle.putSerializable(Helper.TIMELINE_TYPE, TimelineVM.TimelineType.MOST_LIKED); mostLikedFragment.setArguments(bundle); Loading app/src/main/java/app/fedilab/android/peertube/drawer/AccountsListAdapter.java +4 −3 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Toast; Loading Loading @@ -72,7 +73,7 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH viewModel.post(RetrofitPeertubeAPI.ActionType.UNMUTE, account.getAcct(), null).observe((LifecycleOwner) context, apiResponse -> manageVIewPostActions(RetrofitPeertubeAPI.ActionType.UNMUTE, apiResponse, account.getAcct())); }); } else { holder.binding.accountAction.hide(); holder.binding.accountAction.setVisibility(View.GONE); } holder.binding.accountDn.setText(account.getDisplayName()); Loading @@ -84,8 +85,8 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH Helper.loadAvatar(context, account, holder.binding.accountPp); //Follow button if (type == RetrofitPeertubeAPI.DataType.MUTED) { holder.binding.accountAction.show(); holder.binding.accountAction.setImageResource(R.drawable.ic_baseline_volume_mute_24); holder.binding.accountAction.setVisibility(View.VISIBLE); holder.binding.accountAction.setIconResource(R.drawable.ic_baseline_volume_mute_24); } holder.binding.accountPp.setOnClickListener(v -> { Loading app/src/main/res/layouts/peertube/layout/drawer_account_peertube.xml +12 −13 Original line number Diff line number Diff line Loading @@ -14,8 +14,8 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/main_container" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -23,14 +23,14 @@ android:layout_marginBottom="5dp" android:orientation="horizontal"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/account_pp" android:layout_width="60dp" android:layout_height="60dp" android:layout_gravity="center_horizontal" android:contentDescription="@string/profile_picture" /> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/account_container" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -38,7 +38,7 @@ android:layout_weight="1" android:orientation="vertical"> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_dn" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -46,7 +46,7 @@ android:textAppearance="@style/TextAppearance.AppCompat.Body1" android:textSize="18sp" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_ac" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -56,19 +56,18 @@ android:textSize="16sp" /> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat> <com.google.android.material.floatingactionbutton.FloatingActionButton <com.google.android.material.button.MaterialButton android:id="@+id/account_action" style="@style/Widget.Material3.Button.OutlinedButton.Icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:layout_margin="5dp" android:layout_marginStart="10dp" android:contentDescription="@string/action_follow" android:gravity="center" android:scaleType="fitXY" android:visibility="gone" app:backgroundTint="?colorAccent" app:fabSize="mini" /> tools:visibility="visible" /> </LinearLayout> No newline at end of file </androidx.appcompat.widget.LinearLayoutCompat> No newline at end of file app/src/main/res/layouts/peertube/layout/drawer_channel_peertube.xml +9 −9 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/main_container" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -22,14 +22,14 @@ android:layout_marginBottom="5dp" android:orientation="horizontal"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/account_pp" android:layout_width="60dp" android:layout_height="60dp" android:layout_gravity="center_horizontal" android:contentDescription="@string/profile_picture" /> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/account_container" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -37,7 +37,7 @@ android:layout_weight="1" android:orientation="vertical"> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_dn" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -45,7 +45,7 @@ android:textAppearance="@style/TextAppearance.AppCompat.Body1" android:textSize="18sp" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_ac" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -54,15 +54,15 @@ android:singleLine="true" android:textSize="16sp" /> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat> <ImageButton <com.google.android.material.button.MaterialButton android:id="@+id/more_actions" style="@style/Widget.AppCompat.Button.Borderless" style="@style/Widget.Material3.Button.OutlinedButton.Icon" android:layout_width="40dp" android:layout_height="40dp" android:layout_gravity="center" android:contentDescription="@string/display_more" android:src="@drawable/ic_baseline_more_vert_24" /> </LinearLayout> No newline at end of file </androidx.appcompat.widget.LinearLayoutCompat> No newline at end of file app/src/main/res/layouts/peertube/layout/drawer_comment_peertube.xml +15 −16 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:id="@+id/main_container" android:layout_width="match_parent" Loading @@ -25,7 +25,7 @@ android:orientation="horizontal" android:showDividers="end"> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/decoration_container" android:layout_width="wrap_content" android:layout_height="match_parent" Loading @@ -40,7 +40,7 @@ android:layout_height="wrap_content" android:layout_marginStart="10dp"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/comment_account_profile" android:layout_width="40dp" android:layout_height="40dp" Loading @@ -50,7 +50,7 @@ app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_account_displayname" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -61,7 +61,7 @@ app:layout_constraintStart_toEndOf="@+id/comment_account_profile" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_account_username" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -74,7 +74,7 @@ app:layout_constraintStart_toEndOf="@+id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_account_displayname" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_date" android:layout_width="wrap_content" android:layout_height="wrap_content" Loading @@ -87,7 +87,7 @@ app:layout_constraintEnd_toStartOf="@id/more_actions" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/more_actions" android:layout_width="wrap_content" android:layout_height="wrap_content" Loading @@ -98,7 +98,7 @@ app:layout_constraintEnd_toEndOf="parent" app:layout_constraintTop_toBottomOf="@+id/comment_date" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_content" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -108,35 +108,34 @@ app:layout_constraintStart_toStartOf="@id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_account_profile" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/number_of_replies" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="15dp" android:textColor="?attr/colorAccent" android:textColor="?attr/colorPrimary" app:layout_constraintEnd_toStartOf="@+id/replyButton" app:layout_constraintStart_toStartOf="@id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_content" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/replyButton" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="10dp" android:text="@string/reply" android:textColor="?attr/colorAccent" android:textColor="?attr/colorPrimary" app:layout_constraintStart_toEndOf="@id/number_of_replies" app:layout_constraintTop_toTopOf="@+id/number_of_replies" /> <Button <com.google.android.material.button.MaterialButton android:id="@+id/post_reply_button" style="@style/Widget.AppCompat.Button.Borderless.Colored" style="@style/Widget.Material3.Button.OutlinedButton" android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" android:text="@string/add_public_reply" android:textColor="?attr/colorAccent" android:visibility="gone" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" Loading @@ -144,4 +143,4 @@ </androidx.constraintlayout.widget.ConstraintLayout> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat> Loading
app/src/main/java/app/fedilab/android/peertube/activities/PeertubeMainActivity.java +5 −2 Original line number Diff line number Diff line Loading @@ -114,7 +114,10 @@ public class PeertubeMainActivity extends PeertubeBaseMainActivity { public static InstanceData.InstanceConfig instanceConfig; public static TypeOfConnection typeOfConnection = TypeOfConnection.NORMAL; public static int badgeCount; private DisplayVideosFragment recentFragment, locaFragment, trendingFragment, subscriptionFragment, mostLikedFragment; private DisplayVideosFragment recentFragment; private DisplayVideosFragment locaFragment; private DisplayVideosFragment trendingFragment; private DisplayVideosFragment subscriptionFragment; private DisplayOverviewFragment overviewFragment; private ActivityMainPeertubeBinding binding; Loading Loading @@ -259,7 +262,7 @@ public class PeertubeMainActivity extends PeertubeBaseMainActivity { bundle.putSerializable(Helper.TIMELINE_TYPE, TimelineVM.TimelineType.SUBSCRIBTIONS); subscriptionFragment.setArguments(bundle); mostLikedFragment = new DisplayVideosFragment(); DisplayVideosFragment mostLikedFragment = new DisplayVideosFragment(); bundle = new Bundle(); bundle.putSerializable(Helper.TIMELINE_TYPE, TimelineVM.TimelineType.MOST_LIKED); mostLikedFragment.setArguments(bundle); Loading
app/src/main/java/app/fedilab/android/peertube/drawer/AccountsListAdapter.java +4 −3 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Toast; Loading Loading @@ -72,7 +73,7 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH viewModel.post(RetrofitPeertubeAPI.ActionType.UNMUTE, account.getAcct(), null).observe((LifecycleOwner) context, apiResponse -> manageVIewPostActions(RetrofitPeertubeAPI.ActionType.UNMUTE, apiResponse, account.getAcct())); }); } else { holder.binding.accountAction.hide(); holder.binding.accountAction.setVisibility(View.GONE); } holder.binding.accountDn.setText(account.getDisplayName()); Loading @@ -84,8 +85,8 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH Helper.loadAvatar(context, account, holder.binding.accountPp); //Follow button if (type == RetrofitPeertubeAPI.DataType.MUTED) { holder.binding.accountAction.show(); holder.binding.accountAction.setImageResource(R.drawable.ic_baseline_volume_mute_24); holder.binding.accountAction.setVisibility(View.VISIBLE); holder.binding.accountAction.setIconResource(R.drawable.ic_baseline_volume_mute_24); } holder.binding.accountPp.setOnClickListener(v -> { Loading
app/src/main/res/layouts/peertube/layout/drawer_account_peertube.xml +12 −13 Original line number Diff line number Diff line Loading @@ -14,8 +14,8 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/main_container" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -23,14 +23,14 @@ android:layout_marginBottom="5dp" android:orientation="horizontal"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/account_pp" android:layout_width="60dp" android:layout_height="60dp" android:layout_gravity="center_horizontal" android:contentDescription="@string/profile_picture" /> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/account_container" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -38,7 +38,7 @@ android:layout_weight="1" android:orientation="vertical"> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_dn" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -46,7 +46,7 @@ android:textAppearance="@style/TextAppearance.AppCompat.Body1" android:textSize="18sp" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_ac" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -56,19 +56,18 @@ android:textSize="16sp" /> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat> <com.google.android.material.floatingactionbutton.FloatingActionButton <com.google.android.material.button.MaterialButton android:id="@+id/account_action" style="@style/Widget.Material3.Button.OutlinedButton.Icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:layout_margin="5dp" android:layout_marginStart="10dp" android:contentDescription="@string/action_follow" android:gravity="center" android:scaleType="fitXY" android:visibility="gone" app:backgroundTint="?colorAccent" app:fabSize="mini" /> tools:visibility="visible" /> </LinearLayout> No newline at end of file </androidx.appcompat.widget.LinearLayoutCompat> No newline at end of file
app/src/main/res/layouts/peertube/layout/drawer_channel_peertube.xml +9 −9 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/main_container" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -22,14 +22,14 @@ android:layout_marginBottom="5dp" android:orientation="horizontal"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/account_pp" android:layout_width="60dp" android:layout_height="60dp" android:layout_gravity="center_horizontal" android:contentDescription="@string/profile_picture" /> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/account_container" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -37,7 +37,7 @@ android:layout_weight="1" android:orientation="vertical"> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_dn" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -45,7 +45,7 @@ android:textAppearance="@style/TextAppearance.AppCompat.Body1" android:textSize="18sp" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/account_ac" android:layout_width="match_parent" android:layout_height="wrap_content" Loading @@ -54,15 +54,15 @@ android:singleLine="true" android:textSize="16sp" /> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat> <ImageButton <com.google.android.material.button.MaterialButton android:id="@+id/more_actions" style="@style/Widget.AppCompat.Button.Borderless" style="@style/Widget.Material3.Button.OutlinedButton.Icon" android:layout_width="40dp" android:layout_height="40dp" android:layout_gravity="center" android:contentDescription="@string/display_more" android:src="@drawable/ic_baseline_more_vert_24" /> </LinearLayout> No newline at end of file </androidx.appcompat.widget.LinearLayoutCompat> No newline at end of file
app/src/main/res/layouts/peertube/layout/drawer_comment_peertube.xml +15 −16 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ You should have received a copy of the GNU General Public License along with Fedilab; if not, see <http://www.gnu.org/licenses>. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:id="@+id/main_container" android:layout_width="match_parent" Loading @@ -25,7 +25,7 @@ android:orientation="horizontal" android:showDividers="end"> <LinearLayout <androidx.appcompat.widget.LinearLayoutCompat android:id="@+id/decoration_container" android:layout_width="wrap_content" android:layout_height="match_parent" Loading @@ -40,7 +40,7 @@ android:layout_height="wrap_content" android:layout_marginStart="10dp"> <ImageView <androidx.appcompat.widget.AppCompatImageView android:id="@+id/comment_account_profile" android:layout_width="40dp" android:layout_height="40dp" Loading @@ -50,7 +50,7 @@ app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_account_displayname" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -61,7 +61,7 @@ app:layout_constraintStart_toEndOf="@+id/comment_account_profile" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_account_username" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -74,7 +74,7 @@ app:layout_constraintStart_toEndOf="@+id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_account_displayname" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_date" android:layout_width="wrap_content" android:layout_height="wrap_content" Loading @@ -87,7 +87,7 @@ app:layout_constraintEnd_toStartOf="@id/more_actions" app:layout_constraintTop_toTopOf="parent" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/more_actions" android:layout_width="wrap_content" android:layout_height="wrap_content" Loading @@ -98,7 +98,7 @@ app:layout_constraintEnd_toEndOf="parent" app:layout_constraintTop_toBottomOf="@+id/comment_date" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/comment_content" android:layout_width="0dp" android:layout_height="wrap_content" Loading @@ -108,35 +108,34 @@ app:layout_constraintStart_toStartOf="@id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_account_profile" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/number_of_replies" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="15dp" android:textColor="?attr/colorAccent" android:textColor="?attr/colorPrimary" app:layout_constraintEnd_toStartOf="@+id/replyButton" app:layout_constraintStart_toStartOf="@id/comment_account_profile" app:layout_constraintTop_toBottomOf="@+id/comment_content" /> <TextView <androidx.appcompat.widget.AppCompatTextView android:id="@+id/replyButton" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="10dp" android:text="@string/reply" android:textColor="?attr/colorAccent" android:textColor="?attr/colorPrimary" app:layout_constraintStart_toEndOf="@id/number_of_replies" app:layout_constraintTop_toTopOf="@+id/number_of_replies" /> <Button <com.google.android.material.button.MaterialButton android:id="@+id/post_reply_button" style="@style/Widget.AppCompat.Button.Borderless.Colored" style="@style/Widget.Material3.Button.OutlinedButton" android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" android:text="@string/add_public_reply" android:textColor="?attr/colorAccent" android:visibility="gone" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" Loading @@ -144,4 +143,4 @@ </androidx.constraintlayout.widget.ConstraintLayout> </LinearLayout> </androidx.appcompat.widget.LinearLayoutCompat>