Fix ocean tiles

This commit is contained in:
Victor Shcherb 2012-04-29 15:43:43 +02:00
parent 068d5d0f59
commit 48b0f8e189

View file

@ -730,7 +730,7 @@ bool searchMapTreeBounds(io::CodedInputStream* input, MapTreeBounds* current, Ma
readInt(input, &child->length); readInt(input, &child->length);
child->filePointer = input->getTotalBytesRead(); child->filePointer = input->getTotalBytesRead();
int oldLimit = input->PushLimit(child->length); int oldLimit = input->PushLimit(child->length);
if (current->ocean != -1) { if (current->ocean) {
child->ocean = current->ocean; child->ocean = current->ocean;
} }
searchMapTreeBounds(input, child, current, req, foundSubtrees); searchMapTreeBounds(input, child, current, req, foundSubtrees);
@ -904,6 +904,9 @@ extern "C" JNIEXPORT jint JNICALL Java_net_osmand_plus_render_NativeOsmandLibrar
} }
} }
} }
if (q.ocean) {
ocean = true;
}
if (!q.isCancelled()) { if (!q.isCancelled()) {
std::vector<MapDataObject*>::iterator r = q.result.begin(); std::vector<MapDataObject*>::iterator r = q.result.begin();
tempResult.reserve(q.result.size() + tempResult.size()); tempResult.reserve(q.result.size() + tempResult.size());
@ -931,10 +934,6 @@ extern "C" JNIEXPORT jint JNICALL Java_net_osmand_plus_render_NativeOsmandLibrar
tempResult.push_back(*r); tempResult.push_back(*r);
} }
} }
if (q.ocean) {
ocean = true;
}
} }
} }
} }