Timeline things working right now Woohoo!
This commit is contained in:
@@ -118,7 +118,7 @@ public class LoginActivity extends AppCompatActivity implements View.OnClickList
|
|||||||
String passwordConfirmString = passwordConfirmField.getText().toString();
|
String passwordConfirmString = passwordConfirmField.getText().toString();
|
||||||
|
|
||||||
if (!emailString.isEmpty() && !usernameString.isEmpty()
|
if (!emailString.isEmpty() && !usernameString.isEmpty()
|
||||||
&& passwordString.isEmpty() && passwordConfirmString.isEmpty()) {
|
&& !passwordString.isEmpty() && !passwordConfirmString.isEmpty()) {
|
||||||
if (passwordField.getText().toString().equals(passwordConfirmField.getText().toString())) {
|
if (passwordField.getText().toString().equals(passwordConfirmField.getText().toString())) {
|
||||||
registerUser(emailField.getText().toString(), passwordField.getText().toString());
|
registerUser(emailField.getText().toString(), passwordField.getText().toString());
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -17,7 +17,11 @@ import com.google.firebase.auth.FirebaseAuth;
|
|||||||
import nl.myhyvesbookplus.tagram.controller.DownloadClass;
|
import nl.myhyvesbookplus.tagram.controller.DownloadClass;
|
||||||
import nl.myhyvesbookplus.tagram.controller.ProfilePictureUploader;
|
import nl.myhyvesbookplus.tagram.controller.ProfilePictureUploader;
|
||||||
|
|
||||||
public class MainActivity extends AppCompatActivity implements CameraFragment.OnFragmentInteractionListener, ProfileFragment.OnFragmentInteractionListener, TimelineFragment.OnFragmentInteractionListener, ProfilePictureUploader.ProfilePictureUpdatedListener {
|
public class MainActivity extends AppCompatActivity implements
|
||||||
|
CameraFragment.OnFragmentInteractionListener,
|
||||||
|
ProfileFragment.OnFragmentInteractionListener,
|
||||||
|
ProfilePictureUploader.ProfilePictureUpdatedListener,
|
||||||
|
DownloadClass.PostDownloadListener {
|
||||||
final static private String TAG = "MainScreen";
|
final static private String TAG = "MainScreen";
|
||||||
|
|
||||||
FirebaseAuth mAuth;
|
FirebaseAuth mAuth;
|
||||||
@@ -100,10 +104,10 @@ public class MainActivity extends AppCompatActivity implements CameraFragment.On
|
|||||||
this.finish();
|
this.finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void testCreatePost(View view) {
|
// public void testCreatePost(View view) {
|
||||||
DownloadClass downloadClass = new DownloadClass();
|
// DownloadClass downloadClass = new DownloadClass();
|
||||||
downloadClass.getPosts();
|
// downloadClass.getPosts();
|
||||||
}
|
// }
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void ProfilePictureUpdated(Boolean success) {
|
public void ProfilePictureUpdated(Boolean success) {
|
||||||
@@ -118,4 +122,12 @@ public class MainActivity extends AppCompatActivity implements CameraFragment.On
|
|||||||
Log.d(TAG, "ProfilePictureUpdated: Done reloading fragment");
|
Log.d(TAG, "ProfilePictureUpdated: Done reloading fragment");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void PostDownloaded() {
|
||||||
|
FragmentManager fragmentManager = getFragmentManager();
|
||||||
|
fragmentManager.findFragmentById(R.id.content);
|
||||||
|
TimelineFragment frag = (TimelineFragment) fragmentManager.findFragmentById(R.id.content);
|
||||||
|
frag.startList();
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,75 @@
|
|||||||
|
package nl.myhyvesbookplus.tagram;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.BaseAdapter;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.firebase.ui.storage.images.FirebaseImageLoader;
|
||||||
|
import com.google.firebase.storage.FirebaseStorage;
|
||||||
|
import com.google.firebase.storage.StorageReference;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import nl.myhyvesbookplus.tagram.model.UriPost;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by marijnjansen on 26/06/2017.
|
||||||
|
*/
|
||||||
|
|
||||||
|
public class TimeLineAdapter extends BaseAdapter {
|
||||||
|
private static final String TAG = "TimeLineAdapter";
|
||||||
|
private LayoutInflater mInflater;
|
||||||
|
private Context mContext;
|
||||||
|
private ArrayList<UriPost> mData;
|
||||||
|
|
||||||
|
TimeLineAdapter(Context context, ArrayList<UriPost> data) {
|
||||||
|
mContext = context;
|
||||||
|
mInflater = (LayoutInflater) mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
|
||||||
|
mData = data;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCount() {
|
||||||
|
Log.d(TAG, "getCount: " + mData.size());
|
||||||
|
return mData.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getItem(int position) {
|
||||||
|
return mData.get(position);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getItemId(int position) {
|
||||||
|
return position;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View getView(int position, View convertView, ViewGroup parent) {
|
||||||
|
View rowView = mInflater.inflate(R.layout.list_item_timeline, parent, false);
|
||||||
|
|
||||||
|
TextView comment = (TextView) rowView.findViewById(R.id.comment_timeline);
|
||||||
|
TextView nietslechts = (TextView) rowView.findViewById(R.id.niet_slecht_count);
|
||||||
|
ImageView photo = (ImageView) rowView.findViewById(R.id.timeline_image);
|
||||||
|
|
||||||
|
UriPost post = (UriPost) getItem(position);
|
||||||
|
|
||||||
|
nietslechts.setText(Integer.toString(post.getNietSlechts()));
|
||||||
|
comment.setText(post.getComment());
|
||||||
|
|
||||||
|
StorageReference ref = FirebaseStorage.getInstance().getReferenceFromUrl(post.getUri());
|
||||||
|
Glide.with(mContext)
|
||||||
|
.using(new FirebaseImageLoader())
|
||||||
|
.load(ref)
|
||||||
|
.into(photo);
|
||||||
|
|
||||||
|
|
||||||
|
return rowView;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,33 +1,25 @@
|
|||||||
package nl.myhyvesbookplus.tagram;
|
package nl.myhyvesbookplus.tagram;
|
||||||
|
|
||||||
import android.content.Context;
|
|
||||||
import android.net.Uri;
|
|
||||||
import android.os.Bundle;
|
|
||||||
import android.app.Fragment;
|
import android.app.Fragment;
|
||||||
|
import android.os.Bundle;
|
||||||
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.ListView;
|
||||||
|
|
||||||
|
import nl.myhyvesbookplus.tagram.controller.DownloadClass;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A simple {@link Fragment} subclass.
|
* A simple {@link Fragment} subclass.
|
||||||
* Activities that contain this fragment must implement the
|
|
||||||
* {@link TimelineFragment.OnFragmentInteractionListener} interface
|
|
||||||
* to handle interaction events.
|
|
||||||
* Use the {@link TimelineFragment#newInstance} factory method to
|
* Use the {@link TimelineFragment#newInstance} factory method to
|
||||||
* create an instance of this fragment.
|
* create an instance of this fragment.
|
||||||
*/
|
*/
|
||||||
public class TimelineFragment extends Fragment {
|
public class TimelineFragment extends Fragment {
|
||||||
// TODO: Rename parameter arguments, choose names that match
|
final private static String TAG = "TimelineFragment";
|
||||||
// the fragment initialization parameters, e.g. ARG_ITEM_NUMBER
|
|
||||||
private static final String ARG_PARAM1 = "param1";
|
|
||||||
private static final String ARG_PARAM2 = "param2";
|
|
||||||
|
|
||||||
// TODO: Rename and change types of parameters
|
private ListView listView;
|
||||||
private String mParam1;
|
private DownloadClass downloadClass;
|
||||||
private String mParam2;
|
|
||||||
|
|
||||||
private OnFragmentInteractionListener mListener;
|
|
||||||
|
|
||||||
public TimelineFragment() {
|
public TimelineFragment() {
|
||||||
// Required empty public constructor
|
// Required empty public constructor
|
||||||
@@ -36,73 +28,31 @@ public class TimelineFragment extends Fragment {
|
|||||||
/**
|
/**
|
||||||
* Use this factory method to create a new instance of
|
* Use this factory method to create a new instance of
|
||||||
* this fragment using the provided parameters.
|
* this fragment using the provided parameters.
|
||||||
*
|
|
||||||
* @param param1 Parameter 1.
|
|
||||||
* @param param2 Parameter 2.
|
|
||||||
* @return A new instance of fragment TimelineFragment.
|
* @return A new instance of fragment TimelineFragment.
|
||||||
*/
|
*/
|
||||||
// TODO: Rename and change types and number of parameters
|
// TODO: Rename and change types and number of parameters
|
||||||
public static TimelineFragment newInstance(String param1, String param2) {
|
public static TimelineFragment newInstance() {
|
||||||
TimelineFragment fragment = new TimelineFragment();
|
TimelineFragment fragment = new TimelineFragment();
|
||||||
Bundle args = new Bundle();
|
Bundle args = new Bundle();
|
||||||
args.putString(ARG_PARAM1, param1);
|
|
||||||
args.putString(ARG_PARAM2, param2);
|
|
||||||
fragment.setArguments(args);
|
fragment.setArguments(args);
|
||||||
return fragment;
|
return fragment;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
|
||||||
super.onCreate(savedInstanceState);
|
|
||||||
if (getArguments() != null) {
|
|
||||||
mParam1 = getArguments().getString(ARG_PARAM1);
|
|
||||||
mParam2 = getArguments().getString(ARG_PARAM2);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
Bundle savedInstanceState) {
|
Bundle savedInstanceState) {
|
||||||
|
View view = inflater.inflate(R.layout.fragment_timeline, container, false);
|
||||||
|
|
||||||
|
listView = (ListView) view.findViewById(R.id.listview);
|
||||||
|
downloadClass = new DownloadClass(getActivity());
|
||||||
|
downloadClass.getPostsFromServer();
|
||||||
|
|
||||||
// Inflate the layout for this fragment
|
// Inflate the layout for this fragment
|
||||||
return inflater.inflate(R.layout.fragment_timeline, container, false);
|
return view;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Rename method, update argument and hook method into UI event
|
public void startList() {
|
||||||
public void onButtonPressed(Uri uri) {
|
TimeLineAdapter adapter = new TimeLineAdapter(getActivity(), downloadClass.getmList());
|
||||||
if (mListener != null) {
|
listView.setAdapter(adapter);
|
||||||
mListener.onFragmentInteraction(uri);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onAttach(Context context) {
|
|
||||||
super.onAttach(context);
|
|
||||||
if (context instanceof OnFragmentInteractionListener) {
|
|
||||||
mListener = (OnFragmentInteractionListener) context;
|
|
||||||
} else {
|
|
||||||
throw new RuntimeException(context.toString()
|
|
||||||
+ " must implement OnFragmentInteractionListener");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onDetach() {
|
|
||||||
super.onDetach();
|
|
||||||
mListener = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* This interface must be implemented by activities that contain this
|
|
||||||
* fragment to allow an interaction in this fragment to be communicated
|
|
||||||
* to the activity and potentially other fragments contained in that
|
|
||||||
* activity.
|
|
||||||
* <p>
|
|
||||||
* See the Android Training lesson <a href=
|
|
||||||
* "http://developer.android.com/training/basics/fragments/communicating.html"
|
|
||||||
* >Communicating with Other Fragments</a> for more information.
|
|
||||||
*/
|
|
||||||
public interface OnFragmentInteractionListener {
|
|
||||||
// TODO: Update argument type and name
|
|
||||||
void onFragmentInteraction(Uri uri);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package nl.myhyvesbookplus.tagram.controller;
|
package nl.myhyvesbookplus.tagram.controller;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
|
|
||||||
import com.google.firebase.database.DataSnapshot;
|
import com.google.firebase.database.DataSnapshot;
|
||||||
@@ -9,6 +10,7 @@ import com.google.firebase.database.FirebaseDatabase;
|
|||||||
import com.google.firebase.database.ValueEventListener;
|
import com.google.firebase.database.ValueEventListener;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collections;
|
||||||
|
|
||||||
import nl.myhyvesbookplus.tagram.model.UriPost;
|
import nl.myhyvesbookplus.tagram.model.UriPost;
|
||||||
|
|
||||||
@@ -18,30 +20,31 @@ import nl.myhyvesbookplus.tagram.model.UriPost;
|
|||||||
|
|
||||||
public class DownloadClass {
|
public class DownloadClass {
|
||||||
private static final String TAG = "DownloadClass";
|
private static final String TAG = "DownloadClass";
|
||||||
// private StorageReference mStorageRef;
|
|
||||||
private DatabaseReference mDataRef;
|
private DatabaseReference mDataRef;
|
||||||
|
private ArrayList<UriPost> mList;
|
||||||
|
private PostDownloadListener mListener;
|
||||||
|
|
||||||
public DownloadClass() {
|
public DownloadClass(Context context) {
|
||||||
// mStorageRef = FirebaseStorage.getInstance().getReference();
|
if (context instanceof DownloadClass.PostDownloadListener) {
|
||||||
|
mListener = (PostDownloadListener) context;
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException(context.toString()
|
||||||
|
+ " must implement PostDownloadListener");
|
||||||
|
}
|
||||||
mDataRef = FirebaseDatabase.getInstance().getReference();
|
mDataRef = FirebaseDatabase.getInstance().getReference();
|
||||||
|
mList = new ArrayList<>();
|
||||||
}
|
}
|
||||||
|
|
||||||
public UriPost[] getPosts() {
|
public void getPostsFromServer() {
|
||||||
UriPost[] posts = new UriPost[10];
|
|
||||||
getPostsFromServer().toArray(posts);
|
|
||||||
|
|
||||||
return posts;
|
|
||||||
}
|
|
||||||
|
|
||||||
private ArrayList<UriPost> getPostsFromServer() {
|
|
||||||
Log.d(TAG, "getPostsFromServer: Begin of function");
|
Log.d(TAG, "getPostsFromServer: Begin of function");
|
||||||
final ArrayList<UriPost> list = new ArrayList<>();
|
|
||||||
mDataRef.child("posts").addListenerForSingleValueEvent(new ValueEventListener() {
|
mDataRef.child("posts").addListenerForSingleValueEvent(new ValueEventListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onDataChange(DataSnapshot dataSnapshot) {
|
public void onDataChange(DataSnapshot dataSnapshot) {
|
||||||
for (DataSnapshot data : dataSnapshot.getChildren()) {
|
for (DataSnapshot data : dataSnapshot.getChildren()) {
|
||||||
list.add(data.getValue(UriPost.class));
|
mList.add(data.getValue(UriPost.class));
|
||||||
}
|
}
|
||||||
|
Collections.reverse(mList);
|
||||||
|
mListener.PostDownloaded();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -49,6 +52,13 @@ public class DownloadClass {
|
|||||||
Log.d(TAG, "onCancelled: " + databaseError.getDetails() + databaseError.getMessage());
|
Log.d(TAG, "onCancelled: " + databaseError.getDetails() + databaseError.getMessage());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return list;
|
}
|
||||||
|
|
||||||
|
public ArrayList<UriPost> getmList() {
|
||||||
|
return mList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface PostDownloadListener {
|
||||||
|
void PostDownloaded();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ public class PostUploader extends UploadClass {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void uploadPicture(final BitmapPost post) {
|
public void uploadPicture(final BitmapPost post) {
|
||||||
final String name = getUserUid() + currentTimeMillis();
|
final String name = currentTimeMillis() + "_" + getUserUid();
|
||||||
|
|
||||||
UploadTask uploadTask = mStorageRef.child("posts").child(name + ".jpg").putBytes(bitmapToBytes(post.getBitmap()));
|
UploadTask uploadTask = mStorageRef.child("posts").child(name + ".jpg").putBytes(bitmapToBytes(post.getBitmap()));
|
||||||
uploadTask.addOnFailureListener(new OnFailureListener() {
|
uploadTask.addOnFailureListener(new OnFailureListener() {
|
||||||
|
|||||||
@@ -1,17 +1,25 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?><!--<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"--><!--xmlns:app="http://schemas.android.com/apk/res-auto"--><!--xmlns:tools="http://schemas.android.com/tools"--><!--android:layout_width="match_parent"--><!--android:layout_height="match_parent"--><!--tools:context="nl.myhyvesbookplus.tagram.LoginActivity">-->
|
<?xml version="1.0" encoding="utf-8"?><!--<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"--><!--xmlns:app="http://schemas.android.com/apk/res-auto"--><!--xmlns:tools="http://schemas.android.com/tools"--><!--android:layout_width="match_parent"--><!--android:layout_height="match_parent"--><!--tools:context="nl.myhyvesbookplus.tagram.LoginActivity">-->
|
||||||
|
|
||||||
<!--</android.support.constraint.ConstraintLayout>-->
|
<!--</android.support.constraint.ConstraintLayout>-->
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
|
||||||
android:paddingBottom="@dimen/activity_vertical_margin"
|
android:paddingBottom="@dimen/activity_vertical_margin"
|
||||||
android:paddingLeft="@dimen/activity_horizontal_margin"
|
android:paddingLeft="@dimen/activity_horizontal_margin"
|
||||||
android:paddingRight="@dimen/activity_horizontal_margin"
|
android:paddingRight="@dimen/activity_horizontal_margin"
|
||||||
android:paddingTop="@dimen/activity_vertical_margin"
|
android:paddingTop="@dimen/activity_vertical_margin"
|
||||||
tools:context=".LoginActivity">
|
tools:context=".LoginActivity">
|
||||||
|
|
||||||
|
<ScrollView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -21,6 +29,7 @@
|
|||||||
android:paddingEnd="@dimen/activity_horizontal_margin"
|
android:paddingEnd="@dimen/activity_horizontal_margin"
|
||||||
android:paddingStart="@dimen/activity_horizontal_margin"
|
android:paddingStart="@dimen/activity_horizontal_margin"
|
||||||
android:src="@drawable/logo_new" />
|
android:src="@drawable/logo_new" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -107,5 +116,6 @@
|
|||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:text="@string/back_to_login"
|
android:text="@string/back_to_login"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
</ScrollView>
|
||||||
|
</FrameLayout>
|
||||||
@@ -1,18 +1,15 @@
|
|||||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
tools:context="nl.myhyvesbookplus.tagram.TimelineFragment">
|
tools:context="nl.myhyvesbookplus.tagram.TimelineFragment">
|
||||||
|
|
||||||
<!-- TODO: Update blank fragment layout -->
|
<ListView
|
||||||
<TextView
|
android:id="@+id/listview"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent">
|
||||||
android:text="@string/hello_blank_fragment" />
|
|
||||||
<Button
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="Test bitmap upload"
|
|
||||||
android:onClick="testCreatePost"/>
|
|
||||||
|
|
||||||
</FrameLayout>
|
</ListView>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/timeline_image"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/comment_timeline"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Hallo Ik ben een comment!" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp">
|
||||||
|
|
||||||
|
<ImageButton
|
||||||
|
android:layout_width="200dp"
|
||||||
|
android:layout_height="match_parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:text="@string/niet_slecht" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/niet_slecht_count"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:text="10" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
@@ -18,4 +18,5 @@
|
|||||||
<string name="profile_picture_description">profiel foto</string>
|
<string name="profile_picture_description">profiel foto</string>
|
||||||
<string name="change_psw_button">Wachtwoord wijzigen</string>
|
<string name="change_psw_button">Wachtwoord wijzigen</string>
|
||||||
<string name="please_wait">Wacht a.u.b.</string>
|
<string name="please_wait">Wacht a.u.b.</string>
|
||||||
|
<string name="niet_slecht">\"Niet slecht.\"s</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -24,4 +24,5 @@
|
|||||||
<string name="profile_picture_description">profile picture</string>
|
<string name="profile_picture_description">profile picture</string>
|
||||||
<string name="change_psw_button">Change Password</string>
|
<string name="change_psw_button">Change Password</string>
|
||||||
<string name="please_wait">Please Wait</string>
|
<string name="please_wait">Please Wait</string>
|
||||||
|
<string name="niet_slecht">\"Niet slecht.\"s</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
Reference in New Issue
Block a user