Merge pull request #2443 from igrechuhin/ig-search

[ios] Bugs fixes.
This commit is contained in:
Vladimir Byko-Ianko 2016-03-23 17:48:43 +03:00
commit 6afd04693a
11 changed files with 19 additions and 1 deletions

View file

@ -7,6 +7,7 @@ using namespace storage;
extern NSString * const kCountryCellIdentifier;
extern NSString * const kSubplaceCellIdentifier;
extern NSString * const kPlaceCellIdentifier;
extern NSString * const kLargeCountryCellIdentifier;
@interface MWMMapDownloaderSearchDataSource ()
@ -66,8 +67,13 @@ extern NSString * const kPlaceCellIdentifier;
- (NSString *)cellIdentifierForIndexPath:(NSIndexPath *)indexPath
{
auto const & s = GetFramework().Storage();
NodeAttrs nodeAttrs;
NSString * countryId = [self countryIdForIndexPath:indexPath];
TCountriesVec children;
s.GetChildren(countryId.UTF8String, children);
BOOL const haveChildren = !children.empty();
if (haveChildren)
return kLargeCountryCellIdentifier;
NodeAttrs nodeAttrs;
s.GetNodeAttrs(countryId.UTF8String, nodeAttrs);
NSString * nodeLocalName = @(nodeAttrs.m_nodeLocalName.c_str());
NSString * matchedResult = [self searchMatchedResultForCountryId:countryId];

View file

@ -9,6 +9,7 @@
/* Begin PBXBuildFile section */
347F32F91C45383E009758CC /* debug_rect_renderer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 347F32F71C45383E009758CC /* debug_rect_renderer.cpp */; };
347F32FA1C45383E009758CC /* debug_rect_renderer.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 347F32F81C45383E009758CC /* debug_rect_renderer.hpp */; };
3492DA0B1CA2D91C00C1F3B3 /* visual_scale.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 3492DA0A1CA2D91C00C1F3B3 /* visual_scale.hpp */; };
670947231BDF9A4F005014C0 /* data_buffer_impl.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 670947151BDF9A4F005014C0 /* data_buffer_impl.hpp */; };
670947241BDF9A4F005014C0 /* depth_constants.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 670947161BDF9A4F005014C0 /* depth_constants.hpp */; };
670947251BDF9A4F005014C0 /* fribidi.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 670947171BDF9A4F005014C0 /* fribidi.cpp */; };
@ -122,6 +123,7 @@
/* Begin PBXFileReference section */
347F32F71C45383E009758CC /* debug_rect_renderer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = debug_rect_renderer.cpp; sourceTree = "<group>"; };
347F32F81C45383E009758CC /* debug_rect_renderer.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = debug_rect_renderer.hpp; sourceTree = "<group>"; };
3492DA0A1CA2D91C00C1F3B3 /* visual_scale.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = visual_scale.hpp; sourceTree = "<group>"; };
670947151BDF9A4F005014C0 /* data_buffer_impl.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = data_buffer_impl.hpp; sourceTree = "<group>"; };
670947161BDF9A4F005014C0 /* depth_constants.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = depth_constants.hpp; sourceTree = "<group>"; };
670947171BDF9A4F005014C0 /* fribidi.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = fribidi.cpp; sourceTree = "<group>"; };
@ -264,6 +266,7 @@
6729A4F31A691F6A007D5872 /* drape */ = {
isa = PBXGroup;
children = (
3492DA0A1CA2D91C00C1F3B3 /* visual_scale.hpp */,
6743D3421C3533AE0095054B /* support_manager.cpp */,
6743D3431C3533AE0095054B /* support_manager.hpp */,
6729A53E1A69213A007D5872 /* shaders */,
@ -418,6 +421,7 @@
670947231BDF9A4F005014C0 /* data_buffer_impl.hpp in Headers */,
6729A59B1A69213A007D5872 /* render_bucket.hpp in Headers */,
6729A56C1A69213A007D5872 /* binding_info.hpp in Headers */,
3492DA0B1CA2D91C00C1F3B3 /* visual_scale.hpp in Headers */,
6729A5971A69213A007D5872 /* overlay_tree.hpp in Headers */,
6729A5751A69213A007D5872 /* drape_global.hpp in Headers */,
347F32FA1C45383E009758CC /* debug_rect_renderer.hpp in Headers */,

View file

@ -7,6 +7,8 @@
objects = {
/* Begin PBXBuildFile section */
3492DA0E1CA2D9BF00C1F3B3 /* animation_utils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3492DA0C1CA2D9BF00C1F3B3 /* animation_utils.cpp */; };
3492DA0F1CA2D9BF00C1F3B3 /* animation_utils.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 3492DA0D1CA2D9BF00C1F3B3 /* animation_utils.hpp */; };
56BF56DA1C7608C0006DD7CB /* choose_position_mark.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 56BF56D81C7608C0006DD7CB /* choose_position_mark.cpp */; };
56BF56DB1C7608C0006DD7CB /* choose_position_mark.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 56BF56D91C7608C0006DD7CB /* choose_position_mark.hpp */; };
56D545661C74A44900E3719C /* overlay_batcher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 56D545641C74A44900E3719C /* overlay_batcher.cpp */; };
@ -183,6 +185,8 @@
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
3492DA0C1CA2D9BF00C1F3B3 /* animation_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = animation_utils.cpp; sourceTree = "<group>"; };
3492DA0D1CA2D9BF00C1F3B3 /* animation_utils.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = animation_utils.hpp; sourceTree = "<group>"; };
56BF56D81C7608C0006DD7CB /* choose_position_mark.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = choose_position_mark.cpp; sourceTree = "<group>"; };
56BF56D91C7608C0006DD7CB /* choose_position_mark.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = choose_position_mark.hpp; sourceTree = "<group>"; };
56D545641C74A44900E3719C /* overlay_batcher.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = overlay_batcher.cpp; sourceTree = "<group>"; };
@ -392,6 +396,8 @@
670947411BDF9B99005014C0 /* drape_frontend */ = {
isa = PBXGroup;
children = (
3492DA0C1CA2D9BF00C1F3B3 /* animation_utils.cpp */,
3492DA0D1CA2D9BF00C1F3B3 /* animation_utils.hpp */,
56D545641C74A44900E3719C /* overlay_batcher.cpp */,
56D545651C74A44900E3719C /* overlay_batcher.hpp */,
670E39361C46C59000E9C0A6 /* batch_merge_helper.cpp */,
@ -651,6 +657,7 @@
6709487D1BDF9C7F005014C0 /* point.h in Headers */,
6709479A1BDF9BE1005014C0 /* map_shape.hpp in Headers */,
670948731BDF9C7F005014C0 /* frame_image.hpp in Headers */,
3492DA0F1CA2D9BF00C1F3B3 /* animation_utils.hpp in Headers */,
670947FB1BDF9BF5005014C0 /* backend_renderer.hpp in Headers */,
670947DF1BDF9BE1005014C0 /* visual_params.hpp in Headers */,
670948171BDF9C39005014C0 /* interpolation_holder.hpp in Headers */,
@ -772,6 +779,7 @@
670947CE1BDF9BE1005014C0 /* tile_key.cpp in Sources */,
670947AB1BDF9BE1005014C0 /* path_text_shape.cpp in Sources */,
670947F61BDF9BF5005014C0 /* apply_feature_functors.cpp in Sources */,
3492DA0E1CA2D9BF00C1F3B3 /* animation_utils.cpp in Sources */,
670947D81BDF9BE1005014C0 /* user_mark_shapes.cpp in Sources */,
670947A51BDF9BE1005014C0 /* my_position.cpp in Sources */,
670947BB1BDF9BE1005014C0 /* route_shape.cpp in Sources */,