Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new quest to determine the maxheight #960

Merged
merged 41 commits into from
Aug 15, 2018
Merged
Show file tree
Hide file tree
Changes from 17 commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
02f38ac
Add new quest to determine the maximum height of some elements
ENT8R Mar 8, 2018
7ff5c4a
Remove unnecessary import statement
ENT8R Mar 8, 2018
59b4374
Remove now unnecessary drawable files
ENT8R Mar 8, 2018
6f17750
Fix some issues with e.g. the query, the wording and other answers
ENT8R Mar 10, 2018
54abb77
Some minor changes
ENT8R Mar 11, 2018
9c0a448
Merge branch master into 'maxheight'
ENT8R May 31, 2018
967d873
Exclude private service ways, update country metadata and fix some ot…
ENT8R Jun 3, 2018
3ec283d
Add layouts for some more countries like Australia, Canada, Great Bri…
ENT8R Jun 10, 2018
506cb05
Merge branch master into 'maxheight'
ENT8R Jun 10, 2018
d1f9cf6
Merge branch master into 'maxheight'
ENT8R Jun 28, 2018
bd2f194
Merged speedUnit.yml and heightUnit.yml to a new file called measurem…
ENT8R Jun 28, 2018
9a3462a
Fix some issues after review
ENT8R Jul 7, 2018
1dde772
Merge branch 'master' into maxheight
westnordost Aug 5, 2018
34afef1
sanitize layouts
westnordost Aug 5, 2018
12ae85e
use of current country resources is now automatic
westnordost Aug 5, 2018
7598410
update measurementSystem metadata
westnordost Aug 5, 2018
225a132
Refactor height class
ENT8R Aug 6, 2018
e0ebc94
Remove unnecessary layout code and add another null check
ENT8R Aug 6, 2018
89edcfc
Fix setContentView not using current country resources
westnordost Aug 8, 2018
63ea34f
Add a method to calculate the height of an object using the phones se…
ENT8R Aug 11, 2018
545cb65
Merge branch 'maxheight' of github.com:ENT8R/StreetComplete into maxh…
ENT8R Aug 11, 2018
ee08c5a
Correct wording
ENT8R Aug 11, 2018
ccf6eb9
Remove the height measurement activity, fix an issue after testing an…
ENT8R Aug 12, 2018
61bb31b
Add another check to avoid the inch input to be higher than 12
ENT8R Aug 12, 2018
edec337
add DpUtil
westnordost Aug 11, 2018
143ef5a
refactor to clean VisibleQuestListener to have only this one purpose,…
westnordost Aug 11, 2018
63ba0d0
add quest plop animation on solving
westnordost Aug 11, 2018
ccbc2b7
fix error on downloading oneway quest for areas
westnordost Aug 11, 2018
1f1f650
don't show upload-button in autosync-mode
westnordost Aug 11, 2018
8ceeec2
progress bar on upload button
westnordost Aug 11, 2018
b29d5ec
also add plop-animation for create-notes.
westnordost Aug 11, 2018
5221612
show blinking cursor in speed limit input and housenumber input sign
westnordost Aug 12, 2018
220ca4c
when exiting quest details, always zoom back to the previous zoom (do…
westnordost Aug 12, 2018
5a31fd4
fix tests
westnordost Aug 12, 2018
84042c4
request focus on input field when layout is set
westnordost Aug 12, 2018
cc19ad8
* fix sign is not yellow in Nordic countries
westnordost Aug 12, 2018
e0ef7fc
remove outer (double) black line from signs to reduce noise
westnordost Aug 15, 2018
48c0fcd
Merge branch 'master' into maxheight
westnordost Aug 15, 2018
91e87c1
remove outer (double) black line from signs to reduce noise
westnordost Aug 15, 2018
a9d9f7d
Workaround for an Android bug that it assumes the decimal separator t…
westnordost Aug 15, 2018
0eea8c8
actually, let's not care about which separator the user uses, he migh…
westnordost Aug 15, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ private void checkFirstDayOfWorkweekIsValid(CountryInfo info)
assertTrue(Weekdays.getWeekdayIndex(info.getFirstDayOfWorkweek()) > -1);
}

