diff --git a/iphone/Maps/ActiveMapsVC.mm b/iphone/Maps/ActiveMapsVC.mm index 4c1de81ecf..adba16cadc 100644 --- a/iphone/Maps/ActiveMapsVC.mm +++ b/iphone/Maps/ActiveMapsVC.mm @@ -99,7 +99,7 @@ extern NSString * const MapsStatusChangedNotification; - (void)markSelectedMapIndexPath:(NSIndexPath *)indexPath { - self.selectedPosition = indexPath.row; + self.selectedPosition = static_cast(indexPath.row); self.selectedGroup = [self groupWithSection:indexPath.section]; } @@ -237,7 +237,7 @@ extern NSString * const MapsStatusChangedNotification; if (!cell) cell = [[MapCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:[MapCell className]]; - int const position = indexPath.row; + int const position = static_cast(indexPath.row); ActiveMapsLayout::TGroup const group = [self groupWithSection:indexPath.section]; TStatus const status = self.mapsLayout.GetCountryStatus(group, position); TMapOptions const options = self.mapsLayout.GetCountryOptions(group, position); @@ -293,7 +293,7 @@ extern NSString * const MapsStatusChangedNotification; - (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath { - TStatus const status = self.mapsLayout.GetCountryStatus([self groupWithSection:indexPath.section], indexPath.row); + TStatus const status = self.mapsLayout.GetCountryStatus([self groupWithSection:indexPath.section], static_cast(indexPath.row)); return status == TStatus::EOnDisk || status == TStatus::EOnDiskOutOfDate; } @@ -301,7 +301,7 @@ extern NSString * const MapsStatusChangedNotification; { if (editingStyle == UITableViewCellEditingStyleDelete) { - int const position = indexPath.row; + int const position = static_cast(indexPath.row); ActiveMapsLayout::TGroup const group = [self groupWithSection:indexPath.section]; TMapOptions const options = self.mapsLayout.GetCountryOptions(group, position); self.mapsLayout.DeleteMap(group, position, options); @@ -340,7 +340,7 @@ extern NSString * const MapsStatusChangedNotification; - (void)mapCellDidCancelDownloading:(MapCell *)cell { NSIndexPath * indexPath = [self.tableView indexPathForCell:cell]; - self.selectedPosition = indexPath.row; + self.selectedPosition = static_cast(indexPath.row); self.selectedGroup = [self groupWithSection:indexPath.section]; [[self actionSheetToCancelDownloadingSelectedMap] showFromRect:cell.frame inView:cell.superview animated:YES]; diff --git a/iphone/Maps/Bookmarks/AddSetVC.h b/iphone/Maps/Bookmarks/AddSetVC.h index 658c64ebcf..893726f50a 100644 --- a/iphone/Maps/Bookmarks/AddSetVC.h +++ b/iphone/Maps/Bookmarks/AddSetVC.h @@ -4,7 +4,7 @@ @class AddSetVC; @protocol AddSetVCDelegate -- (void)addSetVC:(AddSetVC *)vc didAddSetWithIndex:(size_t)setIndex; +- (void)addSetVC:(AddSetVC *)vc didAddSetWithIndex:(int)setIndex; @end diff --git a/iphone/Maps/Bookmarks/AddSetVC.mm b/iphone/Maps/Bookmarks/AddSetVC.mm index 70fbdb4aaf..6e71957e05 100644 --- a/iphone/Maps/Bookmarks/AddSetVC.mm +++ b/iphone/Maps/Bookmarks/AddSetVC.mm @@ -30,7 +30,7 @@ NSString * text = textField.text; if (text.length) { - [self.delegate addSetVC:self didAddSetWithIndex:GetFramework().AddCategory([text UTF8String])]; + [self.delegate addSetVC:self didAddSetWithIndex:static_cast(GetFramework().AddCategory([text UTF8String]))]; [self.navigationController popViewControllerAnimated:YES]; } } diff --git a/iphone/Maps/Bookmarks/BookmarksVC.mm b/iphone/Maps/Bookmarks/BookmarksVC.mm index 5d152d6e4e..f61472edd9 100644 --- a/iphone/Maps/Bookmarks/BookmarksVC.mm +++ b/iphone/Maps/Bookmarks/BookmarksVC.mm @@ -438,7 +438,7 @@ - (void)calculateSections { - size_t index = 1; + int index = 1; BookmarkCategory * cat = GetFramework().GetBmCategory(m_categoryIndex); if (cat->GetTracksCount()) m_trackSection = index++; diff --git a/iphone/Maps/Bookmarks/SelectSetVC.mm b/iphone/Maps/Bookmarks/SelectSetVC.mm index e03b5058aa..b155847667 100644 --- a/iphone/Maps/Bookmarks/SelectSetVC.mm +++ b/iphone/Maps/Bookmarks/SelectSetVC.mm @@ -69,7 +69,7 @@ return cell; } -- (void)addSetVC:(AddSetVC *)vc didAddSetWithIndex:(size_t)setIndex +- (void)addSetVC:(AddSetVC *)vc didAddSetWithIndex:(int)setIndex { [self moveBookmarkToSetWithIndex:setIndex]; @@ -77,9 +77,9 @@ [self.delegate selectSetVC:self didUpdateBookmarkAndCategory:m_bookmarkAndCategory]; } -- (void)moveBookmarkToSetWithIndex:(size_t)setIndex +- (void)moveBookmarkToSetWithIndex:(int)setIndex { - m_bookmarkAndCategory.second = GetFramework().MoveBookmark(m_bookmarkAndCategory.second, m_bookmarkAndCategory.first, setIndex); + m_bookmarkAndCategory.second = static_cast(GetFramework().MoveBookmark(m_bookmarkAndCategory.second, m_bookmarkAndCategory.first, setIndex)); m_bookmarkAndCategory.first = setIndex; } @@ -96,7 +96,7 @@ } else { - [self moveBookmarkToSetWithIndex:indexPath.row]; + [self moveBookmarkToSetWithIndex:static_cast(indexPath.row)]; [self.delegate selectSetVC:self didUpdateBookmarkAndCategory:m_bookmarkAndCategory]; [self.navigationController popViewControllerAnimated:YES]; }