-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Thumbnails used in NewPipe are small (list/grid) mode. This PR facili…
…tates full width thumbnails and dubbed as card mode.
- Loading branch information
1 parent
c47d1af
commit 41e948d
Showing
24 changed files
with
608 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
app/src/main/java/org/schabi/newpipe/info_list/ItemViewMode.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package org.schabi.newpipe.info_list; | ||
|
||
/** | ||
* Item view mode for streams & playlist listing screens. | ||
*/ | ||
public enum ItemViewMode { | ||
/** | ||
* Default mode. | ||
*/ | ||
AUTO, | ||
/** | ||
* Full width list item with thumb on the left and two line title & uploader in right. | ||
*/ | ||
LIST, | ||
/** | ||
* Grid mode places two cards per row. | ||
*/ | ||
GRID, | ||
/** | ||
* A full width card in phone - portrait. | ||
*/ | ||
CARD | ||
} |
17 changes: 17 additions & 0 deletions
17
app/src/main/java/org/schabi/newpipe/info_list/holder/PlaylistCardInfoItemHolder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package org.schabi.newpipe.info_list.holder; | ||
|
||
import android.view.ViewGroup; | ||
|
||
import org.schabi.newpipe.R; | ||
import org.schabi.newpipe.info_list.InfoItemBuilder; | ||
|
||
/** | ||
* Playlist card layout. | ||
*/ | ||
public class PlaylistCardInfoItemHolder extends PlaylistMiniInfoItemHolder { | ||
|
||
public PlaylistCardInfoItemHolder(final InfoItemBuilder infoItemBuilder, | ||
final ViewGroup parent) { | ||
super(infoItemBuilder, R.layout.list_playlist_card_item, parent); | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
app/src/main/java/org/schabi/newpipe/info_list/holder/StreamCardInfoItemHolder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package org.schabi.newpipe.info_list.holder; | ||
|
||
import android.view.ViewGroup; | ||
|
||
import org.schabi.newpipe.R; | ||
import org.schabi.newpipe.info_list.InfoItemBuilder; | ||
|
||
/** | ||
* Card layout for stream. | ||
*/ | ||
public class StreamCardInfoItemHolder extends StreamInfoItemHolder { | ||
|
||
public StreamCardInfoItemHolder(final InfoItemBuilder infoItemBuilder, final ViewGroup parent) { | ||
super(infoItemBuilder, R.layout.list_stream_card_item, parent); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.