private void checkSpeedUnitIsEitherKmhOrMph(CountryInfo info)
private void checkMeasurementUnitIsEitherMetricOrImperial(CountryInfo info)
{
assertNotNull(info.getSpeedUnits());
assertTrue(info.getSpeedUnits().contains("mph") || info.getSpeedUnits().contains("km/h"));
assertNotNull(info.getMeasurementSystem());
assertTrue(info.getMeasurementSystem().contains("metric") || info.getMeasurementSystem().contains("imperial"));
}

private void checkAdditionalValidHousenumberRegexes(Map<String, CountryInfo> infos)
Expand All @@ -48,7 +48,7 @@ private void checkStartOfWorkweekValid(CountryInfo info)
private void checkForEach(CountryInfo info)
{
checkFirstDayOfWorkweekIsValid(info);
checkSpeedUnitIsEitherKmhOrMph(info);
checkMeasurementUnitIsEitherMetricOrImperial(info);
checkRegularShoppingDaysIsBetween0And7(info);
checkStartOfWorkweekValid(info);
}
Expand Down
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/AG.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 344
officialLanguages: [en]
orchardProduces: [guava, mango, mangosteen, lemon, lime, tomatoe, pineapple, banana, chilli_pepper,
Expand Down
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/AI.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/AS.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
officialLanguages: [en, sm]
orchardProduces: [coconut, banana, tomatoe, cacao]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/BM.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
orchardProduces: [banana, tomatoe]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/BS.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 364
officialLanguages: [en]
orchardProduces: [grapefruit, banana, coconut, lemon, lime, orange, tomatoe, guava, mango, mangosteen,
avocado, papaya]
popularSports: [tennis, basketball, baseball]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/BZ.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
mobileCountryCode: 702
officialLanguages: [en, bzj]
orchardProduces: [orange, grapefruit, banana, cacao, papaya, coconut, pineapple, cashew_nut, chilli_pepper,
sweet_pepper, coffee, tomatoe, guava, mango, mangosteen]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/DM.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 366
officialLanguages: [en]
orchardProduces: [banana, coconut, cacao, guava, mango, mangosteen, grapefruit, orange, coffee, lemon,
lime, avocado, tomatoe, pineapple, nutmeg, papaya]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/FK.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/FM.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
mobileCountryCode: 550
officialLanguages: [en, chk, pon]
orchardProduces: [coconut, banana, cacao]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/GB.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ isAdvisorySpeedLimitKnown: true
isLeftHandTraffic: true
isLivingStreetKnown: true
isSlowZoneKnown: true
measurementSystem: [imperial, metric]
mobileCountryCode: 234
officialLanguages: [en]
orchardProduces: [apple, strawberry, raspberry, pear, plum, cherry, hop, grape, tomatoe, chilli_pepper,
sweet_pepper]
popularReligions: [christian, muslim, jewish, hindu, sikh]
popularSports: [soccer, tennis, bowls, cricket, golf, basketball, rugby]
speedUnit: [mph]
Copy link
Member

@westnordost westnordost Jun 29, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, this is a problem. In GB, maxspeed signs are always in km/h, while heights/lengths will mostly be in metric (or both)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You rather mean that maxspeed signs are always in mph, right? And AFAIK heights and lengths are (at least on the traffic signs) also mostly in imperial units...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, ok

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wikipedia says here: https://en.wikipedia.org/wiki/Road_signs_in_the_United_Kingdom#Units_of_measurement

The United Kingdom is the only European country to use mostly imperial units rather than SI units on road signs for distance measurements and speed limits, and one of few countries in the world [..] to do so. Vehicle weight limits are signed only in metric (TSRGD 1981), and metric units may be used in addition to imperial ones for height, width and length restrictions.

Just to give a source...

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can confirm. Speed limits in UK are always mph.

2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/GD.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 352
officialLanguages: [en]
orchardProduces: [coconut, cacao, banana, nutmeg, avocado, guava, mango, mangosteen, plum, grapefruit,
orange, apple, tomatoe, lemon, lime, chilli_pepper, sweet_pepper, pineapple]
popularSports: [cricket]
speedUnit: [mph, km/h]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why did you switch this around? According to https://en.wikipedia.org/wiki/Miles_per_hour, Grenada uses MPH

Copy link
Contributor Author

@ENT8R ENT8R Jul 7, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, was my fault... Is fixed now.

1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/GG.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/GI.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
officialLanguages: [en]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/GS.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/GU.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
officialLanguages: [en, ch]
orchardProduces: [coconut, tomatoe, banana]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/GY.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [metric, imperial]
mobileCountryCode: 738
officialLanguages: [en, gyn]
orchardProduces: [coconut, tomatoe, chilli_pepper, sweet_pepper, cacao, banana, pepper, orange, pineapple,
Expand Down
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/IM.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [gv, en]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/JE.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/KY.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
orchardProduces: [banana, tomatoe]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/LC.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 358
officialLanguages: [en]
orchardProduces: [coconut, banana, pepper, grapefruit, nutmeg, lemon, lime, orange, guava, mango, mangosteen,
cacao, avocado, tomatoe, pineapple]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/LR.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right. I think this was actually missing in the current implementation

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, Liberia was not included at all...

mobileCountryCode: 618
officialLanguages: [en]
orchardProduces: [rubber, cacao, palm_oil, banana, coffee, coconut, orange, pineapple, tomatoe]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/MH.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Source?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same reason why I added Palau (PW): because the Marshall Islands were a territory of the US but gained independence about 30 years ago but they are still in a conversion from imperial to metric units and traffic signs...

mobileCountryCode: 551
officialLanguages: [mh, en]
orchardProduces: [coconut]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/MM.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Do not edit. Source files are in /res/country_metadata
additionalStreetsignLanguages: [en]
measurementSystem: [imperial, metric]
mobileCountryCode: 414
officialLanguages: [my]
orchardProduces: [rubber, chilli_pepper, sweet_pepper, tea, areca_nut, coconut, coffee, cashew_nut,
guava, mango, mangosteen]
popularReligions: [buddhist, christian, muslim, hindu]
popularSports: [soccer, tennis, sepak_takraw]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/MP.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
officialLanguages: [ch]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/MS.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
orchardProduces: [banana, tomatoe, guava, mango, mangosteen, chilli_pepper, sweet_pepper]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/PR.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
officialLanguages: [en]
orchardProduces: [coffee, banana, orange, guava, mango, mangosteen, avocado, pineapple, tomatoe, coconut,
papaya, grapefruit, chilli_pepper, sweet_pepper, lemon, lime]
popularSports: [basketball, tennis, baseball]
speedUnit: [mph, km/h]
1 change: 1 addition & 0 deletions app/src/main/assets/country_metadata/PW.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
measurementSystem: [imperial, metric]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Source?

Copy link
Contributor Author

@ENT8R ENT8R Jul 1, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added Palau because it is a part of Micronesia (FM) which uses the imperial system because it was a territory of the US

mobileCountryCode: 552
officialLanguages: [en, pau]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/TC.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/US.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Do not edit. Source files are in /res/country_metadata
isAdvisorySpeedLimitKnown: true
isSlowZoneKnown: false
measurementSystem: [imperial]
mobileCountryCode: 310
officialLanguages: [en]
orchardProduces: [grape, almond, tomatoe, apple, walnut, pistachio, peach, blueberry, grapefruit, plum,
chilli_pepper, sweet_pepper, strawberry, avocado, orange, lemon, lime]
popularReligions: [christian, jewish]
popularSports: [baseball, tennis, basketball, soccer, golf, american_football]
speedUnit: [mph]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/VC.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 360
officialLanguages: [en]
orchardProduces: [banana, cacao, coconut, coffee, nutmeg, guava, mango, mangosteen, orange, apple,
lemon, lime, chilli_pepper, sweet_pepper, pear, grapefruit]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/VG.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
orchardProduces: [banana]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/VI.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
officialLanguages: [en]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/WS.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Do not edit. Source files are in /res/country_metadata
isLeftHandTraffic: true
measurementSystem: [imperial, metric]
mobileCountryCode: 549
officialLanguages: [sm, en]
popularSports: [cricket]
speedUnit: [mph, km/h]
2 changes: 1 addition & 1 deletion app/src/main/assets/country_metadata/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ isAdvisorySpeedLimitKnown: false
isLeftHandTraffic: false
isLivingStreetKnown: false
isSlowZoneKnown: false
measurementSystem: [metric]
officialLanguages: [en]
orchardProduces: []
popularReligions: []
popularSports: []
regularShoppingDays: 6
speedUnit: [km/h]
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public class CountryInfo implements Serializable, Cloneable
// i.e. US for US-TX.yml
String countryCode;

List<String> speedUnit;
List<String> measurementSystem;
List<String> popularSports;
List<String> popularReligions;
String firstDayOfWorkweek;
Expand All @@ -29,9 +29,9 @@ public class CountryInfo implements Serializable, Cloneable
Boolean isLeftHandTraffic;
Integer mobileCountryCode;

public List<String> getSpeedUnits()
public List<String> getMeasurementSystem()
{
return speedUnit;
return measurementSystem;
}

public List<String> getPopularSports()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public SimpleOverpassQuestType(OverpassMapDataDao overpassServer)
/** @return a query string that is accepted by Overpass and does not exceed the given bbox */
String getOverpassQuery(BoundingBox bbox)
{
return filter.toOverpassQLString(bbox);
return filter.toOverpassQLString(bbox, true);
}

protected abstract String getTagFilters();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public boolean matches(Element element)
}

/** @return this expression as a Overpass query string (in a short one-liner form) */
public String toOverpassQLString(BoundingBox bbox)
public String toOverpassQLString(BoundingBox bbox, boolean print)
{
StringBuilder oql = new StringBuilder();
if(bbox != null)
Expand All @@ -66,9 +66,12 @@ public String toOverpassQLString(BoundingBox bbox)
}
if(useUnion) oql.append(");");

/* "body" print mode (default) does not include version, but "meta" does. "geom" prints out
* geometry for every way and relation */
oql.append("out meta geom;");
if (print)
{
/* "body" print mode (default) does not include version, but "meta" does. "geom" prints out
* geometry for every way and relation */
oql.append("out meta geom;");
}
return oql.toString();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import de.westnordost.streetcomplete.quests.diet_type.AddVegetarian;
import de.westnordost.streetcomplete.quests.fire_hydrant.AddFireHydrantType;
import de.westnordost.streetcomplete.quests.internet_access.AddInternetAccess;
import de.westnordost.streetcomplete.quests.max_height.AddMaxHeight;
import de.westnordost.streetcomplete.quests.oneway.AddOneway;
import de.westnordost.streetcomplete.quests.oneway.TrafficFlowSegmentsDao;
import de.westnordost.streetcomplete.quests.oneway.WayTrafficFlowDao;
Expand Down Expand Up @@ -86,6 +87,7 @@ public class QuestModule
new AddRecyclingType(o),
new AddRoadSurface(o),
new AddMaxSpeed(o), // should best be after road surface because it excludes unpaved roads
new AddMaxHeight(o),
new AddReligionToPlaceOfWorship(o), // icon on maps are different
new AddPostboxCollectionTimes(o),
new AddOpeningHours(o),
Expand Down
Loading