remove spinner lib
This commit is contained in:
parent
bf8543bc77
commit
fc34de1da4
@ -174,7 +174,6 @@ dependencies {
|
|||||||
implementation "net.gotev:uploadservice:4.5.1"
|
implementation "net.gotev:uploadservice:4.5.1"
|
||||||
implementation "net.gotev:uploadservice-okhttp:4.5.1"
|
implementation "net.gotev:uploadservice-okhttp:4.5.1"
|
||||||
implementation 'androidx.media:media:1.6.0'
|
implementation 'androidx.media:media:1.6.0'
|
||||||
implementation 'com.github.ybq:Android-SpinKit:1.4.0'
|
|
||||||
implementation 'com.github.mancj:MaterialSearchBar:0.8.5'
|
implementation 'com.github.mancj:MaterialSearchBar:0.8.5'
|
||||||
|
|
||||||
implementation 'com.github.vkay94:DoubleTapPlayerView:1.0.0'
|
implementation 'com.github.vkay94:DoubleTapPlayerView:1.0.0'
|
||||||
|
@ -37,13 +37,12 @@
|
|||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
android:id="@+id/cast_loader_small"
|
android:id="@+id/cast_loader_small"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="18dp"
|
android:layout_height="18dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:layout_marginStart="5dp"
|
android:layout_marginStart="5dp"
|
||||||
app:SpinKit_Color="?colorAccent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toEndOf="@+id/cast_loader_text"
|
app:layout_constraintStart_toEndOf="@+id/cast_loader_text"
|
||||||
|
@ -18,11 +18,7 @@ import android.content.Context;
|
|||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.LinearLayout;
|
|
||||||
import android.widget.TextView;
|
|
||||||
import android.widget.Toast;
|
import android.widget.Toast;
|
||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
@ -31,11 +27,10 @@ import androidx.lifecycle.ViewModelProvider;
|
|||||||
import androidx.lifecycle.ViewModelStoreOwner;
|
import androidx.lifecycle.ViewModelStoreOwner;
|
||||||
import androidx.recyclerview.widget.RecyclerView;
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
import com.google.android.material.floatingactionbutton.FloatingActionButton;
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import app.fedilab.android.R;
|
import app.fedilab.android.R;
|
||||||
|
import app.fedilab.android.databinding.DrawerAccountPeertubeBinding;
|
||||||
import app.fedilab.android.peertube.activities.ShowAccountActivity;
|
import app.fedilab.android.peertube.activities.ShowAccountActivity;
|
||||||
import app.fedilab.android.peertube.client.APIResponse;
|
import app.fedilab.android.peertube.client.APIResponse;
|
||||||
import app.fedilab.android.peertube.client.RetrofitPeertubeAPI;
|
import app.fedilab.android.peertube.client.RetrofitPeertubeAPI;
|
||||||
@ -63,37 +58,37 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
|
|||||||
@Override
|
@Override
|
||||||
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||||
context = parent.getContext();
|
context = parent.getContext();
|
||||||
LayoutInflater layoutInflater = LayoutInflater.from(context);
|
DrawerAccountPeertubeBinding itemBinding = DrawerAccountPeertubeBinding.inflate(LayoutInflater.from(parent.getContext()), parent, false);
|
||||||
return new ViewHolder(layoutInflater.inflate(R.layout.drawer_account, parent, false));
|
return new AccountViewHolder(itemBinding);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
||||||
final ViewHolder holder = (ViewHolder) viewHolder;
|
final AccountViewHolder holder = (AccountViewHolder) viewHolder;
|
||||||
final AccountData.PeertubeAccount account = accounts.get(position);
|
final AccountData.PeertubeAccount account = accounts.get(position);
|
||||||
if (type == RetrofitPeertubeAPI.DataType.MUTED) {
|
if (type == RetrofitPeertubeAPI.DataType.MUTED) {
|
||||||
holder.account_action.setOnClickListener(v -> {
|
holder.binding.accountAction.setOnClickListener(v -> {
|
||||||
PostActionsVM viewModel = new ViewModelProvider((ViewModelStoreOwner) context).get(PostActionsVM.class);
|
PostActionsVM viewModel = new ViewModelProvider((ViewModelStoreOwner) context).get(PostActionsVM.class);
|
||||||
viewModel.post(RetrofitPeertubeAPI.ActionType.UNMUTE, account.getAcct(), null).observe((LifecycleOwner) context, apiResponse -> manageVIewPostActions(RetrofitPeertubeAPI.ActionType.UNMUTE, apiResponse, account.getAcct()));
|
viewModel.post(RetrofitPeertubeAPI.ActionType.UNMUTE, account.getAcct(), null).observe((LifecycleOwner) context, apiResponse -> manageVIewPostActions(RetrofitPeertubeAPI.ActionType.UNMUTE, apiResponse, account.getAcct()));
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
holder.account_action.hide();
|
holder.binding.accountAction.hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
holder.account_dn.setText(account.getDisplayName());
|
holder.binding.accountDn.setText(account.getDisplayName());
|
||||||
holder.account_ac.setText(String.format("@%s", account.getAcct()));
|
holder.binding.accountAc.setText(String.format("@%s", account.getAcct()));
|
||||||
if (account.getDescription() == null) {
|
if (account.getDescription() == null) {
|
||||||
account.setDescription("");
|
account.setDescription("");
|
||||||
}
|
}
|
||||||
//Profile picture
|
//Profile picture
|
||||||
Helper.loadAvatar(context, account, holder.account_pp);
|
Helper.loadAvatar(context, account, holder.binding.accountPp);
|
||||||
//Follow button
|
//Follow button
|
||||||
if (type == RetrofitPeertubeAPI.DataType.MUTED) {
|
if (type == RetrofitPeertubeAPI.DataType.MUTED) {
|
||||||
holder.account_action.show();
|
holder.binding.accountAction.show();
|
||||||
holder.account_action.setImageResource(R.drawable.ic_baseline_volume_mute_24);
|
holder.binding.accountAction.setImageResource(R.drawable.ic_baseline_volume_mute_24);
|
||||||
}
|
}
|
||||||
|
|
||||||
holder.account_pp.setOnClickListener(v -> {
|
holder.binding.accountPp.setOnClickListener(v -> {
|
||||||
Intent intent = new Intent(context, ShowAccountActivity.class);
|
Intent intent = new Intent(context, ShowAccountActivity.class);
|
||||||
Bundle b = new Bundle();
|
Bundle b = new Bundle();
|
||||||
b.putSerializable("account", account);
|
b.putSerializable("account", account);
|
||||||
@ -142,21 +137,12 @@ public class AccountsListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private static class ViewHolder extends RecyclerView.ViewHolder {
|
public static class AccountViewHolder extends RecyclerView.ViewHolder {
|
||||||
ImageView account_pp;
|
DrawerAccountPeertubeBinding binding;
|
||||||
TextView account_ac;
|
|
||||||
TextView account_dn;
|
|
||||||
FloatingActionButton account_action;
|
|
||||||
LinearLayout account_container;
|
|
||||||
|
|
||||||
ViewHolder(View itemView) {
|
AccountViewHolder(DrawerAccountPeertubeBinding itemView) {
|
||||||
super(itemView);
|
super(itemView.getRoot());
|
||||||
account_pp = itemView.findViewById(R.id.account_pp);
|
binding = itemView;
|
||||||
account_dn = itemView.findViewById(R.id.account_dn);
|
|
||||||
account_ac = itemView.findViewById(R.id.account_ac);
|
|
||||||
account_action = itemView.findViewById(R.id.account_action);
|
|
||||||
account_container = itemView.findViewById(R.id.account_container);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -22,15 +22,9 @@ import android.content.Context;
|
|||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.content.SharedPreferences;
|
import android.content.SharedPreferences;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.os.Handler;
|
|
||||||
import android.os.Looper;
|
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.ImageButton;
|
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.LinearLayout;
|
|
||||||
import android.widget.TextView;
|
|
||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
import androidx.appcompat.widget.PopupMenu;
|
import androidx.appcompat.widget.PopupMenu;
|
||||||
@ -42,6 +36,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import app.fedilab.android.R;
|
import app.fedilab.android.R;
|
||||||
|
import app.fedilab.android.databinding.DrawerChannelPeertubeBinding;
|
||||||
import app.fedilab.android.peertube.activities.AccountActivity;
|
import app.fedilab.android.peertube.activities.AccountActivity;
|
||||||
import app.fedilab.android.peertube.activities.ShowChannelActivity;
|
import app.fedilab.android.peertube.activities.ShowChannelActivity;
|
||||||
import app.fedilab.android.peertube.client.RetrofitPeertubeAPI;
|
import app.fedilab.android.peertube.client.RetrofitPeertubeAPI;
|
||||||
@ -65,28 +60,28 @@ public class ChannelListAdapter extends RecyclerView.Adapter<RecyclerView.ViewHo
|
|||||||
@Override
|
@Override
|
||||||
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||||
context = parent.getContext();
|
context = parent.getContext();
|
||||||
LayoutInflater layoutInflater = LayoutInflater.from(context);
|
DrawerChannelPeertubeBinding itemBinding = DrawerChannelPeertubeBinding.inflate(LayoutInflater.from(parent.getContext()), parent, false);
|
||||||
return new ViewHolder(layoutInflater.inflate(R.layout.drawer_channel_peertube, parent, false));
|
return new ChannelViewHolder(itemBinding);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
||||||
final ViewHolder holder = (ViewHolder) viewHolder;
|
ChannelViewHolder holder = (ChannelViewHolder) viewHolder;
|
||||||
final Channel channel = channels.get(position);
|
final Channel channel = channels.get(position);
|
||||||
holder.account_dn.setText(channel.getDisplayName());
|
holder.binding.accountDn.setText(channel.getDisplayName());
|
||||||
holder.account_ac.setText(String.format("@%s", channel.getAcct()));
|
holder.binding.accountAc.setText(String.format("@%s", channel.getAcct()));
|
||||||
if (channel.getDescription() == null) {
|
if (channel.getDescription() == null) {
|
||||||
channel.setDescription("");
|
channel.setDescription("");
|
||||||
}
|
}
|
||||||
|
|
||||||
//Profile picture
|
//Profile picture
|
||||||
Helper.loadAvatar(context, channel, holder.account_pp);
|
Helper.loadAvatar(context, channel, holder.binding.accountPp);
|
||||||
|
|
||||||
if (!isMyChannel(channel)) {
|
if (!isMyChannel(channel)) {
|
||||||
holder.more_actions.setVisibility(View.GONE);
|
holder.binding.moreActions.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
holder.more_actions.setOnClickListener(view -> {
|
holder.binding.moreActions.setOnClickListener(view -> {
|
||||||
PopupMenu popup = new PopupMenu(context, holder.more_actions);
|
PopupMenu popup = new PopupMenu(context, holder.binding.moreActions);
|
||||||
popup.getMenuInflater()
|
popup.getMenuInflater()
|
||||||
.inflate(R.menu.playlist_menu_peertube, popup.getMenu());
|
.inflate(R.menu.playlist_menu_peertube, popup.getMenu());
|
||||||
if (channels.size() == 1) {
|
if (channels.size() == 1) {
|
||||||
@ -100,18 +95,12 @@ public class ChannelListAdapter extends RecyclerView.Adapter<RecyclerView.ViewHo
|
|||||||
builder.setMessage(context.getString(R.string.action_channel_confirm_delete));
|
builder.setMessage(context.getString(R.string.action_channel_confirm_delete));
|
||||||
builder.setIcon(android.R.drawable.ic_dialog_alert)
|
builder.setIcon(android.R.drawable.ic_dialog_alert)
|
||||||
.setPositiveButton(R.string.yes, (dialog, which) -> {
|
.setPositiveButton(R.string.yes, (dialog, which) -> {
|
||||||
new Thread(() -> {
|
new Thread(() -> new RetrofitPeertubeAPI(context).post(RetrofitPeertubeAPI.ActionType.DELETE_CHANNEL, channel.getName(), null)).start();
|
||||||
new RetrofitPeertubeAPI(context).post(RetrofitPeertubeAPI.ActionType.DELETE_CHANNEL, channel.getName(), null);
|
channels.remove(channel);
|
||||||
Handler mainHandler = new Handler(Looper.getMainLooper());
|
notifyItemRemoved(position);
|
||||||
Runnable myRunnable = () -> {
|
if (channels.size() == 0) {
|
||||||
channels.remove(channel);
|
allChannelRemoved.onAllChannelRemoved();
|
||||||
notifyDataSetChanged();
|
}
|
||||||
if (channels.size() == 0) {
|
|
||||||
allChannelRemoved.onAllChannelRemoved();
|
|
||||||
}
|
|
||||||
};
|
|
||||||
mainHandler.post(myRunnable);
|
|
||||||
}).start();
|
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.setNegativeButton(R.string.no, (dialog, which) -> dialog.dismiss())
|
.setNegativeButton(R.string.no, (dialog, which) -> dialog.dismiss())
|
||||||
@ -126,7 +115,7 @@ public class ChannelListAdapter extends RecyclerView.Adapter<RecyclerView.ViewHo
|
|||||||
popup.show();
|
popup.show();
|
||||||
});
|
});
|
||||||
|
|
||||||
holder.account_pp.setOnClickListener(v -> {
|
holder.binding.accountPp.setOnClickListener(v -> {
|
||||||
Intent intent = new Intent(context, ShowChannelActivity.class);
|
Intent intent = new Intent(context, ShowChannelActivity.class);
|
||||||
Bundle b = new Bundle();
|
Bundle b = new Bundle();
|
||||||
b.putSerializable("channel", channel);
|
b.putSerializable("channel", channel);
|
||||||
@ -174,20 +163,12 @@ public class ChannelListAdapter extends RecyclerView.Adapter<RecyclerView.ViewHo
|
|||||||
void show(Channel channel);
|
void show(Channel channel);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static class ViewHolder extends RecyclerView.ViewHolder {
|
public static class ChannelViewHolder extends RecyclerView.ViewHolder {
|
||||||
ImageView account_pp;
|
DrawerChannelPeertubeBinding binding;
|
||||||
TextView account_ac;
|
|
||||||
TextView account_dn;
|
|
||||||
ImageButton more_actions;
|
|
||||||
LinearLayout account_container;
|
|
||||||
|
|
||||||
ViewHolder(View itemView) {
|
ChannelViewHolder(DrawerChannelPeertubeBinding itemView) {
|
||||||
super(itemView);
|
super(itemView.getRoot());
|
||||||
account_pp = itemView.findViewById(R.id.account_pp);
|
binding = itemView;
|
||||||
account_dn = itemView.findViewById(R.id.account_dn);
|
|
||||||
account_ac = itemView.findViewById(R.id.account_ac);
|
|
||||||
more_actions = itemView.findViewById(R.id.more_actions);
|
|
||||||
account_container = itemView.findViewById(R.id.account_container);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -61,12 +61,10 @@
|
|||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="gone">
|
android:visibility="gone">
|
||||||
|
<ProgressBar
|
||||||
<com.github.ybq.android.spinkit.SpinKitView xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
<!-- Loader for next items -->
|
<!-- Loader for next items -->
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
@ -78,11 +76,10 @@
|
|||||||
android:gravity="bottom|center_horizontal"
|
android:gravity="bottom|center_horizontal"
|
||||||
android:visibility="gone">
|
android:visibility="gone">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView xmlns:app="http://schemas.android.com/apk/res-auto"
|
<ProgressBar
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
@ -118,11 +118,10 @@
|
|||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/filters_container">
|
app:layout_constraintTop_toBottomOf="@+id/filters_container">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -56,11 +56,10 @@
|
|||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="gone">
|
android:visibility="gone">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||||
|
@ -96,8 +96,7 @@
|
|||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="gone">
|
android:visibility="gone">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
style="@style/SpinKitView.DoubleBounce"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center" />
|
android:layout_gravity="center" />
|
||||||
|
@ -32,9 +32,7 @@
|
|||||||
<com.google.android.material.appbar.CollapsingToolbarLayout
|
<com.google.android.material.appbar.CollapsingToolbarLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?android:colorBackground"
|
|
||||||
android:fitsSystemWindows="true"
|
android:fitsSystemWindows="true"
|
||||||
app:contentScrim="?attr/colorPrimary"
|
|
||||||
app:expandedTitleMarginEnd="64dp"
|
app:expandedTitleMarginEnd="64dp"
|
||||||
app:expandedTitleMarginStart="48dp"
|
app:expandedTitleMarginStart="48dp"
|
||||||
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
||||||
@ -61,36 +59,33 @@
|
|||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:mt_backIconTint="?attr/colorAccent"
|
|
||||||
app:mt_clearIconTint="?attr/colorAccent"
|
|
||||||
app:mt_hint="@string/sepia_search_hint"
|
app:mt_hint="@string/sepia_search_hint"
|
||||||
app:mt_maxSuggestionsCount="10"
|
app:mt_maxSuggestionsCount="10"
|
||||||
app:mt_menuIconTint="?attr/colorAccent"
|
|
||||||
app:mt_searchIconTint="?attr/colorAccent"
|
|
||||||
app:mt_speechMode="false" />
|
app:mt_speechMode="false" />
|
||||||
|
|
||||||
<TextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/explanations"
|
android:id="@+id/explanations"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="5dp"
|
android:layout_marginTop="10dp"
|
||||||
android:text="@string/sepia_indication"
|
android:text="@string/sepia_indication"
|
||||||
android:textColor="?attr/colorAccent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/searchBar" />
|
app:layout_constraintTop_toBottomOf="@+id/searchBar" />
|
||||||
|
|
||||||
<Button
|
<com.google.android.material.button.MaterialButton
|
||||||
android:id="@+id/filter"
|
android:id="@+id/filter"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
style="@style/Widget.Material3.Button.OutlinedButton.Icon"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:drawableEnd="@drawable/ic_baseline_arrow_drop_down_24"
|
android:drawableEnd="@drawable/ic_baseline_arrow_drop_down_24"
|
||||||
android:text="@string/filter"
|
android:text="@string/filter"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/explanations" />
|
app:layout_constraintTop_toBottomOf="@+id/explanations" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:labelFor="@+id/sort_by"
|
android:labelFor="@+id/sort_by"
|
||||||
@ -100,6 +95,7 @@
|
|||||||
app:layout_constraintTop_toBottomOf="@+id/explanations" />
|
app:layout_constraintTop_toBottomOf="@+id/explanations" />
|
||||||
|
|
||||||
<Spinner
|
<Spinner
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
android:id="@+id/sort_by"
|
android:id="@+id/sort_by"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -149,7 +145,7 @@
|
|||||||
android:text="@string/no" />
|
android:text="@string/no" />
|
||||||
</RadioGroup>
|
</RadioGroup>
|
||||||
|
|
||||||
<TextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/sepia_element_published_date_label"
|
android:id="@+id/sepia_element_published_date_label"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -288,7 +284,7 @@
|
|||||||
app:layout_constraintStart_toStartOf="@+id/sepia_element_license_label"
|
app:layout_constraintStart_toStartOf="@+id/sepia_element_license_label"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/sepia_element_license_label" />
|
app:layout_constraintTop_toBottomOf="@+id/sepia_element_license_label" />
|
||||||
|
|
||||||
<TextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/sepia_element_language_label"
|
android:id="@+id/sepia_element_language_label"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -305,7 +301,7 @@
|
|||||||
app:layout_constraintStart_toStartOf="@+id/sepia_element_language_label"
|
app:layout_constraintStart_toStartOf="@+id/sepia_element_language_label"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/sepia_element_language_label" />
|
app:layout_constraintTop_toBottomOf="@+id/sepia_element_language_label" />
|
||||||
|
|
||||||
<TextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/sepia_element_all_of_tags_label"
|
android:id="@+id/sepia_element_all_of_tags_label"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -325,7 +321,7 @@
|
|||||||
TagsEditText:allowSpaceInTag="true"
|
TagsEditText:allowSpaceInTag="true"
|
||||||
TagsEditText:tagsCloseImagePadding="@dimen/defaultTagsCloseImagePadding"
|
TagsEditText:tagsCloseImagePadding="@dimen/defaultTagsCloseImagePadding"
|
||||||
TagsEditText:tagsCloseImageRight="@drawable/tag_close"
|
TagsEditText:tagsCloseImageRight="@drawable/tag_close"
|
||||||
TagsEditText:tagsTextColor="?colorAccent"
|
TagsEditText:tagsTextColor="?colorSecondary"
|
||||||
TagsEditText:tagsTextSize="@dimen/defaultTagsTextSize"
|
TagsEditText:tagsTextSize="@dimen/defaultTagsTextSize"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
@ -352,7 +348,7 @@
|
|||||||
TagsEditText:allowSpaceInTag="true"
|
TagsEditText:allowSpaceInTag="true"
|
||||||
TagsEditText:tagsCloseImagePadding="@dimen/defaultTagsCloseImagePadding"
|
TagsEditText:tagsCloseImagePadding="@dimen/defaultTagsCloseImagePadding"
|
||||||
TagsEditText:tagsCloseImageRight="@drawable/tag_close"
|
TagsEditText:tagsCloseImageRight="@drawable/tag_close"
|
||||||
TagsEditText:tagsTextColor="?colorAccent"
|
TagsEditText:tagsTextColor="?colorSecondary"
|
||||||
TagsEditText:tagsTextSize="@dimen/defaultTagsTextSize"
|
TagsEditText:tagsTextSize="@dimen/defaultTagsTextSize"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
@ -25,14 +25,12 @@
|
|||||||
<com.google.android.material.appbar.AppBarLayout
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:fitsSystemWindows="true"
|
android:fitsSystemWindows="true">
|
||||||
app:theme="@style/ThemeOverlay.AppCompat.ActionBar">
|
|
||||||
|
|
||||||
<com.google.android.material.appbar.CollapsingToolbarLayout
|
<com.google.android.material.appbar.CollapsingToolbarLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:fitsSystemWindows="true"
|
android:fitsSystemWindows="true"
|
||||||
app:contentScrim="?attr/colorPrimary"
|
|
||||||
app:expandedTitleMarginEnd="64dp"
|
app:expandedTitleMarginEnd="64dp"
|
||||||
app:expandedTitleMarginStart="48dp"
|
app:expandedTitleMarginStart="48dp"
|
||||||
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
||||||
@ -50,6 +48,7 @@
|
|||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/account_pp"
|
android:id="@+id/account_pp"
|
||||||
android:layout_width="80dp"
|
android:layout_width="80dp"
|
||||||
|
tools:src="@tools:sample/avatars"
|
||||||
android:layout_height="80dp"
|
android:layout_height="80dp"
|
||||||
android:layout_margin="10dp"
|
android:layout_margin="10dp"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="10dp"
|
||||||
@ -66,7 +65,6 @@
|
|||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
|
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
|
||||||
android:textColor="@android:color/white"
|
|
||||||
android:textSize="18sp"
|
android:textSize="18sp"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/subscriber_count"
|
app:layout_constraintBottom_toTopOf="@+id/subscriber_count"
|
||||||
app:layout_constraintStart_toEndOf="@+id/account_pp"
|
app:layout_constraintStart_toEndOf="@+id/account_pp"
|
||||||
@ -81,26 +79,26 @@
|
|||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
|
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
|
||||||
android:textColor="@android:color/white"
|
|
||||||
android:visibility="invisible"
|
android:visibility="invisible"
|
||||||
app:layout_constraintBottom_toBottomOf="@id/account_follow"
|
app:layout_constraintBottom_toBottomOf="@id/account_follow"
|
||||||
app:layout_constraintStart_toEndOf="@+id/account_pp"
|
app:layout_constraintStart_toEndOf="@+id/account_pp"
|
||||||
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
||||||
|
|
||||||
<Button
|
<com.google.android.material.button.MaterialButton
|
||||||
android:id="@+id/account_follow"
|
android:id="@+id/account_follow"
|
||||||
style="@style/Widget.AppCompat.Button.Colored"
|
style="@style/Widget.Material3.Button"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:contentDescription="@string/make_an_action"
|
android:contentDescription="@string/make_an_action"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintStart_toEndOf="@id/subscriber_count"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
tools:visibility="visible"
|
||||||
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
||||||
|
|
||||||
<Button
|
<com.google.android.material.button.MaterialButton
|
||||||
style="@style/Widget.AppCompat.Button.Colored"
|
style="@style/Widget.Material3.Button"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
@ -108,13 +106,14 @@
|
|||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:src="@drawable/ic_baseline_edit_24"
|
android:src="@drawable/ic_baseline_edit_24"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintStart_toEndOf="@id/subscriber_count"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
tools:visibility="visible"
|
||||||
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
app:layout_constraintTop_toBottomOf="@id/account_dn" />
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_below="@+id/top_banner"
|
android:layout_below="@+id/top_banner"
|
||||||
@ -123,17 +122,16 @@
|
|||||||
android:paddingTop="8dp"
|
android:paddingTop="8dp"
|
||||||
app:layout_scrollFlags="scroll|enterAlways">
|
app:layout_scrollFlags="scroll|enterAlways">
|
||||||
|
|
||||||
<TextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/account_note"
|
android:id="@+id/account_note"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="5dp"
|
android:layout_marginTop="5dp"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:padding="10dp"
|
android:padding="10dp"
|
||||||
android:textColor="@android:color/white"
|
|
||||||
android:textIsSelectable="true"
|
android:textIsSelectable="true"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
</LinearLayout>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
|
||||||
@ -145,9 +143,7 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:tabGravity="fill"
|
app:tabGravity="fill"
|
||||||
app:tabMode="fixed"
|
app:tabMode="fixed" />
|
||||||
app:tabSelectedTextColor="?colorAccent"
|
|
||||||
app:tabTextColor="@android:color/white" />
|
|
||||||
</com.google.android.material.appbar.AppBarLayout>
|
</com.google.android.material.appbar.AppBarLayout>
|
||||||
|
|
||||||
<androidx.viewpager.widget.ViewPager
|
<androidx.viewpager.widget.ViewPager
|
||||||
@ -164,7 +160,6 @@
|
|||||||
android:layout_gravity="bottom|end"
|
android:layout_gravity="bottom|end"
|
||||||
android:layout_margin="@dimen/fab_margin"
|
android:layout_margin="@dimen/fab_margin"
|
||||||
android:src="@drawable/ic_baseline_add_24"
|
android:src="@drawable/ic_baseline_add_24"
|
||||||
android:tint="@android:color/white"
|
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
@ -100,11 +100,10 @@
|
|||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="gone">
|
android:visibility="gone">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
<!-- Loader for next videos -->
|
<!-- Loader for next videos -->
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
@ -117,11 +116,10 @@
|
|||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintBottom_toBottomOf="parent">
|
app:layout_constraintBottom_toBottomOf="parent">
|
||||||
|
|
||||||
<com.github.ybq.android.spinkit.SpinKitView
|
<ProgressBar
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center" />
|
||||||
app:SpinKit_Color="?colorAccent" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</androidx.core.widget.NestedScrollView>
|
</androidx.core.widget.NestedScrollView>
|
Loading…
x
Reference in New Issue
Block a user