use of com.abewy.android.apps.klyph.adapter.holder.StreamHolder in project Klyph by jonathangerbaud.
the class StreamAdapter2 method mergeViewWithData.
@Override
protected void mergeViewWithData(View view, GraphObject data) {
super.mergeViewWithData(view, data);
if (buttonBarAdapter == null)
buttonBarAdapter = new StreamButtonBar(parentAdapter, specialLayout);
if (photoAdapter == null)
photoAdapter = new StreamPhoto(parentAdapter, specialLayout);
if (linkAdapter == null)
linkAdapter = new StreamLink(parentAdapter, specialLayout);
if (statusAdapter == null)
statusAdapter = new StreamStatus(parentAdapter, specialLayout);
final StreamHolder holder = (StreamHolder) getHolder(view);
setData(view, data);
final Stream stream = (Stream) data;
setData(holder, stream);
}
use of com.abewy.android.apps.klyph.adapter.holder.StreamHolder in project Klyph by jonathangerbaud.
the class StreamAdapter2 method attachHolder.
@Override
protected void attachHolder(View view) {
ImageView authorProfileImage = (ImageView) view.findViewById(R.id.author_profile_image);
TextView story = (TextView) view.findViewById(R.id.story);
TextView postTime = (TextView) view.findViewById(R.id.post_time);
ImageView sharedAuthorProfileImage = (ImageView) view.findViewById(R.id.shared_author_profile_image);
TextView sharedStory = (TextView) view.findViewById(R.id.shared_story);
TextView sharedPostTime = (TextView) view.findViewById(R.id.shared_post_time);
TextView message = (TextView) view.findViewById(R.id.message);
ImageView postPhoto = (ImageView) view.findViewById(R.id.post_photo);
ImageView postVideoPlay = (ImageView) view.findViewById(R.id.post_video_play);
TextView videoTitle = (TextView) view.findViewById(R.id.post_video_title);
TextView videoUrl = (TextView) view.findViewById(R.id.post_video_url);
ImageView postPicturePlay = (ImageView) view.findViewById(R.id.post_picture_play);
ImageView postLinkBackground = (ImageView) view.findViewById(R.id.stream_link_image_background);
TextView postName = (TextView) view.findViewById(R.id.post_name);
TextView postCaption = (TextView) view.findViewById(R.id.post_caption);
TextView postDescription = (TextView) view.findViewById(R.id.post_description);
HListView streamAlbum = (HListView) view.findViewById(R.id.stream_album);
ViewGroup streamLink = (ViewGroup) view.findViewById(R.id.stream_link);
Button likeButton = (Button) view.findViewById(R.id.like_button);
Button commentButton = (Button) view.findViewById(R.id.comment_button);
ImageButton shareButton = (ImageButton) view.findViewById(R.id.share_button);
ImageButton overflowButton = (ImageButton) view.findViewById(R.id.overflow_button);
ViewGroup buttonBar = (ViewGroup) view.findViewById(R.id.button_bar);
View buttonBarDivider = (View) view.findViewById(R.id.button_bar_divider);
StreamHolder holder = new StreamHolder(authorProfileImage, story, postTime, sharedAuthorProfileImage, sharedStory, sharedPostTime, message, postPhoto, postVideoPlay, videoTitle, videoUrl, postPicturePlay, postLinkBackground, postName, postCaption, postDescription, likeButton, commentButton, shareButton, overflowButton, streamAlbum, streamLink, buttonBar, buttonBarDivider);
setHolder(view, holder);
}
use of com.abewy.android.apps.klyph.adapter.holder.StreamHolder in project Klyph by jonathangerbaud.
the class StreamAdapter method mergeViewWithData.
@Override
protected void mergeViewWithData(View view, GraphObject data) {
//GraphObject previousData = getData(view);
/*if (previousData != null)
{
if (((Stream) previousData).getPost_id().equals(((Stream) data).getPost_id()))
{
return;
}
}*/
super.mergeViewWithData(view, data);
// getParentAdapter() = null on constructor
if (buttonBarAdapter == null)
buttonBarAdapter = new StreamButtonBar(parentAdapter, specialLayout);
if (photoAdapter == null)
photoAdapter = new StreamPhoto(parentAdapter, specialLayout);
if (linkAdapter == null)
linkAdapter = new StreamLink(parentAdapter, specialLayout);
if (statusAdapter == null)
statusAdapter = new StreamStatus(parentAdapter, specialLayout);
final StreamHolder holder = (StreamHolder) getHolder(view);
setData(view, data);
setData(view, holder, (Stream) data);
}
use of com.abewy.android.apps.klyph.adapter.holder.StreamHolder in project Klyph by jonathangerbaud.
the class StreamAdapter method attachHolder.
@Override
protected void attachHolder(View view) {
ImageView authorProfileImage = (ImageView) view.findViewById(R.id.author_profile_image);
TextView story = (TextView) view.findViewById(R.id.story);
TextView postTime = (TextView) view.findViewById(R.id.post_time);
ImageView sharedAuthorProfileImage = (ImageView) view.findViewById(R.id.shared_author_profile_image);
TextView sharedStory = (TextView) view.findViewById(R.id.shared_story);
TextView sharedPostTime = (TextView) view.findViewById(R.id.shared_post_time);
TextView message = (TextView) view.findViewById(R.id.message);
ImageView postPhoto = (ImageView) view.findViewById(R.id.post_photo);
ImageView postVideoPlay = (ImageView) view.findViewById(R.id.post_video_play);
TextView videoTitle = (TextView) view.findViewById(R.id.post_video_title);
TextView videoUrl = (TextView) view.findViewById(R.id.post_video_url);
ImageView postPicturePlay = (ImageView) view.findViewById(R.id.post_picture_play);
ImageView postLinkBackground = (ImageView) view.findViewById(R.id.stream_link_image_background);
TextView postName = (TextView) view.findViewById(R.id.post_name);
TextView postCaption = (TextView) view.findViewById(R.id.post_caption);
TextView postDescription = (TextView) view.findViewById(R.id.post_description);
Button likeButton = (Button) view.findViewById(R.id.like_button);
Button commentButton = (Button) view.findViewById(R.id.comment_button);
ImageButton shareButton = (ImageButton) view.findViewById(R.id.share_button);
ImageButton overflowButton = (ImageButton) view.findViewById(R.id.overflow_button);
HListView streamAlbum = (HListView) view.findViewById(R.id.stream_album);
ViewGroup streamLink = (ViewGroup) view.findViewById(R.id.stream_link);
ViewGroup buttonBar = (ViewGroup) view.findViewById(R.id.button_bar);
View buttonBarDivider = (View) view.findViewById(R.id.button_bar_divider);
StreamHolder holder = new StreamHolder(authorProfileImage, story, postTime, sharedAuthorProfileImage, sharedStory, sharedPostTime, message, postPhoto, postVideoPlay, videoTitle, videoUrl, postPicturePlay, postLinkBackground, postName, postCaption, postDescription, likeButton, commentButton, shareButton, overflowButton, streamAlbum, streamLink, buttonBar, buttonBarDivider);
setHolder(view, holder);
}
Aggregations