Change category question text sizes

This commit is contained in:
neslihanturan 2018-05-19 23:41:05 +03:00 committed by maskara
parent 3b1cf20d27
commit 76b8df2b28
3 changed files with 10 additions and 2 deletions

View file

@ -3,10 +3,12 @@ package fr.free.nrw.commons.review;
import android.app.AlertDialog;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.EditText;
import android.widget.TableLayout;
import android.widget.TextView;
import com.facebook.drawee.view.SimpleDraweeView;
@ -47,6 +49,7 @@ public class ReviewImageFragment extends CommonsDaggerSupportFragment {
if (catsView != null) {
((TextView) catsView).setText(catString);
}
}
@Override
@ -61,6 +64,8 @@ public class ReviewImageFragment extends CommonsDaggerSupportFragment {
View layoutView = inflater.inflate(R.layout.fragment_review_image, container,
false);
View textView = layoutView.findViewById(R.id.reviewQuestion);
View textViewQuestion = layoutView.findViewById(R.id.reviewQuestion);
View textViewQuestionContext = layoutView.findViewById(R.id.reviewQuestionContext);
catsView = layoutView.findViewById(R.id.reviewCategories);
String question;
switch(position) {
@ -68,6 +73,8 @@ public class ReviewImageFragment extends CommonsDaggerSupportFragment {
question = getString(R.string.review_copyright);
break;
case CATEGORY:
textViewQuestion.setLayoutParams(new TableLayout.LayoutParams(TableLayout.LayoutParams.WRAP_CONTENT, TableLayout.LayoutParams.WRAP_CONTENT, 0.35f));
textViewQuestionContext.setLayoutParams(new TableLayout.LayoutParams(TableLayout.LayoutParams.WRAP_CONTENT, TableLayout.LayoutParams.WRAP_CONTENT, 0.35f));
question = getString(R.string.review_category);
catsView.setVisibility(View.VISIBLE);
break;
@ -88,5 +95,4 @@ public class ReviewImageFragment extends CommonsDaggerSupportFragment {
}
return layoutView;
}
}

View file

@ -5,7 +5,7 @@
android:layout_height="match_parent"
android:weightSum="6"
android:orientation="vertical"
android:gravity="center_horizontal"
android:gravity="center_horizontal|bottom"
>
<com.facebook.drawee.view.SimpleDraweeView
@ -45,6 +45,7 @@
android:layout_height="0dp"
android:layout_weight="0.7"
android:textSize="24sp"
android:textStyle="bold"
android:textAlignment="center"
android:text="testing2"
/>

View file

@ -480,5 +480,6 @@ Upload your first media by touching the camera or gallery icon above.</string>
<string name="review_copyright">Is this a copyright violation?</string>
<string name="review_category">Is this mis-categorized?</string>
<string name="review_spam">Is this spam?</string>
<string name="review_no_category">This image is uncategorized</string>
</resources>