diff --git a/README.md b/README.md index 16e2a42..d2e0777 100644 --- a/README.md +++ b/README.md @@ -17,15 +17,17 @@ - [X] Endless scrolling - [X] Pull to refresh - [X] Very Basic Torrent playback +- [X] Change Server + + +# TODO - [ ] Video Playback via WebRTC -- [ ] Pick Server - [ ] Login - [ ] Like/dislike video - [ ] Comment video -- [ ] Lots more missing at this point... - -# TODO - [ ] Unit Tests - [ ] App Icon and assets +- [ ] Search +- [ ] Lots more missing at this point... diff --git a/app/build.gradle b/app/build.gradle index 1162fec..3630f22 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -48,6 +48,8 @@ dependencies { // implementation "com.github.TorrentStream:TorrentStreamServer-Android:1.0.1" // implementation 'com.devbrackets.android:exomedia:4.1.0' + implementation 'de.hdodenhof:circleimageview:2.2.0' + implementation 'com.android.support:support-v4:27.1.0' testImplementation 'junit:junit:4.12' androidTestImplementation 'com.android.support.test:runner:1.0.1' diff --git a/app/src/main/java/net/schueller/peertube/activity/VideoListActivity.java b/app/src/main/java/net/schueller/peertube/activity/VideoListActivity.java index f06aedc..233fc11 100644 --- a/app/src/main/java/net/schueller/peertube/activity/VideoListActivity.java +++ b/app/src/main/java/net/schueller/peertube/activity/VideoListActivity.java @@ -145,6 +145,11 @@ public class VideoListActivity extends AppCompatActivity { inflater.inflate(R.menu.menu_main, menu); // Set an icon in the ActionBar + menu.findItem(R.id.action_search).setIcon( + new IconDrawable(this, FontAwesomeIcons.fa_search) + .colorRes(R.color.cardview_light_background) + .actionBarSize()); + menu.findItem(R.id.action_settings).setIcon( new IconDrawable(this, FontAwesomeIcons.fa_cog) .colorRes(R.color.cardview_light_background) @@ -162,6 +167,11 @@ public class VideoListActivity extends AppCompatActivity { switch (item.getItemId()) { // action with ID action_refresh was selected + case R.id.action_search: + // TODO: implement + Toast.makeText(this, "Search Selected", Toast.LENGTH_SHORT).show(); + + return false; case R.id.action_settings: // Toast.makeText(this, "Login Selected", Toast.LENGTH_SHORT).show(); Intent intent = new Intent(this, SettingsActivity.class); diff --git a/app/src/main/java/net/schueller/peertube/adapter/VideoAdapter.java b/app/src/main/java/net/schueller/peertube/adapter/VideoAdapter.java index 21f492f..6d4ee3c 100644 --- a/app/src/main/java/net/schueller/peertube/adapter/VideoAdapter.java +++ b/app/src/main/java/net/schueller/peertube/adapter/VideoAdapter.java @@ -2,11 +2,8 @@ package net.schueller.peertube.adapter; import android.content.Context; import android.content.Intent; -import android.content.SharedPreferences; -import android.preference.PreferenceManager; import android.support.annotation.NonNull; import android.support.v7.widget.RecyclerView; -import android.text.format.DateUtils; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; @@ -19,6 +16,7 @@ import net.schueller.peertube.R; import net.schueller.peertube.activity.TorrentVideoPlayActivity; import net.schueller.peertube.helper.APIUrlHelper; import net.schueller.peertube.helper.MetaDataHelper; +import net.schueller.peertube.model.Avatar; import net.schueller.peertube.model.Video; import java.util.ArrayList; @@ -55,6 +53,16 @@ public class VideoAdapter extends RecyclerView.Adapter getConfigData(); + +} \ No newline at end of file diff --git a/app/src/main/res/layout/row_video.xml b/app/src/main/res/layout/row_video.xml index 35e15d7..609a759 100644 --- a/app/src/main/res/layout/row_video.xml +++ b/app/src/main/res/layout/row_video.xml @@ -1,50 +1,64 @@ - - + - + android:orientation="vertical" + android:padding="12dp"> + - + + + + + android:layout_below="@id/name" + android:layout_toEndOf="@id/avatar" + android:textAppearance="@style/Base.TextAppearance.AppCompat.Caption" /> + android:layout_below="@id/videoMeta" + android:layout_toEndOf="@id/avatar" + android:textAppearance="@style/Base.TextAppearance.AppCompat.Caption" /> - + diff --git a/app/src/main/res/menu/menu_main.xml b/app/src/main/res/menu/menu_main.xml index 1e92997..b2d252f 100644 --- a/app/src/main/res/menu/menu_main.xml +++ b/app/src/main/res/menu/menu_main.xml @@ -4,6 +4,13 @@ xmlns:tools="http://schemas.android.com/tools" tools:context="activity.VideoListActivity"> + + + + Search Settings @@ -29,6 +30,8 @@ Account + 1.0.0-alpha.7 + https://troll.tv PeerTube Server @@ -38,4 +41,9 @@ \u0020Views \@ + + + Video Thumbnail + Account Avatar +