Commit d220f5f8 authored by Geoffrey Métais's avatar Geoffrey Métais

Decode streams title & url for display

parent 108d27ba
......@@ -20,6 +20,7 @@
*****************************************************************************/
package org.videolan.vlc.gui.network;
import android.net.Uri;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
......@@ -39,12 +40,12 @@ class MRLAdapter extends RecyclerView.Adapter<MRLAdapter.ViewHolder> {
}
public class ViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener {
TextView uriTv, titleTv;
final TextView uriTv, titleTv;
public ViewHolder(View v) {
super(v);
uriTv = (TextView) v.findViewById(R.id.mrl_item_uri);
titleTv = (TextView) v.findViewById(R.id.mrl_item_title);
uriTv = v.findViewById(R.id.mrl_item_uri);
titleTv = v.findViewById(R.id.mrl_item_title);
itemView.setOnClickListener(this);
}
......@@ -69,8 +70,8 @@ class MRLAdapter extends RecyclerView.Adapter<MRLAdapter.ViewHolder> {
@Override
public void onBindViewHolder(final ViewHolder holder, int position) {
final HistoryItem item = mDataset[position];
holder.uriTv.setText(item.getMrl());
holder.titleTv.setText(item.getTitle());
holder.uriTv.setText(Uri.decode(item.getMrl()));
holder.titleTv.setText(Uri.decode(item.getTitle()));
}
public void setList(HistoryItem[] list){
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment