Skip to content

Commit

Permalink
Closes #1267: Update Alert allergens fragment (#1276)
Browse files Browse the repository at this point in the history
* Fixes #1267 Padding given in alert allergen list

* Update strings.xml

* Update strings.xml

* Update fragment_alert_allergens.xml

* Update fragment_alert_allergens.xml

* Update

* Resolved conflicts

* Fixes #1267 Update

* Fixes #1267 Update

* Update Final
  • Loading branch information
vaishali51 authored and ross-holloway94 committed Mar 23, 2018
1 parent fcf247f commit a067019
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 18 deletions.
12 changes: 5 additions & 7 deletions app/build.gradle
Expand Up @@ -128,13 +128,12 @@ dependencies {
implementation "com.android.support:design:$rootProject.supportLibraryVersion"
implementation "com.android.support:support-annotations:$rootProject.supportLibraryVersion"
implementation 'com.android.support.constraint:constraint-layout:1.0.2'

compile "com.android.support:multidex:$rootProject.multidexVersion"

//DI
annotationProcessor "com.google.dagger:dagger-compiler:$rootProject.daggerVersion"
implementation "com.google.dagger:dagger:$rootProject.daggerVersion"
provided "javax.annotation:jsr250-api:1.0"
provided 'javax.annotation:jsr250-api:1.0'

//Rx
implementation "io.reactivex.rxjava2:rxjava:$rootProject.rxVersion"
Expand All @@ -153,7 +152,8 @@ dependencies {
implementation "com.fasterxml.jackson.core:jackson-core:$rootProject.jacksonVersion"
implementation "com.fasterxml.jackson.core:jackson-databind:$rootProject.jacksonVersion"
implementation "com.fasterxml.jackson.core:jackson-annotations:$rootProject.jacksonVersion"
// compile 'io.rest-assured:json-path:3.0.7'

// compile 'io.rest-assured:json-path:3.0.7'

//CSV Serialization/Deserialization
implementation "com.opencsv:opencsv:$rootProject.openCsvVersion"
Expand Down Expand Up @@ -198,6 +198,7 @@ dependencies {
}

//UI Component : Adapters

//DO NOT UPDATE : RecyclerViewCacheUtil removed, needs rework
implementation 'com.mikepenz:fastadapter-commons:2.1.0@aar'

Expand All @@ -209,14 +210,12 @@ dependencies {
implementation "com.mikepenz:google-material-typeface:$rootProject.googleMaterialFontVersion"
implementation "com.mikepenz:material-design-iconic-typeface:$rootProject.materialFontVersion"
implementation "com.mikepenz:fontawesome-typeface:$rootProject.awesomeFontVersion"

implementation("com.theartofdev.edmodo:android-image-cropper:2.6.0") {
implementation('com.theartofdev.edmodo:android-image-cropper:2.6.0') {
exclude group: 'com.android.support', module: 'appcompat-v7'
}

//Testing
androidTestUtil 'com.android.support.test:orchestrator:1.0.1'

testImplementation "junit:junit:$rootProject.jUnitVersion"
testImplementation "org.mockito:mockito-core:$rootProject.mockitoVersion"
testImplementation "net.javacrumbs.json-unit:json-unit-fluent:$rootProject.jsonUnitVersion"
Expand All @@ -232,7 +231,6 @@ dependencies {
exclude group: 'com.android.support', module: 'design'
exclude module: 'recyclerview-v7'
}

resourcePlaceholders {
files = ['xml/shortcuts.xml']
}
Expand Down
@@ -1,6 +1,5 @@
package openfoodfacts.github.scrachx.openfood.views;


import android.Manifest;
import android.app.Activity;
import android.content.Context;
Expand Down Expand Up @@ -72,7 +71,6 @@ public class HistoryScanActivity extends BaseActivity implements SwipeController
@BindView(R.id.history_progressbar)
ProgressBar historyProgressbar;


@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Expand Down
@@ -1,6 +1,7 @@
package openfoodfacts.github.scrachx.openfood.views;

import android.app.Activity;
import android.app.Dialog;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
Expand All @@ -16,14 +17,24 @@
import android.support.v4.content.ContextCompat;
import android.support.v7.widget.CardView;
import android.support.v7.widget.Toolbar;

import android.util.Log;

import android.view.Gravity;
import android.view.MenuItem;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageButton;

import android.widget.ImageView;

import android.widget.RadioButton;


import android.widget.LinearLayout;

import android.widget.Spinner;
import android.widget.TextView;
import android.widget.Toast;
Expand Down
17 changes: 11 additions & 6 deletions app/src/main/res/layout/fragment_alert_allergens.xml
Expand Up @@ -2,20 +2,24 @@
xmlns:fab="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<!--Recycles R.layout#item_allergens.xml-->

<android.support.v7.widget.RecyclerView
android:id="@+id/allergens_recycle"
android:layout_width="match_parent"
android:layout_height="match_parent" />
android:layout_height="match_parent"
android:paddingBottom="100dp"
android:clipToPadding="false"/>

<android.support.design.widget.FloatingActionButton
android:id="@+id/fab"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/allergens_recycle"
android:layout_alignEnd="@+id/allergens_recycle"
android:layout_alignRight="@+id/allergens_recycle"
android:layout_margin="16dp"
android:layout_alignParentBottom="true"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_marginBottom="25dp"
android:layout_marginEnd="25dp"
android:layout_marginRight="25dp"
android:clickable="true"
android:focusable="true"
android:tint="@android:color/white"
Expand All @@ -24,3 +28,4 @@
fab:srcCompat="@drawable/plus" />

</RelativeLayout>

5 changes: 2 additions & 3 deletions app/src/main/res/values/strings.xml
Expand Up @@ -24,7 +24,7 @@
<string name="first_offline">Products added offline will appear here</string>

<!-- Image Upload -->
<string-array name="upload_image" translatable="false">
<string-array name="upload_image">
<item>640 X 480</item>
<item>1024 X 768</item>
<item>1152 X 864</item>
Expand Down Expand Up @@ -472,8 +472,7 @@
<string name="choose_resolution">Choose Resolution</string>
<string name="pref_resolution_summary">Pick a resolution for image upload</string>
<string name="image_upload_resolution">Image Upload Resolution</string>



<string name="can_add_barcode">Having trouble scanning?\nDrag up to type the barcode</string>
<string name="brand_string">Brand</string>
<string name="additive_string">Additive</string>
Expand Down

0 comments on commit a067019

Please sign in to comment.