Skip to content

Commit

Permalink
only show opening hours quests for elements that have names (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
westnordost committed Mar 22, 2017
1 parent 61d4555 commit ad5472e
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public class AddOpeningHours extends OverpassQuestType
" tourism ~ zoo|theme_park|gallery|museum or" +
" tourism = information and information = office or" +
" leisure ~ golf_course|water_park|miniature_golf )" +
" and !opening_hours";
" and !opening_hours and name";
}

@Override public int importance()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,14 +67,7 @@ private void setTitle()
{
name = element.getTags().get("name");
}
if(name != null)
{
setTitle(getResources().getString(R.string.quest_openingHours_name_title, name));
}
else
{
setTitle(R.string.quest_openingHours_unknownName_title);
}
setTitle(getResources().getString(R.string.quest_openingHours_name_title, name));
}

@Override protected List<Integer> getOtherAnswerResourceIds()
Expand Down
1 change: 0 additions & 1 deletion app/src/main/res/values-de/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
<string name="quest_streetName_nameWithAbbreviations_confirmation_title">"Name abgekürzt?"</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_description">"Abkürzungen in Straßennamen sollten immer ausgeschrieben werden. Für übliche Abkürzungen passiert das automatisch beim Schreiben, aber eventuell nicht für alle."</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_positive">"Keine Abkürzung"</string>
<string name="quest_openingHours_unknownName_title">"Was sind die Öffnungszeiten dieser Stätte?"</string>
<string name="quest_openingHours_name_title">"Was sind die Öffnungszeiten von „%s“?"</string>
<string name="quest_openingHours_start_time">"öffnet um"</string>
<string name="quest_openingHours_end_time">"schließt um"</string>
Expand Down
1 change: 0 additions & 1 deletion app/src/main/res/values-fr/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
<string name="quest_streetName_nameWithAbbreviations_confirmation_title">"Abréviation dans le nom?"</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_description">"Si le nom peut être épeler sans abréviation, il devrait être rallongé. Beaucoup d'abréviation. De nombreuses abréviations courantes sont développées automatiquement pendant que vous tapez, mais probablement pas toutes."</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_positive">"Pas d'abréviations"</string>
<string name="quest_openingHours_unknownName_title">"Quelles sont les heures d'ouverture de cette place?"</string>
<string name="quest_openingHours_name_title">"Quelles sont les heures d'ouverture de %s?"</string>
<string name="quest_openingHours_start_time">"heure d'ouverture"</string>
<string name="quest_openingHours_end_time">"heure de fermeture"</string>
Expand Down
1 change: 0 additions & 1 deletion app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
<string name="quest_streetName_nameWithAbbreviations_confirmation_title">"Abbreviation in the name?"</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_description">"If the name can be spelled without an abbreviation, then it should be expanded. Many common abbreviations are expanded automatically while you type, but probably not all."</string>
<string name="quest_streetName_nameWithAbbreviations_confirmation_positive">"No abbreviation"</string>
<string name="quest_openingHours_unknownName_title">"What are the opening hours of this location?"</string>
<string name="quest_openingHours_name_title">"What are the opening hours of %s?"</string>
<string name="quest_openingHours_start_time">"opening time"</string>
<string name="quest_openingHours_end_time">"closing time"</string>
Expand Down

0 comments on commit ad5472e

Please sign in to comment.