diff --git a/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/DisplayableMenu.java b/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/DisplayableMenu.java
index 34e85b1f7..273cc697e 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/DisplayableMenu.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/DisplayableMenu.java
@@ -26,9 +26,7 @@
import android.view.Gravity;
import android.view.View;
import android.view.ViewGroup;
-import android.widget.ImageView;
-import android.widget.TableRow;
-import android.widget.TextView;
+import android.widget.*;
import androidx.annotation.DrawableRes;
import androidx.appcompat.content.res.AppCompatResources;
@@ -41,6 +39,8 @@
import be.ugent.zeus.hydra.resto.RestoMenu;
import com.google.android.material.textview.MaterialTextView;
+import static be.ugent.zeus.hydra.common.utils.ViewUtils.convertDpToPixelInt;
+
/**
* Helper class to display meals.
*
@@ -76,7 +76,8 @@ private static ImageView makeImageView(Context context, @DrawableRes int id) {
ImageView imageView = new ImageView(context);
imageView.setScaleType(ImageView.ScaleType.FIT_CENTER);
imageView.setImageDrawable(AppCompatResources.getDrawable(context, id));
- TableRow.LayoutParams params = new TableRow.LayoutParams(TableRow.LayoutParams.WRAP_CONTENT, TableRow.LayoutParams.MATCH_PARENT);
+ var size = convertDpToPixelInt(16, context);
+ TableRow.LayoutParams params = new TableRow.LayoutParams(size, size);
imageView.setLayoutParams(params);
return imageView;
}
@@ -104,27 +105,8 @@ public static int getDrawable(RestoMeal meal) {
* @param parent The view to which the child views will be added. This will be done by calling {@link
* ViewGroup#addView(View)}. This is also the view to get a context from.
*/
- void addVegetableViews(ViewGroup parent) {
-
- final Context context = parent.getContext();
- final int rowPadding = ViewUtils.convertDpToPixelInt(ROW_PADDING_DP, context);
-
- for (String vegetable : menu.vegetables()) {
-
- TableRow tr = new TableRow(context);
- TableRow.LayoutParams lp = new TableRow.LayoutParams(TableRow.LayoutParams.MATCH_PARENT, TableRow.LayoutParams.WRAP_CONTENT);
- tr.setLayoutParams(lp);
- tr.setPadding(0, rowPadding, 0, rowPadding);
-
- ImageView imageView = makeImageView(context, R.drawable.resto_vegetables);
-
- TextView tvCenter = makeCenterTextView(context, vegetable, lp);
-
- tr.addView(imageView);
- tr.addView(tvCenter);
-
- parent.addView(tr);
- }
+ void addVegetableViews(ViewGroup parent, boolean showAllergens) {
+ addMealViews(parent, menu.vegetables(), showAllergens);
}
/**
@@ -133,8 +115,8 @@ void addVegetableViews(ViewGroup parent) {
* @param parent The view to which the child views will be added. This will be done by calling {@link
* ViewGroup#addView(View)}. This is also the view to get a context from.
*/
- void addSoupViews(ViewGroup parent) {
- addMealViews(parent, menu.soups(), false);
+ void addSoupViews(ViewGroup parent, boolean showAllergens) {
+ addMealViews(parent, menu.soups(), showAllergens);
}
/**
@@ -190,7 +172,7 @@ boolean hasColdDishes() {
private TextView makeCenterTextView(Context context, String text, TableRow.LayoutParams lp) {
TextView tvCenter = new MaterialTextView(context, null, normalStyle);
tvCenter.setTextIsSelectable(selectable);
- tvCenter.setPadding(ViewUtils.convertDpToPixelInt(16, context), 0, 0, 0);
+ tvCenter.setPadding(convertDpToPixelInt(16, context), 0, 0, 0);
tvCenter.setLayoutParams(lp);
tvCenter.setText(text);
return tvCenter;
@@ -204,7 +186,7 @@ private TextView makeCenterTextView(Context context, String text, TableRow.Layou
*/
private void addMealViews(ViewGroup parent, List meals, boolean showAllergens) {
final Context context = parent.getContext();
- final int rowPadding = ViewUtils.convertDpToPixelInt(ROW_PADDING_DP, context);
+ final int rowPadding = convertDpToPixelInt(ROW_PADDING_DP, context);
TableRow.LayoutParams lp = new TableRow.LayoutParams(TableRow.LayoutParams.MATCH_PARENT, TableRow.LayoutParams.WRAP_CONTENT);
@@ -216,17 +198,22 @@ private void addMealViews(ViewGroup parent, List meals, boolean showA
//Set the correct image.
@DrawableRes final int id = getDrawable(meal);
- ImageView imageView = makeImageView(context, id);
- String name = meal.name();
- TextView tvCenter = makeCenterTextView(context, name, lp);
- TextView tvRight = new MaterialTextView(context, null, normalStyle);
- tvRight.setLayoutParams(lp);
- tvRight.setText(meal.price());
- tvRight.setGravity(Gravity.END);
-
- tr.addView(imageView);
- tr.addView(tvCenter);
- tr.addView(tvRight);
+ tr.addView(makeImageView(context, id));
+ var center = makeCenterTextView(context, meal.name(), lp);
+ tr.addView(center);
+
+ if (meal.price() != null) {
+ TextView tvRight = new MaterialTextView(context, null, normalStyle);
+ tvRight.setLayoutParams(lp);
+ tvRight.setText(meal.price());
+ tvRight.setGravity(Gravity.END);
+ tr.addView(tvRight);
+ } else {
+ // Allow the center to span more columns.
+ TableRow.LayoutParams tlp = (TableRow.LayoutParams) center.getLayoutParams();
+ tlp.span = 2;
+ center.setLayoutParams(tlp);
+ }
parent.addView(tr);
diff --git a/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/MenuTable.java b/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/MenuTable.java
index e5f1621e7..a720adc50 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/MenuTable.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/common/ui/widgets/MenuTable.java
@@ -218,19 +218,21 @@ private void populate() {
if (showTitles) {
createTitle(getContext().getString(R.string.resto_menu_soup));
}
- menu.addSoupViews(this);
+ menu.addSoupViews(this, showAllergens);
}
if (isSetIn(displayedKinds, DisplayKind.VEGETABLES) && menu.hasVegetables()) {
if (showTitles) {
createTitle(getContext().getString(R.string.resto_menu_vegetables));
}
- menu.addVegetableViews(this);
+ menu.addVegetableViews(this, showAllergens);
}
}
/**
* Flags to indicate what should be displayed by the menu.
+ *
+ * Keep in sync with the showKind XML attribute.
*/
@IntDef(flag = true, value = {DisplayKind.HOT, DisplayKind.COLD, DisplayKind.SOUP, DisplayKind.VEGETABLES, DisplayKind.ALL})
@Retention(RetentionPolicy.SOURCE)
diff --git a/app/src/main/java/be/ugent/zeus/hydra/feed/cards/resto/RestoCardViewHolder.java b/app/src/main/java/be/ugent/zeus/hydra/feed/cards/resto/RestoCardViewHolder.java
index 645430b93..0cfd02f97 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/feed/cards/resto/RestoCardViewHolder.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/feed/cards/resto/RestoCardViewHolder.java
@@ -108,20 +108,12 @@ public void onCreateMenu(Menu menu) {
} else {
menu.add(NONE, KindMenu.SHOW_HOT, NONE, R.string.feed_pref_resto_show_hot);
}
-
- if ((kind & MenuTable.DisplayKind.COLD) == MenuTable.DisplayKind.COLD) {
- if (displayed > 1) {
- menu.add(NONE, KindMenu.HIDE_COLD, NONE, R.string.feed_pref_resto_hide_cold);
- }
- } else {
- menu.add(NONE, KindMenu.SHOW_COLD, NONE, R.string.feed_pref_resto_show_cold);
- }
}
@Override
public boolean onMenuItemClick(MenuItem item) {
return switch (item.getItemId()) {
- case KindMenu.HIDE_HOT, KindMenu.HIDE_SOUP, KindMenu.SHOW_HOT, KindMenu.SHOW_SOUP, KindMenu.SHOW_COLD, KindMenu.HIDE_COLD -> {
+ case KindMenu.HIDE_HOT, KindMenu.HIDE_SOUP, KindMenu.SHOW_HOT, KindMenu.SHOW_SOUP -> {
adapter.companion().executeCommand(new RestoKindCommand(item.getItemId()));
yield true;
}
diff --git a/app/src/main/java/be/ugent/zeus/hydra/feed/preferences/HomeFragment.java b/app/src/main/java/be/ugent/zeus/hydra/feed/preferences/HomeFragment.java
index caa89e01a..b9ff40031 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/feed/preferences/HomeFragment.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/feed/preferences/HomeFragment.java
@@ -49,7 +49,7 @@ public class HomeFragment extends PreferenceFragment {
public static final String PREF_DATA_SAVER = "pref_home_feed_save_data";
public static final boolean PREF_DATA_SAVER_DEFAULT = false;
- private static final String PREF_RESTO_KINDS = "pref_feed_resto_kinds_v2";
+ private static final String PREF_RESTO_KINDS = "pref_feed_resto_kinds_v3";
@MenuTable.DisplayKind
private static final int PREF_RESTO_KINDS_DEFAULT = MenuTable.DisplayKind.HOT | MenuTable.DisplayKind.SOUP;
private DeleteViewModel viewModel;
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMeal.java b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMeal.java
index bb5267aec..5094eaf95 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMeal.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMeal.java
@@ -25,6 +25,8 @@
import android.os.Parcel;
import android.os.Parcelable;
+import androidx.annotation.Nullable;
+
import java.util.List;
/**
@@ -33,7 +35,7 @@
* @author Niko Strijbol
* @author Mitch
*/
-public record RestoMeal(String name, String price, String type, String kind,
+public record RestoMeal(String name, @Nullable String price, @Nullable String type, String kind,
List allergens) implements Parcelable {
public static final String MENU_TYPE_COLD = "cold";
@@ -55,6 +57,13 @@ public void writeToParcel(Parcel dest, int flags) {
dest.writeStringList(this.allergens);
}
+ public RestoMeal withPrice(String newPrice) {
+ return new RestoMeal(name, newPrice, type, kind, allergens);
+ }
+
+ public RestoMeal withName(String newName) {
+ return new RestoMeal(newName, price, type, kind, allergens);
+ }
public static final Parcelable.Creator CREATOR = new Parcelable.Creator<>() {
@Override
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMenu.java b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMenu.java
index f2bb8c776..672b4e8e1 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMenu.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoMenu.java
@@ -25,7 +25,6 @@
import android.os.Parcel;
import android.os.Parcelable;
import androidx.annotation.NonNull;
-import androidx.annotation.VisibleForTesting;
import androidx.core.os.ParcelCompat;
import java.time.LocalDate;
@@ -44,16 +43,16 @@ public final class RestoMenu implements Parcelable {
private final boolean open;
private final LocalDate date;
private final List meals;
- private final List vegetables;
+ private final List vegetables2;
private final String message;
private transient CategorizedMeals categorized;
- public RestoMenu(boolean open, LocalDate date, List meals, List vegetables, String message) {
+ public RestoMenu(boolean open, LocalDate date, List meals, List vegetables2, String message) {
this.open = open;
this.date = date;
this.meals = meals;
- this.vegetables = vegetables;
+ this.vegetables2 = vegetables2;
this.message = message;
}
@@ -61,19 +60,20 @@ private RestoMenu(Parcel in) {
this.open = in.readByte() != 0;
this.date = ParcelCompat.readSerializable(in, LocalDate.class.getClassLoader(), LocalDate.class);
this.meals = in.createTypedArrayList(RestoMeal.CREATOR);
- this.vegetables = in.createStringArrayList();
+ this.vegetables2 = in.createTypedArrayList(RestoMeal.CREATOR);
this.message = in.readString();
}
/**
* Sort the meals available in the menu.
+ * This will also fix the soups.
*/
private void fillCategoriesIfNeeded() {
if (categorized != null) {
return;
}
- var soups = new ArrayList();
+ List soups = new ArrayList<>();
var mainDishes = new ArrayList();
var coldDishes = new ArrayList();
@@ -89,12 +89,35 @@ private void fillCategoriesIfNeeded() {
}
}
+ soups = fixSoups(soups);
+
this.categorized = new CategorizedMeals(mainDishes, coldDishes, soups);
}
- @VisibleForTesting
- public RestoMenu withDate(LocalDate date) {
- return new RestoMenu(open, date, meals, vegetables, message);
+ private static String removeSuffix(String word, String suffix) {
+ if (word.endsWith(suffix)) {
+ return word.substring(0, word.length() - suffix.length());
+ } else {
+ return word;
+ }
+ }
+
+ private List fixSoups(List soups) {
+ // TODO: this is rather ugly...
+ List finalSoups = new ArrayList<>();
+ var priceBig = "";
+ for (RestoMeal soup: soups) {
+ if (soup.name().endsWith("big") || soup.name().endsWith("groot")) {
+ priceBig = soup.price();
+ } else {
+ var name = removeSuffix(soup.name(), " small");
+ name = removeSuffix(name, " klein");
+ finalSoups.add(soup.withName(name));
+ }
+ }
+ final String suffix = priceBig;
+
+ return finalSoups.stream().map(s -> s.withPrice(s.price() + " / " + suffix)).toList();
}
/**
@@ -104,8 +127,8 @@ public boolean isClosed() {
return !open;
}
- public List vegetables() {
- return vegetables;
+ public List vegetables() {
+ return vegetables2;
}
public LocalDate date() {
@@ -141,13 +164,13 @@ public boolean equals(Object o) {
return open == restoMenu.open &&
Objects.equals(date, restoMenu.date) &&
Objects.equals(meals, restoMenu.meals) &&
- Objects.equals(vegetables, restoMenu.vegetables) &&
+ Objects.equals(vegetables2, restoMenu.vegetables2) &&
Objects.equals(message, restoMenu.message);
}
@Override
public int hashCode() {
- return Objects.hash(open, date, meals, vegetables, message);
+ return Objects.hash(open, date, meals, vegetables2, message);
}
@Override
@@ -156,11 +179,11 @@ public int describeContents() {
}
@Override
- public void writeToParcel(Parcel dest, int flags) {
+ public void writeToParcel(@NonNull Parcel dest, int flags) {
ParcelCompat.writeBoolean(dest, this.open);
dest.writeSerializable(this.date);
dest.writeTypedList(this.meals);
- dest.writeStringList(this.vegetables);
+ dest.writeTypedList(this.vegetables2);
dest.writeString(this.message);
}
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoPreferenceFragment.java b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoPreferenceFragment.java
index da0be8dc0..f7f8e16b0 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/RestoPreferenceFragment.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/RestoPreferenceFragment.java
@@ -61,6 +61,8 @@ public class RestoPreferenceFragment extends PreferenceFragment {
public static final String DEFAULT_CLOSING_TIME = "21:00";
public static final String PREF_RESTO_CLOSING_HOUR = "pref_resto_closing_hour";
+ public static final String PREF_SHOW_ALLERGENS = "key_show_allergens";
+
public static String getDefaultRestoEndpoint(Context context) {
return context.getString(R.string.value_resto_default_endpoint);
}
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/SingleDayFragment.java b/app/src/main/java/be/ugent/zeus/hydra/resto/SingleDayFragment.java
index ac64428bd..9282a8da3 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/SingleDayFragment.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/SingleDayFragment.java
@@ -85,6 +85,7 @@ public void onDestroyView() {
public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
binding.menuTable.setMenu(data, showAllergens);
+ binding.allergenWarningText.setVisibility(showAllergens ? View.VISIBLE : View.GONE);
}
public RestoMenu getData() {
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/menu/MenuPagerAdapter.java b/app/src/main/java/be/ugent/zeus/hydra/resto/menu/MenuPagerAdapter.java
index e0b8d8dab..2cb47482d 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/menu/MenuPagerAdapter.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/menu/MenuPagerAdapter.java
@@ -26,6 +26,7 @@
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;
+import androidx.preference.PreferenceManager;
import androidx.viewpager2.adapter.FragmentStateAdapter;
import java.time.LocalDate;
@@ -34,6 +35,7 @@
import java.util.Objects;
import be.ugent.zeus.hydra.resto.RestoMenu;
+import be.ugent.zeus.hydra.resto.RestoPreferenceFragment;
import be.ugent.zeus.hydra.resto.SingleDayFragment;
/**
@@ -43,13 +45,15 @@
*/
class MenuPagerAdapter extends FragmentStateAdapter {
private static final int LEGEND = -63;
-
- private boolean showAllergens = false;
+
+ private boolean showAllergens;
private List data = Collections.emptyList();
public MenuPagerAdapter(@NonNull Fragment fragment) {
super(fragment);
+ showAllergens = PreferenceManager.getDefaultSharedPreferences(fragment.requireContext())
+ .getBoolean(RestoPreferenceFragment.PREF_SHOW_ALLERGENS, false);
}
@SuppressLint("NotifyDataSetChanged")
@@ -108,7 +112,7 @@ public boolean containsItem(long itemId) {
return true;
}
- for (RestoMenu menu: this.data) {
+ for (RestoMenu menu : this.data) {
if (Objects.hash(menu, showAllergens) == itemId) {
return true;
}
diff --git a/app/src/main/java/be/ugent/zeus/hydra/resto/menu/RestoFragment.java b/app/src/main/java/be/ugent/zeus/hydra/resto/menu/RestoFragment.java
index 8804975cc..3c912b4e2 100644
--- a/app/src/main/java/be/ugent/zeus/hydra/resto/menu/RestoFragment.java
+++ b/app/src/main/java/be/ugent/zeus/hydra/resto/menu/RestoFragment.java
@@ -30,6 +30,7 @@
import android.widget.*;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
+import androidx.core.view.MenuProvider;
import androidx.fragment.app.Fragment;
import androidx.lifecycle.ViewModelProvider;
import androidx.preference.PreferenceManager;
@@ -64,8 +65,8 @@
import com.google.android.material.tabs.TabLayout;
import com.google.android.material.tabs.TabLayoutMediator;
import com.google.android.material.textfield.TextInputLayout;
+import org.jetbrains.annotations.NotNull;
-import static be.ugent.zeus.hydra.common.utils.FragmentUtils.registerMenuProvider;
import static be.ugent.zeus.hydra.common.utils.FragmentUtils.requireBaseActivity;
/**
@@ -133,31 +134,48 @@ public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceStat
super.onViewCreated(view, savedInstanceState);
Log.d(TAG, "receiveResto: on view created");
- registerMenuProvider(this, R.menu.menu_resto, new int[]{R.id.action_history}, menuItem -> {
- int itemId = menuItem.getItemId();
- if (itemId == R.id.action_refresh) {
- Toast toast = Toast.makeText(requireContext(), R.string.resto_extra_refresh_started, Toast.LENGTH_SHORT);
- toast.show();
- metaViewModel.onRefresh();
- menuViewModel.onRefresh();
- return true;
- } else if (itemId == R.id.resto_show_website) {
- NetworkUtils.maybeLaunchBrowser(requireContext(), URL);
- return true;
- } else if (itemId == R.id.action_history) {
- startActivity(new Intent(requireContext(), HistoryActivity.class));
- return true;
- } else if (itemId == R.id.resto_order_online) {
- String url = ORDER_URL + requireContext().getString(R.string.value_info_endpoint);
- NetworkUtils.maybeLaunchBrowser(requireContext(), url);
- return true;
- } else if (itemId == R.id.resto_show_allergens) {
- menuItem.setChecked(!menuItem.isChecked());
- pageAdapter.setShowAllergens(menuItem.isChecked());
- return true;
+ var manager = PreferenceManager.getDefaultSharedPreferences(requireContext());
+ var activity = requireBaseActivity(this);
+ activity.addMenuProvider(new MenuProvider() {
+ @Override
+ public void onCreateMenu(@NonNull @NotNull Menu menu, @NonNull @NotNull MenuInflater menuInflater) {
+ menuInflater.inflate(R.menu.menu_resto, menu);
+ activity.tintToolbarIcons(menu, R.id.action_history);
+ var showAllergens = manager.getBoolean(RestoPreferenceFragment.PREF_SHOW_ALLERGENS, false);
+ menu.findItem(R.id.resto_show_allergens).setChecked(showAllergens);
}
- return false;
- });
+
+ @Override
+ public boolean onMenuItemSelected(@NonNull @NotNull MenuItem menuItem) {
+ int itemId = menuItem.getItemId();
+ if (itemId == R.id.action_refresh) {
+ Toast toast = Toast.makeText(requireContext(), R.string.resto_extra_refresh_started, Toast.LENGTH_SHORT);
+ toast.show();
+ metaViewModel.onRefresh();
+ menuViewModel.onRefresh();
+ return true;
+ } else if (itemId == R.id.resto_show_website) {
+ NetworkUtils.maybeLaunchBrowser(requireContext(), URL);
+ return true;
+ } else if (itemId == R.id.action_history) {
+ startActivity(new Intent(requireContext(), HistoryActivity.class));
+ return true;
+ } else if (itemId == R.id.resto_order_online) {
+ String url = ORDER_URL + requireContext().getString(R.string.value_info_endpoint);
+ NetworkUtils.maybeLaunchBrowser(requireContext(), url);
+ return true;
+ } else if (itemId == R.id.resto_show_allergens) {
+ menuItem.setChecked(!menuItem.isChecked());
+ var newValue = menuItem.isChecked();
+ manager.edit()
+ .putBoolean(RestoPreferenceFragment.PREF_SHOW_ALLERGENS, newValue)
+ .apply();
+ pageAdapter.setShowAllergens(newValue);
+ return true;
+ }
+ return false;
+ }
+ }, getViewLifecycleOwner());
requireBaseActivity(this).requireToolbar().setDisplayShowTitleEnabled(false);
exposedDropdown = requireActivity().findViewById(R.id.exposed_dropdown);
diff --git a/app/src/main/res/drawable/ic_warning.xml b/app/src/main/res/drawable/ic_warning.xml
new file mode 100644
index 000000000..fc186c783
--- /dev/null
+++ b/app/src/main/res/drawable/ic_warning.xml
@@ -0,0 +1,27 @@
+
+
+
+
+
+
diff --git a/app/src/main/res/drawable/resto_vegetarian.xml b/app/src/main/res/drawable/resto_vegetarian.xml
index 9a0e7505a..6a5312c9a 100644
--- a/app/src/main/res/drawable/resto_vegetarian.xml
+++ b/app/src/main/res/drawable/resto_vegetarian.xml
@@ -1,6 +1,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+ android:width="44.995dp"
+ android:height="38dp"
+ android:viewportWidth="44.995"
+ android:viewportHeight="38">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/src/main/res/layout/fragment_menu.xml b/app/src/main/res/layout/fragment_menu.xml
index ae4fcc7ed..2afb2427a 100644
--- a/app/src/main/res/layout/fragment_menu.xml
+++ b/app/src/main/res/layout/fragment_menu.xml
@@ -26,12 +26,12 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
-
+
-
+
+
\ No newline at end of file
diff --git a/app/src/main/res/menu/menu_resto.xml b/app/src/main/res/menu/menu_resto.xml
index 528ca504e..5f2d7126f 100644
--- a/app/src/main/res/menu/menu_resto.xml
+++ b/app/src/main/res/menu/menu_resto.xml
@@ -22,17 +22,17 @@
diff --git a/app/src/main/res/values-en/strings.xml b/app/src/main/res/values-en/strings.xml
index e7c7672d4..1cd3f73b5 100644
--- a/app/src/main/res/values-en/strings.xml
+++ b/app/src/main/res/values-en/strings.xml
@@ -222,6 +222,11 @@
Good Agricultural Practice
Order online
Show allergens
+
+ Allergen information is provided on a best-effort basis, which means errors are possible.
+ The list of allergen information in the restaurant is the one true source of information.
+ Always check the list in case of allergies!
+
en
@@ -240,8 +245,6 @@
Hide soup
Show hot meal
Hide hot meal
- Show cold meal
- Hide cold meal
Resto menu
Activities
diff --git a/app/src/main/res/values/attrs.xml b/app/src/main/res/values/attrs.xml
index 1b5cb5c4f..074e7db27 100644
--- a/app/src/main/res/values/attrs.xml
+++ b/app/src/main/res/values/attrs.xml
@@ -33,10 +33,11 @@
-
-
-
-
+
+
+
+
+
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 2abe15ad7..25baf44d2 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -228,6 +228,11 @@
Goede Agrarische Productie
Bestel online
Allergenen tonen
+
+ Hoewel allergenen zo nauwkeurig mogelijk worden weergegeven, zijn fouten altijd mogelijk.
+ De allergenenlijst in de resto is de autoritaire bron van informatie.
+ Controleer die lijst zeker bij een allergie!
+
nl-debrug
@@ -246,8 +251,6 @@
Soep verbergen
Warm gerecht tonen
Warm gerecht verbergen
- Koud gerecht tonen
- Koud gerecht verbergen
Restomenu
Activiteiten