Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlya Grechuhin <i.grechuhin@gmail.com>2017-08-15 18:19:26 +0300
committerSergey Yershov <syershov@maps.me>2017-08-15 19:16:03 +0300
commitb64b2731550e10b848e682aaaac4d2034948c897 (patch)
tree53ed0791f72417fff923e016b48393b948df46f3
parent648c6ceb96456835f9ac139e0becc451d31646cb (diff)
[cleanup] [ios] Code (imports) cleanup.beta-964
-rw-r--r--iphone/Maps/Bookmarks/AddSetVC.mm1
-rw-r--r--iphone/Maps/Bookmarks/BookmarksRootVC.mm2
-rw-r--r--iphone/Maps/Bookmarks/BookmarksVC.mm12
-rw-r--r--iphone/Maps/Bookmarks/SelectSetVC.h3
-rw-r--r--iphone/Maps/Classes/Components/MWMAddPlaceNavigationBar.mm2
-rw-r--r--iphone/Maps/Classes/Components/MWMCollectionViewController.mm1
-rw-r--r--iphone/Maps/Classes/Components/MWMNavigationController.h1
-rw-r--r--iphone/Maps/Classes/CustomAlert/DefaultAlert/MWMDefaultAlert.mm6
-rw-r--r--iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.h2
-rw-r--r--iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.mm1
-rw-r--r--iphone/Maps/Classes/CustomAlert/Toast/MWMToast.mm2
-rw-r--r--iphone/Maps/Classes/CustomViews/Login/MWMAuthorizationLoginViewController.mm10
-rw-r--r--iphone/Maps/Classes/CustomViews/MapViewControls/APIBar/MWMAPIBar.mm2
-rw-r--r--iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.h10
-rw-r--r--iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.mm18
-rw-r--r--iphone/Maps/Classes/CustomViews/MapViewControls/SideButtons/MWMSideButtons.mm4
-rw-r--r--iphone/Maps/Classes/CustomViews/MapViewControls/TrafficButton/MWMTrafficButtonViewController.mm2
-rw-r--r--iphone/Maps/Classes/CustomViews/NavigationDashboard/MWMNavigationDashboardManager.mm10
-rw-r--r--iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/MWMNavigationInfoView.mm8
-rw-r--r--iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/RoutePreview/MWMTaxiPreviewDataSource.mm10
-rw-r--r--iphone/Maps/Classes/DownloadIndicatorProtocol.h2
-rw-r--r--iphone/Maps/Classes/EAGLView.h7
-rw-r--r--iphone/Maps/Classes/EAGLView.mm14
-rw-r--r--iphone/Maps/Classes/MapViewController.h15
-rw-r--r--iphone/Maps/Classes/MapViewController.mm30
-rw-r--r--iphone/Maps/Classes/MapsAppDelegate.h7
-rw-r--r--iphone/Maps/Classes/MapsAppDelegate.mm21
-rw-r--r--iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm5
-rw-r--r--iphone/Maps/Classes/Widgets/MWMMapWidgets.mm5
-rw-r--r--iphone/Maps/Common/MWMCommon.h5
-rw-r--r--iphone/Maps/Common/Statistics/MWMCustomFacebookEvents.h2
-rw-r--r--iphone/Maps/Core/Ads/MWMBannerHelpers.h5
-rw-r--r--iphone/Maps/Core/Framework/MWMFrameworkHelper.mm1
-rw-r--r--iphone/Maps/Core/Framework/MWMFrameworkListener.h2
-rw-r--r--iphone/Maps/Core/Framework/MWMFrameworkListener.mm3
-rw-r--r--iphone/Maps/Core/Location/MWMLocationManager.mm11
-rw-r--r--iphone/Maps/Core/Notifications/LocalNotificationManager.mm6
-rw-r--r--iphone/Maps/Core/Routing/MWMRouter.mm8
-rw-r--r--iphone/Maps/Core/Search/MWMSearch+CoreSpotlight.mm2
-rw-r--r--iphone/Maps/Core/Search/MWMSearch.h5
-rw-r--r--iphone/Maps/Core/Search/MWMSearch.mm5
-rw-r--r--iphone/Maps/Core/Settings/MWMSettings.mm3
-rw-r--r--iphone/Maps/Core/Storage/MWMStorage.h2
-rw-r--r--iphone/Maps/Core/Storage/MWMStorage.mm4
-rw-r--r--iphone/Maps/Core/TextToSpeech/MWMTextToSpeech.mm25
-rw-r--r--iphone/Maps/Core/Traffic/MWMTrafficManager.mm3
-rw-r--r--iphone/Maps/Maps.xcodeproj/project.pbxproj34
-rw-r--r--iphone/Maps/UI/Autoupdate/MWMAutoupdateController.mm2
-rw-r--r--iphone/Maps/UI/BottomMenu/MWMBottomMenuControllerProtocol.h6
-rw-r--r--iphone/Maps/UI/BottomMenu/MWMBottomMenuView.mm10
-rw-r--r--iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.mm22
-rw-r--r--iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.xib1
-rw-r--r--iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderPlaceTableViewCell.mm1
-rw-r--r--iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.h13
-rw-r--r--iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.mm4
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.h16
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.mm9
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.h6
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.mm12
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSource.mm3
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSourceWithAds.mm2
-rw-r--r--iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderSearchDataSource.mm2
-rw-r--r--iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.h4
-rw-r--r--iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.mm28
-rw-r--r--iphone/Maps/UI/Downloader/MWMMapDownloaderMode.h4
-rw-r--r--iphone/Maps/UI/Downloader/MWMMapDownloaderTypes.h8
-rw-r--r--iphone/Maps/UI/Downloader/MWMMapDownloaderViewController.mm10
-rw-r--r--iphone/Maps/UI/Downloader/NoMaps/MWMNoMapsViewController.mm5
-rw-r--r--iphone/Maps/UI/EditBookmark/MWMEditBookmarkController.mm14
-rw-r--r--iphone/Maps/UI/Editor/MWMEditorViewController.h5
-rw-r--r--iphone/Maps/UI/Editor/MWMEditorViewController.mm10
-rw-r--r--iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.h7
-rw-r--r--iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.mm4
-rw-r--r--iphone/Maps/UI/Migration/MWMMigrationViewController.mm8
-rw-r--r--iphone/Maps/UI/PlacePage/MWMPlacePageData.h27
-rw-r--r--iphone/Maps/UI/PlacePage/MWMPlacePageData.mm17
-rw-r--r--iphone/Maps/UI/PlacePage/MWMPlacePageManager.mm28
-rw-r--r--iphone/Maps/UI/PlacePage/MWMPlacePageProtocol.h2
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.h4
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.mm8
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/Content/BookmarkCell/MWMBookmarkCell.mm1
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.h6
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.mm3
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/Content/RegularCell/MWMPlacePageRegularCell.mm2
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/Content/UGC/MWMUGCReviewVM.mm5
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.h5
-rw-r--r--iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.mm9
-rw-r--r--iphone/Maps/UI/Search/Console/MWMConsole.h5
-rw-r--r--iphone/Maps/UI/Search/Console/MWMConsole.mm13
-rw-r--r--iphone/Maps/UI/Search/Filters/MWMSearchFilterViewController.h10
-rw-r--r--iphone/Maps/UI/Search/Filters/MWMSearchHotelsFilterViewController.mm5
-rw-r--r--iphone/Maps/UI/Search/MWMSearchManager.h1
-rw-r--r--iphone/Maps/UI/Search/MWMSearchManager.mm21
-rw-r--r--iphone/Maps/UI/Search/TabbedView/CategoriesTab/MWMSearchCategoriesManager.mm3
-rw-r--r--iphone/Maps/UI/Search/TabbedView/HistoryTab/MWMSearchHistoryManager.mm4
-rw-r--r--iphone/Maps/UI/Search/TabbedView/MWMSearchTabbedViewController.mm7
-rw-r--r--iphone/Maps/UI/Search/TableView/MWMSearchCommonCell.mm4
-rw-r--r--iphone/Maps/UI/Search/TableView/MWMSearchTableViewController.mm3
-rw-r--r--iphone/Maps/UI/Settings/MWMAboutController.mm3
-rw-r--r--iphone/Maps/UI/Settings/MWMNightModeController.mm3
-rw-r--r--iphone/Maps/UI/Settings/MWMRecentTrackSettingsController.mm1
-rw-r--r--iphone/Maps/UI/Settings/MWMSettingsViewController.mm6
102 files changed, 225 insertions, 536 deletions
diff --git a/iphone/Maps/Bookmarks/AddSetVC.mm b/iphone/Maps/Bookmarks/AddSetVC.mm
index 794bf70c05..27a034971d 100644
--- a/iphone/Maps/Bookmarks/AddSetVC.mm
+++ b/iphone/Maps/Bookmarks/AddSetVC.mm
@@ -1,7 +1,6 @@
#import "AddSetVC.h"
#import "AddSetTableViewCell.h"
#import "SwiftBridge.h"
-#import "UIViewController+Navigation.h"
#include "Framework.h"
diff --git a/iphone/Maps/Bookmarks/BookmarksRootVC.mm b/iphone/Maps/Bookmarks/BookmarksRootVC.mm
index a1e6328d29..9927cb69ff 100644
--- a/iphone/Maps/Bookmarks/BookmarksRootVC.mm
+++ b/iphone/Maps/Bookmarks/BookmarksRootVC.mm
@@ -1,11 +1,9 @@
#import "BookmarksRootVC.h"
#import "BookmarksVC.h"
-#import "MWMCommon.h"
#import "Statistics.h"
#import "UIImageView+Coloring.h"
#include "Framework.h"
-#include "platform/platform.hpp"
#define TEXTFIELD_TAG 999
diff --git a/iphone/Maps/Bookmarks/BookmarksVC.mm b/iphone/Maps/Bookmarks/BookmarksVC.mm
index 049e2393ff..ba8d5e1cf5 100644
--- a/iphone/Maps/Bookmarks/BookmarksVC.mm
+++ b/iphone/Maps/Bookmarks/BookmarksVC.mm
@@ -2,29 +2,19 @@
#import "CircleView.h"
#import "ColorPickerView.h"
#import "MWMBookmarkNameCell.h"
-#import "MWMCommon.h"
#import "MWMLocationHelpers.h"
-#import "MWMLocationManager.h"
#import "MWMLocationObserver.h"
#import "MWMMailViewController.h"
-#import "MWMMapViewControlsManager.h"
-#import "MapViewController.h"
-#import "MapsAppDelegate.h"
-#import "Statistics.h"
+#import "MWMSearchManager.h"
#import "SwiftBridge.h"
#include "Framework.h"
-#include "platform/measurement_utils.hpp"
-
#include "geometry/distance_on_sphere.hpp"
#include "coding/zip_creator.hpp"
#include "coding/internal/file_data.hpp"
-#include <fstream>
-#include <vector>
-
#define PINDIAMETER 18
#define EMPTY_SECTION -666
diff --git a/iphone/Maps/Bookmarks/SelectSetVC.h b/iphone/Maps/Bookmarks/SelectSetVC.h
index 0a61fe0372..e9d3258a90 100644
--- a/iphone/Maps/Bookmarks/SelectSetVC.h
+++ b/iphone/Maps/Bookmarks/SelectSetVC.h
@@ -1,5 +1,6 @@
#import "MWMTableViewController.h"
-#include "Framework.h"
+
+struct BookmarkAndCategory;
@protocol MWMSelectSetDelegate <NSObject>
diff --git a/iphone/Maps/Classes/Components/MWMAddPlaceNavigationBar.mm b/iphone/Maps/Classes/Components/MWMAddPlaceNavigationBar.mm
index f88de663f3..30aad61feb 100644
--- a/iphone/Maps/Classes/Components/MWMAddPlaceNavigationBar.mm
+++ b/iphone/Maps/Classes/Components/MWMAddPlaceNavigationBar.mm
@@ -1,5 +1,5 @@
-#import "MWMCommon.h"
#import "MWMAddPlaceNavigationBar.h"
+#import "MWMCommon.h"
#include "Framework.h"
diff --git a/iphone/Maps/Classes/Components/MWMCollectionViewController.mm b/iphone/Maps/Classes/Components/MWMCollectionViewController.mm
index 93375e22ac..a0e80dccaf 100644
--- a/iphone/Maps/Classes/Components/MWMCollectionViewController.mm
+++ b/iphone/Maps/Classes/Components/MWMCollectionViewController.mm
@@ -1,4 +1,5 @@
#import "MWMCollectionViewController.h"
+#import "3party/Alohalytics/src/alohalytics_objc.h"
#import "MWMAlertViewController.h"
#import "MapViewController.h"
diff --git a/iphone/Maps/Classes/Components/MWMNavigationController.h b/iphone/Maps/Classes/Components/MWMNavigationController.h
index ebd0a9ccf0..bc1fcd8c78 100644
--- a/iphone/Maps/Classes/Components/MWMNavigationController.h
+++ b/iphone/Maps/Classes/Components/MWMNavigationController.h
@@ -1,4 +1,3 @@
-
@interface MWMNavigationController : UINavigationController
@end
diff --git a/iphone/Maps/Classes/CustomAlert/DefaultAlert/MWMDefaultAlert.mm b/iphone/Maps/Classes/CustomAlert/DefaultAlert/MWMDefaultAlert.mm
index 41f0ad576c..8266787688 100644
--- a/iphone/Maps/Classes/CustomAlert/DefaultAlert/MWMDefaultAlert.mm
+++ b/iphone/Maps/Classes/CustomAlert/DefaultAlert/MWMDefaultAlert.mm
@@ -1,11 +1,5 @@
#import "MWMDefaultAlert.h"
-#import "MWMAlertViewController.h"
-#import "MWMDefaultAlert_Protected.h"
-#import "MapViewController.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
-#import "UIButton+RuntimeAttributes.h"
-#import "UILabel+RuntimeAttributes.h"
#include "Framework.h"
diff --git a/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.h b/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.h
index ab3047ac78..b07f46c5db 100644
--- a/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.h
+++ b/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.h
@@ -1,7 +1,5 @@
#import "MWMAlert.h"
-#include "storage/storage.hpp"
-
@interface MWMDownloadTransitMapAlert : MWMAlert
+ (instancetype)downloaderAlertWithMaps:(storage::TCountriesVec const &)countries
diff --git a/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.mm b/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.mm
index c7a7588d82..f39c8ddbca 100644
--- a/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.mm
+++ b/iphone/Maps/Classes/CustomAlert/DownloadTransitMapsAlert/MWMDownloadTransitMapAlert.mm
@@ -1,5 +1,4 @@
#import "MWMDownloadTransitMapAlert.h"
-#import "MWMAlertViewController.h"
#import "MWMCircularProgress.h"
#import "MWMCommon.h"
#import "MWMDownloaderDialogCell.h"
diff --git a/iphone/Maps/Classes/CustomAlert/Toast/MWMToast.mm b/iphone/Maps/Classes/CustomAlert/Toast/MWMToast.mm
index c3bba346a9..2c4cfca481 100644
--- a/iphone/Maps/Classes/CustomAlert/Toast/MWMToast.mm
+++ b/iphone/Maps/Classes/CustomAlert/Toast/MWMToast.mm
@@ -118,7 +118,7 @@ NSUInteger const kWordsPerSecond = 3;
[self configLayout];
UIView * ov = [UIViewController topViewController].view;
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[ov layoutIfNeeded];
self.bottomOffset.priority = UILayoutPriorityFittingSizeLevel;
[UIView animateWithDuration:kDefaultAnimationDuration
diff --git a/iphone/Maps/Classes/CustomViews/Login/MWMAuthorizationLoginViewController.mm b/iphone/Maps/Classes/CustomViews/Login/MWMAuthorizationLoginViewController.mm
index 9e0f711ea9..27520fdd94 100644
--- a/iphone/Maps/Classes/CustomViews/Login/MWMAuthorizationLoginViewController.mm
+++ b/iphone/Maps/Classes/CustomViews/Login/MWMAuthorizationLoginViewController.mm
@@ -1,5 +1,3 @@
-#import "MWMCommon.h"
-#import "MapsAppDelegate.h"
#import "MWMAlertViewController.h"
#import "MWMAuthorizationCommon.h"
#import "MWMAuthorizationLoginViewController.h"
@@ -8,14 +6,6 @@
#include "Framework.h"
-#include "editor/server_api.hpp"
-
-#include "indexer/osm_editor.hpp"
-
-#include "platform/platform.hpp"
-
-#include "base/logging.hpp"
-
namespace
{
NSString * const kWebViewAuthSegue = @"Authorization2WebViewAuthorizationSegue";
diff --git a/iphone/Maps/Classes/CustomViews/MapViewControls/APIBar/MWMAPIBar.mm b/iphone/Maps/Classes/CustomViews/MapViewControls/APIBar/MWMAPIBar.mm
index c0b1abb2a6..0ed5230ef1 100644
--- a/iphone/Maps/Classes/CustomViews/MapViewControls/APIBar/MWMAPIBar.mm
+++ b/iphone/Maps/Classes/CustomViews/MapViewControls/APIBar/MWMAPIBar.mm
@@ -1,6 +1,6 @@
-#import "MWMCommon.h"
#import "MWMAPIBar.h"
#import "MWMAPIBarView.h"
+#import "MWMCommon.h"
#import "Statistics.h"
#include "Framework.h"
diff --git a/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.h b/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.h
index bad1c6a1fa..8bffecf8b7 100644
--- a/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.h
+++ b/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.h
@@ -1,13 +1,17 @@
#import "MWMBottomMenuViewController.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMNavigationDashboardManager.h"
#import "MWMSearchManager.h"
-#include "map/place_page_info.hpp"
-
@class MapViewController;
@protocol MWMFeatureHolder;
@protocol MWMBookingInfoHolder;
+namespace place_page
+{
+class Info;
+} // namespace place_page
+
@interface MWMMapViewControlsManager : NSObject
+ (MWMMapViewControlsManager *)manager;
@@ -48,7 +52,7 @@
#pragma mark - MWMSearchManager
-- (void)actionDownloadMaps:(mwm::DownloaderMode)mode;
+- (void)actionDownloadMaps:(MWMMapDownloaderMode)mode;
- (BOOL)searchText:(NSString *)text forInputLocale:(NSString *)locale;
- (void)searchTextOnMap:(NSString *)text forInputLocale:(NSString *)locale;
diff --git a/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.mm b/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.mm
index 82cf713efd..e7bd4bb9ea 100644
--- a/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.mm
+++ b/iphone/Maps/Classes/CustomViews/MapViewControls/MWMMapViewControlsManager.mm
@@ -1,30 +1,18 @@
#import "MWMMapViewControlsManager.h"
-#import "EAGLView.h"
-#import "MWMAPIBar.h"
#import "MWMAddPlaceNavigationBar.h"
-#import "MWMAlertViewController.h"
-#import "MWMAlertViewController.h"
-#import "MWMAuthorizationCommon.h"
#import "MWMBottomMenuControllerProtocol.h"
-#import "MWMBottomMenuViewController.h"
-#import "MWMButton.h"
#import "MWMCommon.h"
-#import "MWMFrameworkListener.h"
#import "MWMNetworkPolicy.h"
-#import "MWMObjectsCategorySelectorController.h"
#import "MWMPlacePageManager.h"
-#import "MWMRouter.h"
+#import "MWMPlacePageProtocol.h"
#import "MWMSearchManager.h"
#import "MWMSideButtons.h"
#import "MWMToast.h"
#import "MWMTrafficButtonViewController.h"
#import "MapViewController.h"
#import "MapsAppDelegate.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
-#import "3party/Alohalytics/src/alohalytics_objc.h"
-
#include "Framework.h"
#include "platform/local_country_file_utils.hpp"
@@ -32,6 +20,8 @@
#include "storage/storage_helpers.hpp"
+#include "map/place_page_info.hpp"
+
namespace
{
NSString * const kMapToCategorySelectorSegue = @"MapToCategorySelectorSegue";
@@ -166,7 +156,7 @@ extern NSString * const kAlohalyticsTapEventKey;
#pragma mark - MWMBottomMenuControllerProtocol
-- (void)actionDownloadMaps:(mwm::DownloaderMode)mode
+- (void)actionDownloadMaps:(MWMMapDownloaderMode)mode
{
MapViewController * ownerController = self.ownerController;
if (platform::migrate::NeedMigrate())
diff --git a/iphone/Maps/Classes/CustomViews/MapViewControls/SideButtons/MWMSideButtons.mm b/iphone/Maps/Classes/CustomViews/MapViewControls/SideButtons/MWMSideButtons.mm
index 8c49c5575a..0ca883d518 100644
--- a/iphone/Maps/Classes/CustomViews/MapViewControls/SideButtons/MWMSideButtons.mm
+++ b/iphone/Maps/Classes/CustomViews/MapViewControls/SideButtons/MWMSideButtons.mm
@@ -1,17 +1,13 @@
#import "MWMSideButtons.h"
#import "MWMButton.h"
-#import "MWMCommon.h"
#import "MWMMapViewControlsManager.h"
#import "MWMRouter.h"
#import "MWMSettings.h"
#import "MWMSideButtonsView.h"
#import "Statistics.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
-#include "indexer/scales.hpp"
-#include "platform/settings.hpp"
extern NSString * const kAlohalyticsTapEventKey;
diff --git a/iphone/Maps/Classes/CustomViews/MapViewControls/TrafficButton/MWMTrafficButtonViewController.mm b/iphone/Maps/Classes/CustomViews/MapViewControls/TrafficButton/MWMTrafficButtonViewController.mm
index 98d5f87bfb..8c8222a67d 100644
--- a/iphone/Maps/Classes/CustomViews/MapViewControls/TrafficButton/MWMTrafficButtonViewController.mm
+++ b/iphone/Maps/Classes/CustomViews/MapViewControls/TrafficButton/MWMTrafficButtonViewController.mm
@@ -99,7 +99,7 @@ NSArray<UIImage *> * imagesWithName(NSString * name)
- (void)refreshLayout
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
auto const availableArea = self.availableArea;
auto const leftOffset =
self.hidden ? -self.view.width : availableArea.origin.x + kViewControlsOffsetToBounds;
diff --git a/iphone/Maps/Classes/CustomViews/NavigationDashboard/MWMNavigationDashboardManager.mm b/iphone/Maps/Classes/CustomViews/NavigationDashboard/MWMNavigationDashboardManager.mm
index 465e740929..becf92cbe8 100644
--- a/iphone/Maps/Classes/CustomViews/NavigationDashboard/MWMNavigationDashboardManager.mm
+++ b/iphone/Maps/Classes/CustomViews/NavigationDashboard/MWMNavigationDashboardManager.mm
@@ -1,20 +1,10 @@
#import "MWMNavigationDashboardManager.h"
#import <AudioToolbox/AudioServices.h>
#import <Crashlytics/Crashlytics.h>
-#import "MWMCommon.h"
-#import "MWMLocationHelpers.h"
#import "MWMMapViewControlsManager.h"
-#import "MWMNavigationDashboardEntity.h"
#import "MWMNavigationInfoView.h"
-#import "MWMRoutePoint+CPP.h"
#import "MWMRoutePreview.h"
-#import "MWMRouter.h"
-#import "MWMSearchManager.h"
-#import "MWMTextToSpeech.h"
-#import "MWMTrafficManager.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#include "platform/platform.hpp"
diff --git a/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/MWMNavigationInfoView.mm b/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/MWMNavigationInfoView.mm
index 4b6c1cceca..5b9db6fb76 100644
--- a/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/MWMNavigationInfoView.mm
+++ b/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/MWMNavigationInfoView.mm
@@ -1,18 +1,12 @@
#import "MWMNavigationInfoView.h"
-#import "AppInfo.h"
#import "CLLocation+Mercator.h"
#import "MWMButton.h"
-#import "MWMCommon.h"
#import "MWMLocationHelpers.h"
#import "MWMLocationManager.h"
#import "MWMLocationObserver.h"
-#import "MWMMapViewControlsManager.h"
-#import "MWMMapWidgets.h"
-#import "MWMNavigationDashboardEntity.h"
-#import "MWMRouter.h"
#import "MWMSearch.h"
+#import "MWMSearchManager.h"
#import "MapViewController.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#import "UIImageView+Coloring.h"
diff --git a/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/RoutePreview/MWMTaxiPreviewDataSource.mm b/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/RoutePreview/MWMTaxiPreviewDataSource.mm
index a2085dc634..a88b220064 100644
--- a/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/RoutePreview/MWMTaxiPreviewDataSource.mm
+++ b/iphone/Maps/Classes/CustomViews/NavigationDashboard/Views/RoutePreview/MWMTaxiPreviewDataSource.mm
@@ -1,8 +1,5 @@
#import "MWMTaxiPreviewDataSource.h"
-#import "MWMCommon.h"
#import "MWMNetworkPolicy.h"
-#import "MWMRoutePoint.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#include "Framework.h"
@@ -55,7 +52,7 @@ using namespace taxi;
@interface MWMTaxiPreviewDataSource() <UICollectionViewDataSource, UICollectionViewDelegate>
{
- vector<Product> m_products;
+ std::vector<Product> m_products;
ms::LatLon m_from;
ms::LatLon m_to;
uint64_t m_requestId;
@@ -107,7 +104,8 @@ using namespace taxi;
auto success = [self, completion, failure](taxi::ProvidersContainer const & providers,
uint64_t const requestId) {
- runAsyncOnMainQueue([self, completion, failure, providers, requestId] {
+ dispatch_async(dispatch_get_main_queue(), [self, completion, failure, providers,
+ requestId] {
if (self->m_requestId != requestId)
return;
if (providers.empty())
@@ -152,7 +150,7 @@ using namespace taxi;
auto error = [self, failure](taxi::ErrorsContainer const & errors,
uint64_t const requestId) {
- runAsyncOnMainQueue([self, failure, errors, requestId] {
+ dispatch_async(dispatch_get_main_queue(), [self, failure, errors, requestId] {
if (self->m_requestId != requestId)
return;
if (errors.empty())
diff --git a/iphone/Maps/Classes/DownloadIndicatorProtocol.h b/iphone/Maps/Classes/DownloadIndicatorProtocol.h
index 5d224e4136..869205f63b 100644
--- a/iphone/Maps/Classes/DownloadIndicatorProtocol.h
+++ b/iphone/Maps/Classes/DownloadIndicatorProtocol.h
@@ -1,5 +1,3 @@
-#import <Foundation/Foundation.h>
-
@protocol DownloadIndicatorProtocol <NSObject>
- (void)enableStandby;
diff --git a/iphone/Maps/Classes/EAGLView.h b/iphone/Maps/Classes/EAGLView.h
index 6387091a5c..6eb962101e 100644
--- a/iphone/Maps/Classes/EAGLView.h
+++ b/iphone/Maps/Classes/EAGLView.h
@@ -1,12 +1,7 @@
-#import "MWMMapWidgets.h"
-
#include "drape/pointers.hpp"
#include "drape/drape_global.hpp"
-#include "indexer/map_style.hpp"
-
-#include "std/shared_ptr.hpp"
-
+@class MWMMapWidgets;
namespace dp
{
class ThreadSafeFactory;
diff --git a/iphone/Maps/Classes/EAGLView.mm b/iphone/Maps/Classes/EAGLView.mm
index beac617528..f19eb86ef2 100644
--- a/iphone/Maps/Classes/EAGLView.mm
+++ b/iphone/Maps/Classes/EAGLView.mm
@@ -1,22 +1,14 @@
-#import "MWMCommon.h"
#import "EAGLView.h"
-#import "MapsAppDelegate.h"
+#import "3party/Alohalytics/src/alohalytics_objc.h"
#import "MWMDirectionView.h"
-
+#import "MWMMapWidgets.h"
#import "iosOGLContextFactory.h"
-#import "3party/Alohalytics/src/alohalytics_objc.h"
-
#include "Framework.h"
-#include "indexer/classificator_loader.hpp"
-
-#include "platform/platform.hpp"
#include "drape/visual_scale.hpp"
-#include "std/bind.hpp"
-#include "std/limits.hpp"
-#include "std/unique_ptr.hpp"
+#include "base/logging.hpp"
@implementation EAGLView
diff --git a/iphone/Maps/Classes/MapViewController.h b/iphone/Maps/Classes/MapViewController.h
index e315e3825f..20f58dc70d 100644
--- a/iphone/Maps/Classes/MapViewController.h
+++ b/iphone/Maps/Classes/MapViewController.h
@@ -1,16 +1,7 @@
-#import "MWMMapDownloaderTypes.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMViewController.h"
-#import "SwiftBridge.h"
-
-#include "geometry/point2d.hpp"
-#include "geometry/rect2d.hpp"
-#include "indexer/map_style.hpp"
-
-namespace search
-{
-struct AddressInfo;
-}
+@class MWMWelcomePageController;
@class MWMMapViewControlsManager;
@class MWMAPIBar;
@class MWMPlacePageData;
@@ -31,7 +22,7 @@ struct AddressInfo;
- (void)openMigration;
- (void)openBookmarks;
-- (void)openMapsDownloader:(mwm::DownloaderMode)mode;
+- (void)openMapsDownloader:(MWMMapDownloaderMode)mode;
- (void)openEditor;
- (void)openHotelFacilities;
- (void)openBookmarkEditorWithData:(MWMPlacePageData *)data;
diff --git a/iphone/Maps/Classes/MapViewController.mm b/iphone/Maps/Classes/MapViewController.mm
index b5a97e1625..1bc6c3c041 100644
--- a/iphone/Maps/Classes/MapViewController.mm
+++ b/iphone/Maps/Classes/MapViewController.mm
@@ -3,9 +3,7 @@
#import "BookmarksVC.h"
#import "EAGLView.h"
#import "MWMAPIBar.h"
-#import "MWMAlertViewController.h"
#import "MWMAuthorizationCommon.h"
-#import "MWMAuthorizationLoginViewController.h"
#import "MWMAuthorizationWebViewLoginViewController.h"
#import "MWMAutoupdateController.h"
#import "MWMCommon.h"
@@ -13,38 +11,18 @@
#import "MWMEditorViewController.h"
#import "MWMFacilitiesController.h"
#import "MWMFrameworkListener.h"
-#import "MWMKeyboard.h"
#import "MWMLocationHelpers.h"
-#import "MWMLocationManager.h"
#import "MWMMapDownloadDialog.h"
#import "MWMMapDownloaderViewController.h"
#import "MWMMapViewControlsManager.h"
-#import "MWMPlacePageData.h"
#import "MWMPlacePageProtocol.h"
-#import "MWMRouter.h"
-#import "MWMSettings.h"
-#import "MWMSideButtons.h"
-#import "MWMStorage.h"
-#import "MWMTableViewController.h"
#import "MapsAppDelegate.h"
-#import "Statistics.h"
-#import "UIViewController+Navigation.h"
-
-#import "3party/Alohalytics/src/alohalytics_objc.h"
-
-#include "indexer/osm_editor.hpp"
+#import "SwiftBridge.h"
#include "Framework.h"
-#include "map/user_mark.hpp"
-
#include "drape_frontend/user_event_stream.hpp"
-#include "platform/file_logging.hpp"
-#include "platform/local_country_file_utils.hpp"
-#include "platform/platform.hpp"
-#include "platform/settings.hpp"
-
// If you have a "missing header error" here, then please run configure.sh script in the root repo
// folder.
#import "../../../private.h"
@@ -394,10 +372,10 @@ BOOL gIsFirstMyPositionMode = YES;
[self.navigationController pushViewController:vc animated:YES];
}
-- (void)openMapsDownloader:(mwm::DownloaderMode)mode
+- (void)openMapsDownloader:(MWMMapDownloaderMode)mode
{
[Alohalytics logEvent:kAlohalyticsTapEventKey withValue:@"downloader"];
- [self performSegueWithIdentifier:kDownloaderSegue sender:@(static_cast<NSInteger>(mode))];
+ [self performSegueWithIdentifier:kDownloaderSegue sender:@(mode)];
}
- (void)openEditor
@@ -580,7 +558,7 @@ BOOL gIsFirstMyPositionMode = YES;
MWMMapDownloaderViewController * dvc = segue.destinationViewController;
NSNumber * mode = sender;
[dvc setParentCountryId:@(GetFramework().GetStorage().GetRootId().c_str())
- mode:static_cast<mwm::DownloaderMode>(mode.integerValue)];
+ mode:static_cast<MWMMapDownloaderMode>(mode.integerValue)];
}
else if ([segue.identifier isEqualToString:kMap2FBLoginSegue])
{
diff --git a/iphone/Maps/Classes/MapsAppDelegate.h b/iphone/Maps/Classes/MapsAppDelegate.h
index a9341a402d..15c96ead08 100644
--- a/iphone/Maps/Classes/MapsAppDelegate.h
+++ b/iphone/Maps/Classes/MapsAppDelegate.h
@@ -2,12 +2,7 @@
#import "MWMMyTarget.h"
#import "MWMNavigationController.h"
-#include "indexer/map_style.hpp"
-
-#include "storage/index.hpp"
-
@class MapViewController;
-@class LocationManager;
@interface MapsAppDelegate
: UIResponder<UIApplicationDelegate, UIAlertViewDelegate, DownloadIndicatorProtocol>
@@ -41,6 +36,4 @@
- (void)showMap;
- (void)showAlertIfRequired;
-- (void)setMapStyle:(MapStyle)mapStyle;
-
@end
diff --git a/iphone/Maps/Classes/MapsAppDelegate.mm b/iphone/Maps/Classes/MapsAppDelegate.mm
index 598c828380..95a02d976e 100644
--- a/iphone/Maps/Classes/MapsAppDelegate.mm
+++ b/iphone/Maps/Classes/MapsAppDelegate.mm
@@ -1,43 +1,27 @@
#import "MapsAppDelegate.h"
#import <CoreSpotlight/CoreSpotlight.h>
-#import <CoreTelephony/CTTelephonyNetworkInfo.h>
#import <FBSDKCoreKit/FBSDKCoreKit.h>
-#import "AppInfo.h"
#import "EAGLView.h"
#import "LocalNotificationManager.h"
-#import "MWMAlertViewController.h"
#import "MWMAuthorizationCommon.h"
#import "MWMCommon.h"
-#import "MWMController.h"
#import "MWMCoreRouterType.h"
#import "MWMFrameworkListener.h"
#import "MWMFrameworkObservers.h"
-#import "MWMKeyboard.h"
-#import "MWMLocationManager.h"
#import "MWMMapViewControlsManager.h"
#import "MWMPushNotifications.h"
#import "MWMRoutePoint+CPP.h"
#import "MWMRouter.h"
#import "MWMSearch+CoreSpotlight.h"
-#import "MWMSettings.h"
-#import "MWMStorage.h"
-#import "MWMTextToSpeech.h"
#import "MapViewController.h"
#import "Statistics.h"
#import "SwiftBridge.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
-#include <sys/xattr.h>
+#include "Framework.h"
-#include "indexer/osm_editor.hpp"
#include "map/gps_tracker.hpp"
#include "platform/http_thread_apple.h"
-#include "platform/platform.hpp"
-#include "platform/preferred_languages.hpp"
-#include "platform/settings.hpp"
-#include "std/target_os.hpp"
-#include "storage/storage_defines.hpp"
// If you have a "missing header error" here, then please run configure.sh script in the root repo
// folder.
@@ -145,8 +129,6 @@ using namespace osm_auth_ios;
@property(nonatomic) NSInteger standbyCounter;
-@property(nonatomic, readwrite) LocationManager * locationManager;
-
@end
@implementation MapsAppDelegate
@@ -731,7 +713,6 @@ using namespace osm_auth_ios;
[UIApplication sharedApplication].networkActivityIndicatorVisible = YES;
}
-- (void)setMapStyle:(MapStyle)mapStyle { GetFramework().SetMapStyle(mapStyle); }
+ (NSDictionary *)navigationBarTextAttributes
{
return @{
diff --git a/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm b/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm
index 844f7f2c8c..b861e076c0 100644
--- a/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm
+++ b/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm
@@ -4,13 +4,14 @@
#import "MWMBottomMenuViewController.h"
#import "MWMCircularProgress.h"
#import "MWMCommon.h"
+#import "MWMConsts.h"
#import "MWMFrameworkListener.h"
#import "MWMFrameworkObservers.h"
#import "MWMLocationManager.h"
+#import "MWMRouter.h"
#import "MWMSettings.h"
#import "MWMStorage.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
#include "Framework.h"
@@ -21,7 +22,7 @@ namespace
{
CGSize constexpr kInitialDialogSize = {200, 200};
-BOOL canAutoDownload(TCountryId const & countryId)
+BOOL canAutoDownload(storage::TCountryId const & countryId)
{
if (![MWMSettings autoDownloadEnabled])
return NO;
diff --git a/iphone/Maps/Classes/Widgets/MWMMapWidgets.mm b/iphone/Maps/Classes/Widgets/MWMMapWidgets.mm
index a6cccaf5af..3466d2f9d6 100644
--- a/iphone/Maps/Classes/Widgets/MWMMapWidgets.mm
+++ b/iphone/Maps/Classes/Widgets/MWMMapWidgets.mm
@@ -1,12 +1,7 @@
#import "MWMMapWidgets.h"
-#import "MWMCommon.h"
#import "EAGLView.h"
-#import "MWMNavigationDashboardManager.h"
#import "MapViewController.h"
-#include "drape_frontend/gui/skin.hpp"
-#include "std/unique_ptr.hpp"
-
@interface MWMMapWidgets ()
@property(nonatomic) float visualScale;
diff --git a/iphone/Maps/Common/MWMCommon.h b/iphone/Maps/Common/MWMCommon.h
index b83e8477d1..887e966acc 100644
--- a/iphone/Maps/Common/MWMCommon.h
+++ b/iphone/Maps/Common/MWMCommon.h
@@ -56,11 +56,6 @@ static inline CGFloat statusBarHeight()
return MIN(statusBarSize.height, statusBarSize.width);
}
-static inline void runAsyncOnMainQueue(dispatch_block_t block)
-{
- dispatch_async(dispatch_get_main_queue(), block);
-}
-
static inline void setStatusBarBackgroundColor(UIColor * color)
{
UIView * statusBar =
diff --git a/iphone/Maps/Common/Statistics/MWMCustomFacebookEvents.h b/iphone/Maps/Common/Statistics/MWMCustomFacebookEvents.h
index 7c77ae6c56..1690e21723 100644
--- a/iphone/Maps/Common/Statistics/MWMCustomFacebookEvents.h
+++ b/iphone/Maps/Common/Statistics/MWMCustomFacebookEvents.h
@@ -1,5 +1,3 @@
-#import <Foundation/Foundation.h>
-
// Special logic for custom Facebook events to optimize marketing campaigns.
@interface MWMCustomFacebookEvents : NSObject
diff --git a/iphone/Maps/Core/Ads/MWMBannerHelpers.h b/iphone/Maps/Core/Ads/MWMBannerHelpers.h
index 8f2b1881f0..ce50462ffe 100644
--- a/iphone/Maps/Core/Ads/MWMBannerHelpers.h
+++ b/iphone/Maps/Core/Ads/MWMBannerHelpers.h
@@ -3,6 +3,8 @@
#include "partners_api/banner.hpp"
+#include <vector>
+
namespace banner_helpers
{
static inline MWMBannerType MatchBannerType(ads::Banner::Type coreType)
@@ -22,7 +24,8 @@ static inline MWMCoreBanner * MatchBanner(ads::Banner const & banner)
bannerID:@(banner.m_bannerId.c_str())];
}
-static inline NSArray<MWMCoreBanner *> * MatchPriorityBanners(vector<ads::Banner> const & banners)
+static inline NSArray<MWMCoreBanner *> * MatchPriorityBanners(
+ std::vector<ads::Banner> const & banners)
{
NSMutableArray<MWMCoreBanner *> * mBanners = [@[] mutableCopy];
for (auto const & banner : banners)
diff --git a/iphone/Maps/Core/Framework/MWMFrameworkHelper.mm b/iphone/Maps/Core/Framework/MWMFrameworkHelper.mm
index f75b405f75..72b7345eb9 100644
--- a/iphone/Maps/Core/Framework/MWMFrameworkHelper.mm
+++ b/iphone/Maps/Core/Framework/MWMFrameworkHelper.mm
@@ -1,5 +1,4 @@
#import "MWMFrameworkHelper.h"
-#import "CLLocation+Mercator.h"
#import "MWMLocationManager.h"
#import "MapViewController.h"
diff --git a/iphone/Maps/Core/Framework/MWMFrameworkListener.h b/iphone/Maps/Core/Framework/MWMFrameworkListener.h
index b7cfa27c7d..7ac163dbd0 100644
--- a/iphone/Maps/Core/Framework/MWMFrameworkListener.h
+++ b/iphone/Maps/Core/Framework/MWMFrameworkListener.h
@@ -1,7 +1,5 @@
#import "MWMFrameworkObservers.h"
-#include "platform/location.hpp"
-
@interface MWMFrameworkListener : NSObject
+ (MWMFrameworkListener *)listener;
diff --git a/iphone/Maps/Core/Framework/MWMFrameworkListener.mm b/iphone/Maps/Core/Framework/MWMFrameworkListener.mm
index 270ea20014..573415b20b 100644
--- a/iphone/Maps/Core/Framework/MWMFrameworkListener.mm
+++ b/iphone/Maps/Core/Framework/MWMFrameworkListener.mm
@@ -1,10 +1,7 @@
#import "MWMFrameworkListener.h"
-#import "MapsAppDelegate.h"
#include "Framework.h"
-#include "std/mutex.hpp"
-
namespace
{
using Observer = id<MWMFrameworkObserver>;
diff --git a/iphone/Maps/Core/Location/MWMLocationManager.mm b/iphone/Maps/Core/Location/MWMLocationManager.mm
index 11105f3972..cf26ff223f 100644
--- a/iphone/Maps/Core/Location/MWMLocationManager.mm
+++ b/iphone/Maps/Core/Location/MWMLocationManager.mm
@@ -1,22 +1,17 @@
#import "MWMLocationManager.h"
#import <Pushwoosh/PushNotificationManager.h>
#import "MWMAlertViewController.h"
-#import "MWMCommon.h"
-#import "MWMController.h"
#import "MWMLocationObserver.h"
#import "MWMLocationPredictor.h"
#import "MWMRouter.h"
#import "MapsAppDelegate.h"
#import "Statistics.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
#include "map/gps_tracker.hpp"
-#include "std/map.hpp"
-
namespace
{
using Observer = id<MWMLocationObserver>;
@@ -196,7 +191,7 @@ void setPermissionRequested()
+ (void)addObserver:(Observer)observer
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
MWMLocationManager * manager = [self manager];
[manager.observers addObject:observer];
[manager processLocationUpdate:manager.lastLocationInfo];
@@ -205,7 +200,7 @@ void setPermissionRequested()
+ (void)removeObserver:(Observer)observer
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[[self manager].observers removeObject:observer];
});
}
@@ -561,7 +556,7 @@ void setPermissionRequested()
}
else
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[self updateFrameworkInfo];
});
}
diff --git a/iphone/Maps/Core/Notifications/LocalNotificationManager.mm b/iphone/Maps/Core/Notifications/LocalNotificationManager.mm
index 1ec6a5a2a2..3a042929eb 100644
--- a/iphone/Maps/Core/Notifications/LocalNotificationManager.mm
+++ b/iphone/Maps/Core/Notifications/LocalNotificationManager.mm
@@ -1,18 +1,12 @@
#import "LocalNotificationManager.h"
#import "CLLocation+Mercator.h"
-#import "MWMCommon.h"
#import "MWMStorage.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
-#include "platform/platform.hpp"
-#include "storage/country_info_getter.hpp"
-#include "storage/storage_defines.hpp"
#include "storage/storage_helpers.hpp"
namespace
diff --git a/iphone/Maps/Core/Routing/MWMRouter.mm b/iphone/Maps/Core/Routing/MWMRouter.mm
index e96f157fee..f3c80c5500 100644
--- a/iphone/Maps/Core/Routing/MWMRouter.mm
+++ b/iphone/Maps/Core/Routing/MWMRouter.mm
@@ -1,8 +1,5 @@
#import "MWMRouter.h"
#import <Crashlytics/Crashlytics.h>
-#import <Pushwoosh/PushNotificationManager.h>
-#import "CLLocation+Mercator.h"
-#import "MWMAlertViewController.h"
#import "MWMConsts.h"
#import "MWMCoreRouterType.h"
#import "MWMFrameworkListener.h"
@@ -13,9 +10,7 @@
#import "MWMNavigationDashboardManager+Entity.h"
#import "MWMRoutePoint+CPP.h"
#import "MWMSearch.h"
-#import "MWMSettings.h"
#import "MWMStorage.h"
-#import "MWMTextToSpeech.h"
#import "MapViewController.h"
#import "MapsAppDelegate.h"
#import "Statistics.h"
@@ -25,9 +20,6 @@
#include "Framework.h"
#include "platform/local_country_file_utils.hpp"
-#include "platform/measurement_utils.hpp"
-
-#include "map/routing_manager.hpp"
using namespace routing;
diff --git a/iphone/Maps/Core/Search/MWMSearch+CoreSpotlight.mm b/iphone/Maps/Core/Search/MWMSearch+CoreSpotlight.mm
index a9ee13fc56..d13b2a07d7 100644
--- a/iphone/Maps/Core/Search/MWMSearch+CoreSpotlight.mm
+++ b/iphone/Maps/Core/Search/MWMSearch+CoreSpotlight.mm
@@ -8,8 +8,6 @@
#include "Framework.h"
-#include "search/displayed_categories.hpp"
-
@implementation MWMSearch (CoreSpotlight)
+ (void)addCategoriesToSpotlight
diff --git a/iphone/Maps/Core/Search/MWMSearch.h b/iphone/Maps/Core/Search/MWMSearch.h
index a5e2a6aa08..ac73ba1f9e 100644
--- a/iphone/Maps/Core/Search/MWMSearch.h
+++ b/iphone/Maps/Core/Search/MWMSearch.h
@@ -3,7 +3,10 @@
#import "MWMSearchItemType.h"
#import "MWMSearchObserver.h"
-#include "search/result.hpp"
+namespace search
+{
+class Result;
+} // namespace search
@interface MWMSearch : NSObject
diff --git a/iphone/Maps/Core/Search/MWMSearch.mm b/iphone/Maps/Core/Search/MWMSearch.mm
index cf00f1658f..7ad03aa156 100644
--- a/iphone/Maps/Core/Search/MWMSearch.mm
+++ b/iphone/Maps/Core/Search/MWMSearch.mm
@@ -1,9 +1,6 @@
#import "MWMSearch.h"
#import <Crashlytics/Crashlytics.h>
-#import "MWMAlertViewController.h"
#import "MWMBannerHelpers.h"
-#import "MWMCommon.h"
-#import "MWMLocationManager.h"
#import "MWMSearchHotelsFilterViewController.h"
#import "SwiftBridge.h"
@@ -12,8 +9,6 @@
#include "partners_api/ads_engine.hpp"
#include "search/everywhere_search_params.hpp"
-#include "search/hotels_classifier.hpp"
-#include "search/query_saver.hpp"
#include "search/viewport_search_params.hpp"
namespace
diff --git a/iphone/Maps/Core/Settings/MWMSettings.mm b/iphone/Maps/Core/Settings/MWMSettings.mm
index afaaf423b4..a983139f7e 100644
--- a/iphone/Maps/Core/Settings/MWMSettings.mm
+++ b/iphone/Maps/Core/Settings/MWMSettings.mm
@@ -1,10 +1,7 @@
#import "MWMSettings.h"
#import "MWMCoreUnits.h"
-#import "MWMFrameworkHelper.h"
#import "MWMMapViewControlsManager.h"
-#import "MapsAppDelegate.h"
#import "SwiftBridge.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
diff --git a/iphone/Maps/Core/Storage/MWMStorage.h b/iphone/Maps/Core/Storage/MWMStorage.h
index 68363d414d..160d66cab8 100644
--- a/iphone/Maps/Core/Storage/MWMStorage.h
+++ b/iphone/Maps/Core/Storage/MWMStorage.h
@@ -1,5 +1,3 @@
-#import "MWMAlertViewController.h"
-
#include "storage/index.hpp"
@interface MWMStorage : NSObject
diff --git a/iphone/Maps/Core/Storage/MWMStorage.mm b/iphone/Maps/Core/Storage/MWMStorage.mm
index 7edcd29565..13b1606b8d 100644
--- a/iphone/Maps/Core/Storage/MWMStorage.mm
+++ b/iphone/Maps/Core/Storage/MWMStorage.mm
@@ -1,11 +1,9 @@
#import "MWMStorage.h"
-#import "MWMCommon.h"
+#import "MWMAlertViewController.h"
#import "MWMRouter.h"
#include "Framework.h"
-#include "platform/platform.hpp"
-
#include "storage/storage_helpers.hpp"
using namespace storage;
diff --git a/iphone/Maps/Core/TextToSpeech/MWMTextToSpeech.mm b/iphone/Maps/Core/TextToSpeech/MWMTextToSpeech.mm
index 654385ebc1..df0f553585 100644
--- a/iphone/Maps/Core/TextToSpeech/MWMTextToSpeech.mm
+++ b/iphone/Maps/Core/TextToSpeech/MWMTextToSpeech.mm
@@ -6,9 +6,10 @@
#include "LocaleTranslator.h"
-#include "Framework.h"
#include "platform/languages.hpp"
+#include "base/logging.hpp"
+
using namespace locale_translator;
namespace
@@ -17,18 +18,18 @@ NSString * const kUserDefaultsTTSLanguageBcp47 = @"UserDefaultsTTSLanguageBcp47"
NSString * const kIsTTSEnabled = @"UserDefaultsNeedToEnableTTS";
NSString * const kDefaultLanguage = @"en-US";
-vector<pair<string, string>> availableLanguages()
+std::vector<std::pair<string, string>> availableLanguages()
{
NSArray<AVSpeechSynthesisVoice *> * voices = [AVSpeechSynthesisVoice speechVoices];
- vector<pair<string, string>> native;
+ std::vector<std::pair<string, string>> native;
for (AVSpeechSynthesisVoice * v in voices)
native.emplace_back(make_pair(bcp47ToTwineLanguage(v.language), [v.language UTF8String]));
using namespace routing::turns::sound;
- vector<pair<string, string>> result;
+ std::vector<std::pair<string, string>> result;
for (auto const & p : kLanguageList)
{
- for (pair<string, string> const & lang : native)
+ for (std::pair<string, string> const & lang : native)
{
if (lang.first == p.first)
{
@@ -47,7 +48,7 @@ using Observers = NSHashTable<Observer>;
@interface MWMTextToSpeech ()<AVSpeechSynthesizerDelegate>
{
- vector<pair<string, string>> _availableLanguages;
+ std::vector<std::pair<string, string>> _availableLanguages;
}
@property(nonatomic) AVSpeechSynthesizer * speechSynthesizer;
@@ -86,7 +87,7 @@ using Observers = NSHashTable<Observer>;
else
preferedLanguageBcp47 = [AVSpeechSynthesisVoice currentLanguageCode];
- pair<string, string> const lan =
+ std::pair<string, string> const lan =
make_pair([preferedLanguageBcp47 UTF8String],
tts::translatedTwine(bcp47ToTwineLanguage(preferedLanguageBcp47)));
@@ -119,7 +120,7 @@ using Observers = NSHashTable<Observer>;
}
- (void)dealloc { self.speechSynthesizer.delegate = nil; }
-- (vector<pair<string, string>>)availableLanguages { return _availableLanguages; }
+- (std::vector<std::pair<string, string>>)availableLanguages { return _availableLanguages; }
- (void)setNotificationsLocale:(NSString *)locale
{
[Statistics logEvent:kStatEventName(kStatTTSSettings, kStatChangeLanguage)
@@ -156,7 +157,7 @@ using Observers = NSHashTable<Observer>;
[self createSynthesizer];
[self setAudioSessionActive:active];
[MWMRouter enableTurnNotifications:active];
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[self onTTSStatusUpdated];
});
}
@@ -286,9 +287,9 @@ namespace tts
string translatedTwine(string const & twine)
{
auto const & list = routing::turns::sound::kLanguageList;
- auto const it = find_if(list.begin(), list.end(), [&twine](pair<string, string> const & pair) {
- return pair.first == twine;
- });
+ auto const it =
+ find_if(list.begin(), list.end(),
+ [&twine](std::pair<string, string> const & pair) { return pair.first == twine; });
if (it != list.end())
return it->second;
diff --git a/iphone/Maps/Core/Traffic/MWMTrafficManager.mm b/iphone/Maps/Core/Traffic/MWMTrafficManager.mm
index aaca00809c..77a071f081 100644
--- a/iphone/Maps/Core/Traffic/MWMTrafficManager.mm
+++ b/iphone/Maps/Core/Traffic/MWMTrafficManager.mm
@@ -1,10 +1,7 @@
#import "MWMTrafficManager.h"
-#import "MWMCommon.h"
#include "Framework.h"
-#include "map/traffic_manager.hpp"
-
namespace
{
using Observer = id<MWMTrafficManagerObserver>;
diff --git a/iphone/Maps/Maps.xcodeproj/project.pbxproj b/iphone/Maps/Maps.xcodeproj/project.pbxproj
index b93dbc960c..7a21df565d 100644
--- a/iphone/Maps/Maps.xcodeproj/project.pbxproj
+++ b/iphone/Maps/Maps.xcodeproj/project.pbxproj
@@ -1465,9 +1465,6 @@
F6E2FEBD1E097BA00083EBEC /* MWMPPPreviewLayoutHelper.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE01E097B9F0083EBEC /* MWMPPPreviewLayoutHelper.mm */; };
F6E2FEBE1E097BA00083EBEC /* MWMPPPreviewLayoutHelper.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE01E097B9F0083EBEC /* MWMPPPreviewLayoutHelper.mm */; };
F6E2FEBF1E097BA00083EBEC /* MWMPPPreviewLayoutHelper.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE01E097B9F0083EBEC /* MWMPPPreviewLayoutHelper.mm */; };
- F6E2FEC01E097BA00083EBEC /* MWMConsole.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE41E097B9F0083EBEC /* MWMConsole.mm */; };
- F6E2FEC11E097BA00083EBEC /* MWMConsole.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE41E097B9F0083EBEC /* MWMConsole.mm */; };
- F6E2FEC21E097BA00083EBEC /* MWMConsole.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE41E097B9F0083EBEC /* MWMConsole.mm */; };
F6E2FEC31E097BA00083EBEC /* MWMSearchFilterPresentationController.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE71E097B9F0083EBEC /* MWMSearchFilterPresentationController.mm */; };
F6E2FEC41E097BA00083EBEC /* MWMSearchFilterPresentationController.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE71E097B9F0083EBEC /* MWMSearchFilterPresentationController.mm */; };
F6E2FEC51E097BA00083EBEC /* MWMSearchFilterPresentationController.mm in Sources */ = {isa = PBXBuildFile; fileRef = F6E2FCE71E097B9F0083EBEC /* MWMSearchFilterPresentationController.mm */; };
@@ -2401,7 +2398,7 @@
F6E2FC1E1E097B9F0083EBEC /* MWMBaseMapDownloaderViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMBaseMapDownloaderViewController.h; sourceTree = "<group>"; };
F6E2FC1F1E097B9F0083EBEC /* MWMBaseMapDownloaderViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; lineEnding = 0; path = MWMBaseMapDownloaderViewController.mm; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
F6E2FC201E097B9F0083EBEC /* MWMMapDownloaderProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMMapDownloaderProtocol.h; sourceTree = "<group>"; };
- F6E2FC211E097B9F0083EBEC /* MWMMapDownloaderTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMMapDownloaderTypes.h; sourceTree = "<group>"; };
+ F6E2FC211E097B9F0083EBEC /* MWMMapDownloaderMode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMMapDownloaderMode.h; sourceTree = "<group>"; };
F6E2FC221E097B9F0083EBEC /* MWMMapDownloaderViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMMapDownloaderViewController.h; sourceTree = "<group>"; };
F6E2FC231E097B9F0083EBEC /* MWMMapDownloaderViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MWMMapDownloaderViewController.mm; sourceTree = "<group>"; };
F6E2FC251E097B9F0083EBEC /* MWMNoMapsView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMNoMapsView.h; sourceTree = "<group>"; };
@@ -2536,8 +2533,6 @@
F6E2FCDE1E097B9F0083EBEC /* _MWMPPPTitle.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = _MWMPPPTitle.xib; sourceTree = "<group>"; };
F6E2FCDF1E097B9F0083EBEC /* MWMPPPreviewLayoutHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMPPPreviewLayoutHelper.h; sourceTree = "<group>"; };
F6E2FCE01E097B9F0083EBEC /* MWMPPPreviewLayoutHelper.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; lineEnding = 0; path = MWMPPPreviewLayoutHelper.mm; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
- F6E2FCE31E097B9F0083EBEC /* MWMConsole.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMConsole.h; sourceTree = "<group>"; };
- F6E2FCE41E097B9F0083EBEC /* MWMConsole.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MWMConsole.mm; sourceTree = "<group>"; };
F6E2FCE61E097B9F0083EBEC /* MWMSearchFilterPresentationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMSearchFilterPresentationController.h; sourceTree = "<group>"; };
F6E2FCE71E097B9F0083EBEC /* MWMSearchFilterPresentationController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MWMSearchFilterPresentationController.mm; sourceTree = "<group>"; };
F6E2FCE91E097B9F0083EBEC /* MWMSearchFilterTransitioning.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MWMSearchFilterTransitioning.h; sourceTree = "<group>"; };
@@ -3990,7 +3985,7 @@
F6E2FC1E1E097B9F0083EBEC /* MWMBaseMapDownloaderViewController.h */,
F6E2FC1F1E097B9F0083EBEC /* MWMBaseMapDownloaderViewController.mm */,
F6E2FC201E097B9F0083EBEC /* MWMMapDownloaderProtocol.h */,
- F6E2FC211E097B9F0083EBEC /* MWMMapDownloaderTypes.h */,
+ F6E2FC211E097B9F0083EBEC /* MWMMapDownloaderMode.h */,
F6E2FC221E097B9F0083EBEC /* MWMMapDownloaderViewController.h */,
F6E2FC231E097B9F0083EBEC /* MWMMapDownloaderViewController.mm */,
F6E2FC241E097B9F0083EBEC /* NoMaps */,
@@ -4354,7 +4349,6 @@
F6E2FCE11E097B9F0083EBEC /* Search */ = {
isa = PBXGroup;
children = (
- F6E2FCE21E097B9F0083EBEC /* Console */,
F6E2FCE51E097B9F0083EBEC /* Filters */,
F6E2FCF21E097B9F0083EBEC /* MWMSearchChangeModeView.h */,
F6E2FCF31E097B9F0083EBEC /* MWMSearchChangeModeView.mm */,
@@ -4383,15 +4377,6 @@
path = Search;
sourceTree = "<group>";
};
- F6E2FCE21E097B9F0083EBEC /* Console */ = {
- isa = PBXGroup;
- children = (
- F6E2FCE31E097B9F0083EBEC /* MWMConsole.h */,
- F6E2FCE41E097B9F0083EBEC /* MWMConsole.mm */,
- );
- path = Console;
- sourceTree = "<group>";
- };
F6E2FCE51E097B9F0083EBEC /* Filters */ = {
isa = PBXGroup;
children = (
@@ -5499,7 +5484,6 @@
F68BDF1B1EF80DE90009BB81 /* MWMUGCCommentCell.mm in Sources */,
F63AF50E1EA6215100A1DB98 /* FilterPriceCategoryCell.swift in Sources */,
34D3AFF51E37A36A004100F9 /* UICollectionView+Cells.swift in Sources */,
- F6E2FEC01E097BA00083EBEC /* MWMConsole.mm in Sources */,
3490D2DE1CE9DD2500D0B838 /* MWMSideButtons.mm in Sources */,
340708771F2B5D6C00029ECC /* DimBackground.swift in Sources */,
F6E2FDF71E097BA00083EBEC /* MWMOpeningHoursAllDayTableViewCell.mm in Sources */,
@@ -5838,7 +5822,6 @@
F63AF50F1EA6215100A1DB98 /* FilterPriceCategoryCell.swift in Sources */,
34D3AFF61E37A36A004100F9 /* UICollectionView+Cells.swift in Sources */,
6741A9A91BF340DE002C974C /* MWMDefaultAlert.mm in Sources */,
- F6E2FEC11E097BA00083EBEC /* MWMConsole.mm in Sources */,
340708781F2B5D6C00029ECC /* DimBackground.swift in Sources */,
3490D2DF1CE9DD2500D0B838 /* MWMSideButtons.mm in Sources */,
F6E2FDF81E097BA00083EBEC /* MWMOpeningHoursAllDayTableViewCell.mm in Sources */,
@@ -6178,7 +6161,6 @@
34D3AFF71E37A36A004100F9 /* UICollectionView+Cells.swift in Sources */,
340475601E081A4600C92850 /* MWMLocationPredictor.mm in Sources */,
340708791F2B5D6C00029ECC /* DimBackground.swift in Sources */,
- F6E2FEC21E097BA00083EBEC /* MWMConsole.mm in Sources */,
845E4B1C1DEC839800D6BED8 /* MWMTrafficButtonViewController.mm in Sources */,
340B33C71F3AEFDB00A8C1B4 /* MWMRouter+RouteManager.mm in Sources */,
34763EF41F2F5F6400F4D2D3 /* MWMiPhoneRoutePreview.mm in Sources */,
@@ -6587,7 +6569,6 @@
6741AA551BF340DE002C974C /* Simulator */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -6601,7 +6582,6 @@
6741AA561BF340DE002C974C /* Simulator Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -6615,7 +6595,6 @@
6741AA571BF340DE002C974C /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -6630,7 +6609,6 @@
6741AA591BF340DE002C974C /* AdHoc */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -6644,7 +6622,6 @@
6741AA5A1BF340DE002C974C /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -6659,7 +6636,6 @@
6741AA5C1BF340DE002C974C /* Production Full */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
ENABLE_BITCODE = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -7028,7 +7004,6 @@
FAAB411A149BA83500C245B1 /* Simulator */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
@@ -7132,7 +7107,6 @@
FAAB411C149BA84700C245B1 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
@@ -7239,7 +7213,6 @@
FAAB411E149BA85500C245B1 /* AdHoc */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
@@ -7346,7 +7319,6 @@
FAAB4120149BA86000C245B1 /* Production Full */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
@@ -7453,7 +7425,6 @@
FABB561F149CD957006969C0 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
@@ -7561,7 +7532,6 @@
FACFE54515F8F35600CE8B20 /* Simulator Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- CLANG_ENABLE_MODULES = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/3party/MoPubSDK/AdNetworkSupport/Facebook/SDK",
diff --git a/iphone/Maps/UI/Autoupdate/MWMAutoupdateController.mm b/iphone/Maps/UI/Autoupdate/MWMAutoupdateController.mm
index 25f81c4c72..a0308cefb9 100644
--- a/iphone/Maps/UI/Autoupdate/MWMAutoupdateController.mm
+++ b/iphone/Maps/UI/Autoupdate/MWMAutoupdateController.mm
@@ -6,8 +6,6 @@
#import "Statistics.h"
#import "UIButton+RuntimeAttributes.h"
-#include <vector>
-
namespace
{
string RootId() { return GetFramework().GetStorage().GetRootId(); }
diff --git a/iphone/Maps/UI/BottomMenu/MWMBottomMenuControllerProtocol.h b/iphone/Maps/UI/BottomMenu/MWMBottomMenuControllerProtocol.h
index d5a24c4ac2..a707b0ddeb 100644
--- a/iphone/Maps/UI/BottomMenu/MWMBottomMenuControllerProtocol.h
+++ b/iphone/Maps/UI/BottomMenu/MWMBottomMenuControllerProtocol.h
@@ -1,10 +1,10 @@
-#import "MWMMapDownloaderTypes.h"
+#import "MWMMapDownloaderMode.h"
-#include "platform/location.hpp"
+#include "geometry/point2d.hpp"
@protocol MWMBottomMenuControllerProtocol<NSObject>
-- (void)actionDownloadMaps:(mwm::DownloaderMode)mode;
+- (void)actionDownloadMaps:(MWMMapDownloaderMode)mode;
- (void)addPlace:(BOOL)isBusiness hasPoint:(BOOL)hasPoint point:(m2::PointD const &)point;
- (void)didFinishAddingPlace;
diff --git a/iphone/Maps/UI/BottomMenu/MWMBottomMenuView.mm b/iphone/Maps/UI/BottomMenu/MWMBottomMenuView.mm
index fbe16dd027..b87b164294 100644
--- a/iphone/Maps/UI/BottomMenu/MWMBottomMenuView.mm
+++ b/iphone/Maps/UI/BottomMenu/MWMBottomMenuView.mm
@@ -1,15 +1,7 @@
#import "MWMBottomMenuView.h"
-#import "EAGLView.h"
#import "MWMAvailableAreaAffectDirection.h"
-#import "MWMBottomMenuViewController.h"
#import "MWMButton.h"
#import "MWMCommon.h"
-#import "MWMRouter.h"
-#import "MWMSideButtons.h"
-#import "MapsAppDelegate.h"
-#import "UIButton+RuntimeAttributes.h"
-#import "UIImageView+Coloring.h"
-#import "UIView+RuntimeAttributes.h"
#include "Framework.h"
@@ -38,8 +30,6 @@ CGFloat constexpr kDefaultMenuButtonWidth = 60;
@property(nonatomic) IBOutletCollection(NSLayoutConstraint) NSArray * mainButtonConstraintsLeftToRight;
-@property(weak, nonatomic) IBOutlet MWMBottomMenuViewController * owner;
-
@property(nonatomic) CGFloat layoutDuration;
@property(nonatomic) CGRect availableArea;
diff --git a/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.mm b/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.mm
index 3c621687d6..a9cb039a58 100644
--- a/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.mm
+++ b/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.mm
@@ -1,34 +1,16 @@
#import "MWMBottomMenuViewController.h"
-#import <Pushwoosh/PushNotificationManager.h>
-#import "EAGLView.h"
#import "MWMActivityViewController.h"
#import "MWMBottomMenuCollectionViewCell.h"
#import "MWMBottomMenuControllerProtocol.h"
#import "MWMBottomMenuLayout.h"
-#import "MWMBottomMenuView.h"
#import "MWMButton.h"
#import "MWMCommon.h"
-#import "MWMFrameworkListener.h"
-#import "MWMFrameworkObservers.h"
-#import "MWMLocationManager.h"
#import "MWMMapViewControlsManager.h"
-#import "MWMRouter.h"
-#import "MWMSearchManager.h"
-#import "MWMSettingsViewController.h"
-#import "MWMTextToSpeech.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
-#import "UIImageView+Coloring.h"
-#import "UIViewController+Navigation.h"
-
-#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
-#include "platform/mwm_version.hpp"
-
extern NSString * const kAlohalyticsTapEventKey;
extern NSString * const kSearchStateKey;
@@ -245,7 +227,7 @@ typedef NS_ENUM(NSUInteger, MWMBottomMenuViewCell) {
{
[Statistics logEvent:kStatMenu withParameters:@{kStatButton : kStatDownloadMaps}];
self.state = MWMBottomMenuStateInactive;
- [self.delegate actionDownloadMaps:mwm::DownloaderMode::Downloaded];
+ [self.delegate actionDownloadMaps:MWMMapDownloaderModeDownloaded];
}
- (IBAction)menuActionOpenSettings
@@ -350,7 +332,7 @@ typedef NS_ENUM(NSUInteger, MWMBottomMenuViewCell) {
- (void)setState:(MWMBottomMenuState)state
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[self.controller setNeedsStatusBarAppearanceUpdate];
});
MWMBottomMenuView * view = self.menuView;
diff --git a/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.xib b/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.xib
index 53d03e2af7..f63be97e08 100644
--- a/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.xib
+++ b/iphone/Maps/UI/BottomMenu/MWMBottomMenuViewController.xib
@@ -168,7 +168,6 @@
<outlet property="mainButtonsHeight" destination="HtR-j8-Qpc" id="eF8-KH-F9n"/>
<outlet property="menuButton" destination="YLY-C4-SBu" id="A5G-Bc-IlQ"/>
<outlet property="menuButtonWidth" destination="ams-2s-vhw" id="Til-tN-VJX"/>
- <outlet property="owner" destination="-1" id="qBx-4k-WvI"/>
<outlet property="searchButton" destination="IzQ-aQ-aPH" id="2dy-QI-T39"/>
<outlet property="separatorHeight" destination="Kgm-bO-O6Q" id="RGg-dL-lKg"/>
<outletCollection property="mainButtonConstraintsLeftToRight" destination="RMv-Kx-9s6" id="bdV-lr-UW4"/>
diff --git a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderPlaceTableViewCell.mm b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderPlaceTableViewCell.mm
index b32455d49a..943f10190b 100644
--- a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderPlaceTableViewCell.mm
+++ b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderPlaceTableViewCell.mm
@@ -1,5 +1,4 @@
#import "MWMMapDownloaderPlaceTableViewCell.h"
-#import "MWMCommon.h"
#include "Framework.h"
diff --git a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.h b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.h
index e523a73cee..76d52ab5a0 100644
--- a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.h
+++ b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.h
@@ -1,16 +1,19 @@
#import "MWMFrameworkObservers.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMMapDownloaderProtocol.h"
#import "MWMMapDownloaderTableViewCellProtocol.h"
-#import "MWMMapDownloaderTypes.h"
#import "MWMTableViewCell.h"
-#include "storage/storage.hpp"
+namespace storage
+{
+struct NodeAttrs;
+} // storage
@interface MWMMapDownloaderTableViewCell : MWMTableViewCell <MWMMapDownloaderTableViewCellProtocol, MWMFrameworkStorageObserver>
-@property (nonatomic) BOOL isHeightCell;
-@property (weak, nonatomic) id<MWMMapDownloaderProtocol> delegate;
-@property (nonatomic) mwm::DownloaderMode mode;
+@property(nonatomic) BOOL isHeightCell;
+@property(weak, nonatomic) id<MWMMapDownloaderProtocol> delegate;
+@property(nonatomic) MWMMapDownloaderMode mode;
- (void)config:(storage::NodeAttrs const &)nodeAttrs;
- (void)setCountryId:(NSString *)countryId searchQuery:(NSString *)query;
diff --git a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.mm b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.mm
index 9987513b36..8d8281cdf1 100644
--- a/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.mm
+++ b/iphone/Maps/UI/Downloader/Cells/MWMMapDownloaderTableViewCell.mm
@@ -63,7 +63,7 @@
unselectedAttrs:unselectedTitleAttrs];
TMwmSize size = nodeAttrs.m_mwmSize;
- bool const isModeDownloaded = self.mode == mwm::DownloaderMode::Downloaded;
+ bool const isModeDownloaded = self.mode == MWMMapDownloaderModeDownloaded;
switch (nodeAttrs.m_status)
{
@@ -93,7 +93,7 @@
{
MWMCircularProgress * progress = self.progress;
MWMButtonColoring const coloring =
- self.mode == mwm::DownloaderMode::Downloaded ? MWMButtonColoringBlack : MWMButtonColoringBlue;
+ self.mode == MWMMapDownloaderModeDownloaded ? MWMButtonColoringBlack : MWMButtonColoringBlue;
switch (nodeAttrs.m_status)
{
case NodeStatus::NotDownloaded:
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.h b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.h
index 79b5e26792..7661fea427 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.h
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.h
@@ -1,17 +1,19 @@
#import "MWMMapDownloaderButtonTableViewCell.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMMapDownloaderProtocol.h"
#import "MWMMapDownloaderTableViewCell.h"
-#import "MWMMapDownloaderTypes.h"
-
-#include "storage/index.hpp"
@interface MWMMapDownloaderDataSource : NSObject <UITableViewDataSource>
-@property (nonatomic, readonly) BOOL isParentRoot;
-@property (nonatomic, readonly) mwm::DownloaderMode mode;
-@property (weak, nonatomic, readonly) id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol> delegate;
+@property(nonatomic, readonly) BOOL isParentRoot;
+@property(nonatomic, readonly) MWMMapDownloaderMode mode;
+@property(weak, nonatomic, readonly)
+ id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>
+ delegate;
-- (instancetype)initWithDelegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate mode:(mwm::DownloaderMode)mode;
+- (instancetype)
+initWithDelegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate
+ mode:(MWMMapDownloaderMode)mode;
- (NSString *)parentCountryId;
- (NSString *)countryIdForIndexPath:(NSIndexPath *)indexPath;
- (Class)cellClassForIndexPath:(NSIndexPath *)indexPath;
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.mm b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.mm
index 35e4a9a376..67212f61f1 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.mm
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDataSource.mm
@@ -1,18 +1,15 @@
#import "MWMMapDownloaderDataSource.h"
-#import "MWMCommon.h"
-#import "MWMMapDownloaderLargeCountryTableViewCell.h"
#import "MWMMapDownloaderPlaceTableViewCell.h"
#import "MWMMapDownloaderSubplaceTableViewCell.h"
-#import "MWMMapDownloaderTypes.h"
#import "SwiftBridge.h"
-#include "Framework.h"
-
using namespace storage;
@implementation MWMMapDownloaderDataSource
-- (instancetype)initWithDelegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate mode:(mwm::DownloaderMode)mode
+- (instancetype)
+initWithDelegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate
+ mode:(MWMMapDownloaderMode)mode
{
self = [super init];
if (self)
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.h b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.h
index 67dff52d54..ad761b34ad 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.h
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.h
@@ -2,7 +2,11 @@
@interface MWMMapDownloaderDefaultDataSource : MWMMapDownloaderDataSource
-- (instancetype)initForRootCountryId:(NSString *)countryId delegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate mode:(mwm::DownloaderMode)mode;
+- (instancetype)
+initForRootCountryId:(NSString *)countryId
+ delegate:
+ (id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate
+ mode:(MWMMapDownloaderMode)mode;
- (void)load;
@end
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.mm b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.mm
index 0fafc6a38d..678e86bc5b 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.mm
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderDefaultDataSource.mm
@@ -1,10 +1,7 @@
#import "MWMMapDownloaderDefaultDataSource.h"
#import "MWMCommon.h"
-#import "MWMMapDownloaderButtonTableViewCell.h"
#import "MWMMapDownloaderLargeCountryTableViewCell.h"
#import "MWMMapDownloaderPlaceTableViewCell.h"
-#import "MWMStorage.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#include "Framework.h"
@@ -26,7 +23,6 @@ auto compareLocalNames = ^NSComparisonResult(NSString * s1, NSString * s2)
} // namespace
using namespace storage;
-using namespace mwm;
@interface MWMMapDownloaderDefaultDataSource ()
@@ -43,7 +39,11 @@ using namespace mwm;
@synthesize isParentRoot = _isParentRoot;
-- (instancetype)initForRootCountryId:(NSString *)countryId delegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate mode:(DownloaderMode)mode
+- (instancetype)
+initForRootCountryId:(NSString *)countryId
+ delegate:
+ (id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate
+ mode:(MWMMapDownloaderMode)mode
{
self = [super initWithDelegate:delegate mode:mode];
if (self)
@@ -61,7 +61,7 @@ using namespace mwm;
TCountriesVec downloadedChildren;
TCountriesVec availableChildren;
s.GetChildrenInGroups(m_parentId, downloadedChildren, availableChildren, true /* keepAvailableChildren */);
- if (self.mode == DownloaderMode::Available)
+ if (self.mode == MWMMapDownloaderModeAvailable)
{
self.downloadedCountries = nil;
[self configAvailableSections:availableChildren];
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSource.mm b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSource.mm
index b83f5d826f..d88716bf7a 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSource.mm
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSource.mm
@@ -1,7 +1,6 @@
#import "MWMMapDownloaderExtendedDataSource.h"
#import "CLLocation+Mercator.h"
#import "MWMLocationManager.h"
-#import "MapsAppDelegate.h"
#include "Framework.h"
@@ -34,7 +33,7 @@ auto constexpr extraSection = MWMMapDownloaderDataSourceExtraSection::NearMe;
- (void)load
{
[super load];
- if (self.mode == mwm::DownloaderMode::Available)
+ if (self.mode == MWMMapDownloaderModeAvailable)
[self configNearMeSection];
}
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSourceWithAds.mm b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSourceWithAds.mm
index 9a08bf974c..7ce28c4ae9 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSourceWithAds.mm
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderExtendedDataSourceWithAds.mm
@@ -24,7 +24,7 @@ auto constexpr extraSection = MWMMapDownloaderDataSourceExtraSection::Ads;
- (void)load
{
[super load];
- if (self.mode == mwm::DownloaderMode::Available)
+ if (self.mode == MWMMapDownloaderModeAvailable)
[self configAdsSection];
}
diff --git a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderSearchDataSource.mm b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderSearchDataSource.mm
index 2ed8305645..b79a4096a7 100644
--- a/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderSearchDataSource.mm
+++ b/iphone/Maps/UI/Downloader/DataSources/MWMMapDownloaderSearchDataSource.mm
@@ -19,7 +19,7 @@ using namespace storage;
- (instancetype)initWithSearchResults:(DownloaderSearchResults const &)results delegate:(id<MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>)delegate
{
- self = [super initWithDelegate:delegate mode:mwm::DownloaderMode::Available];
+ self = [super initWithDelegate:delegate mode:MWMMapDownloaderModeAvailable];
if (self)
{
NSMutableOrderedSet<NSString *> * nsSearchCountryIds =
diff --git a/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.h b/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.h
index c2bb32f970..a42f930213 100644
--- a/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.h
+++ b/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.h
@@ -1,6 +1,6 @@
#import "MWMMapDownloaderButtonTableViewCell.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMMapDownloaderProtocol.h"
-#import "MWMMapDownloaderTypes.h"
#import "MWMViewController.h"
@interface MWMBaseMapDownloaderViewController : MWMViewController <UITableViewDelegate, MWMMapDownloaderProtocol, MWMMapDownloaderButtonTableViewCellProtocol>
@@ -8,6 +8,6 @@
- (void)configTable;
- (void)configAllMapsView;
-- (void)setParentCountryId:(NSString *)parentId mode:(mwm::DownloaderMode)mode;
+- (void)setParentCountryId:(NSString *)parentId mode:(MWMMapDownloaderMode)mode;
@end
diff --git a/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.mm b/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.mm
index 0033a6859c..2d4f3abfbd 100644
--- a/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.mm
+++ b/iphone/Maps/UI/Downloader/MWMBaseMapDownloaderViewController.mm
@@ -1,7 +1,8 @@
-#import "MWMAlertViewController.h"
+#import "MWMBaseMapDownloaderViewController.h"
#import "MWMButton.h"
#import "MWMCommon.h"
#import "MWMFrameworkListener.h"
+#import "MWMFrameworkObservers.h"
#import "MWMMapDownloaderAdsTableViewCell.h"
#import "MWMMapDownloaderCellHeader.h"
#import "MWMMapDownloaderDefaultDataSource.h"
@@ -10,21 +11,16 @@
#import "MWMMapDownloaderPlaceTableViewCell.h"
#import "MWMMapDownloaderSubplaceTableViewCell.h"
#import "MWMMapDownloaderTableViewCell.h"
-#import "MWMMapDownloaderViewController.h"
#import "MWMMigrationViewController.h"
#import "MWMMyTarget.h"
#import "MWMSegue.h"
#import "MWMStorage.h"
#import "MWMToast.h"
-#import "MapsAppDelegate.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#import "UIViewController+Navigation.h"
#include "Framework.h"
-#include "storage/index.hpp"
-
namespace
{
@@ -58,7 +54,6 @@ NSString * const kControllerIdentifier = @"MWMMapDownloaderViewController";
} // namespace
using namespace storage;
-using namespace mwm;
@interface MWMBaseMapDownloaderViewController ()<UIScrollViewDelegate, MWMFrameworkStorageObserver,
MWMMyTargetDelegate>
@@ -82,7 +77,7 @@ using namespace mwm;
@property (nonatomic) BOOL forceFullReload;
@property (nonatomic, readonly) NSString * parentCountryId;
-@property (nonatomic, readonly) DownloaderMode mode;
+@property(nonatomic, readonly) MWMMapDownloaderMode mode;
@property (nonatomic) BOOL showAllMapsButtons;
@@ -132,7 +127,7 @@ using namespace mwm;
- (void)configNavBar
{
- BOOL const downloaded = self.mode == DownloaderMode::Downloaded;
+ BOOL const downloaded = self.mode == MWMMapDownloaderModeDownloaded;
if (self.dataSource.isParentRoot)
{
self.title = downloaded ? L(@"downloader_my_maps_title") : L(@"download_maps");
@@ -260,7 +255,7 @@ using namespace mwm;
{
self.showAllMapsButtons = NO;
}
- else if (self.mode == DownloaderMode::Downloaded)
+ else if (self.mode == MWMMapDownloaderModeDownloaded)
{
Storage::UpdateInfo updateInfo{};
s.GetUpdateInfo(parentCountryId, updateInfo);
@@ -357,7 +352,7 @@ using namespace mwm;
{
self.skipCountryEventProcessing = YES;
TCountryId const parentCountryId = self.parentCountryId.UTF8String;
- if (self.mode == DownloaderMode::Downloaded)
+ if (self.mode == MWMMapDownloaderModeDownloaded)
{
[Statistics logEvent:kStatDownloaderMapAction
withParameters:@{
@@ -630,7 +625,7 @@ using namespace mwm;
BOOL const isParentRoot = [self.parentCountryId isEqualToString:@(GetFramework().GetStorage().GetRootId().c_str())];
NSString * identifier = isParentRoot ? kControllerIdentifier : kBaseControllerIdentifier;
MWMBaseMapDownloaderViewController * vc = [self.storyboard instantiateViewControllerWithIdentifier:identifier];
- [vc setParentCountryId:self.parentCountryId mode:DownloaderMode::Available];
+ [vc setParentCountryId:self.parentCountryId mode:MWMMapDownloaderModeAvailable];
[MWMSegue segueFrom:self to:vc];
}
@@ -735,7 +730,7 @@ using namespace mwm;
#pragma mark - Configuration
-- (void)setParentCountryId:(NSString *)parentId mode:(DownloaderMode)mode
+- (void)setParentCountryId:(NSString *)parentId mode:(MWMMapDownloaderMode)mode
{
self.defaultDataSource = [[MWMMapDownloaderDefaultDataSource alloc] initForRootCountryId:parentId
delegate:self
@@ -761,12 +756,7 @@ using namespace mwm;
{
return self.dataSource.parentCountryId;
}
-
-- (DownloaderMode)mode
-{
- return self.dataSource.mode;
-}
-
+- (MWMMapDownloaderMode)mode { return self.dataSource.mode; }
- (void)setDataSource:(MWMMapDownloaderDataSource *)dataSource
{
self.forceFullReload = YES;
diff --git a/iphone/Maps/UI/Downloader/MWMMapDownloaderMode.h b/iphone/Maps/UI/Downloader/MWMMapDownloaderMode.h
new file mode 100644
index 0000000000..6dad7d6699
--- /dev/null
+++ b/iphone/Maps/UI/Downloader/MWMMapDownloaderMode.h
@@ -0,0 +1,4 @@
+typedef NS_ENUM(NSUInteger, MWMMapDownloaderMode) {
+ MWMMapDownloaderModeDownloaded,
+ MWMMapDownloaderModeAvailable
+};
diff --git a/iphone/Maps/UI/Downloader/MWMMapDownloaderTypes.h b/iphone/Maps/UI/Downloader/MWMMapDownloaderTypes.h
deleted file mode 100644
index ecb40d1a9d..0000000000
--- a/iphone/Maps/UI/Downloader/MWMMapDownloaderTypes.h
+++ /dev/null
@@ -1,8 +0,0 @@
-namespace mwm
-{
-enum class DownloaderMode
-{
- Downloaded,
- Available
-};
-} // namespace mwm
diff --git a/iphone/Maps/UI/Downloader/MWMMapDownloaderViewController.mm b/iphone/Maps/UI/Downloader/MWMMapDownloaderViewController.mm
index 236eeaaf60..9c2d257c5c 100644
--- a/iphone/Maps/UI/Downloader/MWMMapDownloaderViewController.mm
+++ b/iphone/Maps/UI/Downloader/MWMMapDownloaderViewController.mm
@@ -1,14 +1,10 @@
#import "MWMMapDownloaderViewController.h"
-#import "MWMCommon.h"
#import "MWMMapDownloaderExtendedDataSourceWithAds.h"
#import "MWMMapDownloaderSearchDataSource.h"
-#import "MWMNoMapsViewController.h"
#import "SwiftBridge.h"
#include "Framework.h"
-#include "storage/downloader_search_params.hpp"
-
namespace
{
NSString * const kMapDownloaderNoResultsEmbedViewControllerSegue =
@@ -25,7 +21,7 @@ using namespace storage;
@property(nonatomic) MWMMapDownloaderDataSource * defaultDataSource;
@property(nonatomic, readonly) NSString * parentCountryId;
-@property(nonatomic, readonly) mwm::DownloaderMode mode;
+@property(nonatomic, readonly) MWMMapDownloaderMode mode;
@property(nonatomic) BOOL showAllMapsButtons;
@@ -97,7 +93,7 @@ using namespace storage;
BOOL const noResults =
self.dataSource == self.searchDataSource && self.searchDataSource.isEmpty;
- BOOL const isModeAvailable = self.mode == mwm::DownloaderMode::Available;
+ BOOL const isModeAvailable = self.mode == MWMMapDownloaderModeAvailable;
BOOL const haveActiveMaps = s.HaveDownloadedCountries() || s.IsDownloadInProgress();
if (noResults)
@@ -194,7 +190,7 @@ using namespace storage;
#pragma mark - Configuration
-- (void)setParentCountryId:(NSString *)parentId mode:(mwm::DownloaderMode)mode
+- (void)setParentCountryId:(NSString *)parentId mode:(MWMMapDownloaderMode)mode
{
self.defaultDataSource =
[[MWMMapDownloaderExtendedDataSourceWithAds alloc] initForRootCountryId:parentId
diff --git a/iphone/Maps/UI/Downloader/NoMaps/MWMNoMapsViewController.mm b/iphone/Maps/UI/Downloader/NoMaps/MWMNoMapsViewController.mm
index dc164f37b3..c07d5a8bc5 100644
--- a/iphone/Maps/UI/Downloader/NoMaps/MWMNoMapsViewController.mm
+++ b/iphone/Maps/UI/Downloader/NoMaps/MWMNoMapsViewController.mm
@@ -1,7 +1,8 @@
#import "MWMNoMapsViewController.h"
+#import "MWMMapDownloaderMode.h"
#import "MWMMapViewControlsManager.h"
-#import "UIViewController+Navigation.h"
#import "SwiftBridge.h"
+#import "UIViewController+Navigation.h"
@implementation MWMNoMapsViewController
@@ -13,7 +14,7 @@
- (IBAction)downloadMaps
{
- [[MWMMapViewControlsManager manager] actionDownloadMaps:mwm::DownloaderMode::Available];
+ [[MWMMapViewControlsManager manager] actionDownloadMaps:MWMMapDownloaderModeAvailable];
}
@end
diff --git a/iphone/Maps/UI/EditBookmark/MWMEditBookmarkController.mm b/iphone/Maps/UI/EditBookmark/MWMEditBookmarkController.mm
index 48cc43a643..64e363cc0a 100644
--- a/iphone/Maps/UI/EditBookmark/MWMEditBookmarkController.mm
+++ b/iphone/Maps/UI/EditBookmark/MWMEditBookmarkController.mm
@@ -2,7 +2,6 @@
#import "MWMBookmarkColorViewController.h"
#import "MWMBookmarkTitleCell.h"
#import "MWMButtonCell.h"
-#import "MWMCommon.h"
#import "MWMNoteCell.h"
#import "MWMPlacePageData.h"
#import "SelectSetVC.h"
@@ -35,7 +34,7 @@ enum RowInMetaInfo
@interface MWMEditBookmarkController () <MWMButtonCellDelegate, MWMNoteCelLDelegate, MWMBookmarkColorDelegate,
MWMSelectSetDelegate, MWMBookmarkTitleDelegate>
{
- BookmarkAndCategory m_cachedBac;
+ BookmarkAndCategory m_cachedBookmarkAndCategory;
}
@property (nonatomic) MWMNoteCell * cachedNote;
@@ -57,7 +56,7 @@ enum RowInMetaInfo
self.cachedTitle = data.externalTitle ?: data.title;
self.cachedCategory = data.bookmarkCategory;
self.cachedColor = data.bookmarkColor;
- m_cachedBac = data.bac;
+ m_cachedBookmarkAndCategory = data.bookmarkAndCategory;
[self configNavBar];
[self registerCells];
}
@@ -90,11 +89,12 @@ enum RowInMetaInfo
{
[self.view endEditing:YES];
auto & f = GetFramework();
- BookmarkCategory * category = f.GetBmCategory(m_cachedBac.m_categoryIndex);
+ BookmarkCategory * category = f.GetBmCategory(m_cachedBookmarkAndCategory.m_categoryIndex);
if (!category)
return;
- auto bookmark = static_cast<Bookmark *>(category->GetUserMarkForEdit(m_cachedBac.m_bookmarkIndex));
+ auto bookmark = static_cast<Bookmark *>(
+ category->GetUserMarkForEdit(m_cachedBookmarkAndCategory.m_bookmarkIndex));
if (!bookmark)
return;
@@ -227,7 +227,7 @@ enum RowInMetaInfo
case Category:
{
SelectSetVC * svc = [[SelectSetVC alloc] initWithCategory:self.cachedCategory
- bac:m_cachedBac
+ bac:m_cachedBookmarkAndCategory
delegate:self];
[self.navigationController pushViewController:svc animated:YES];
break;
@@ -276,7 +276,7 @@ enum RowInMetaInfo
- (void)didSelectCategory:(NSString *)category withBac:(BookmarkAndCategory const &)bac
{
self.cachedCategory = category;
- m_cachedBac = bac;
+ m_cachedBookmarkAndCategory = bac;
[self.tableView reloadRowsAtIndexPaths:@[[NSIndexPath indexPathForRow:Category inSection:MetaInfo]] withRowAnimation:UITableViewRowAnimationAutomatic];
}
diff --git a/iphone/Maps/UI/Editor/MWMEditorViewController.h b/iphone/Maps/UI/Editor/MWMEditorViewController.h
index d7d516f382..de1310c287 100644
--- a/iphone/Maps/UI/Editor/MWMEditorViewController.h
+++ b/iphone/Maps/UI/Editor/MWMEditorViewController.h
@@ -1,7 +1,10 @@
#import "MWMTableViewController.h"
-#include "indexer/editable_map_object.hpp"
struct FeatureID;
+namespace osm
+{
+class EditableMapObject;
+} // namespace osm
@interface MWMEditorViewController : MWMTableViewController
diff --git a/iphone/Maps/UI/Editor/MWMEditorViewController.mm b/iphone/Maps/UI/Editor/MWMEditorViewController.mm
index 4f35b15097..344afaffa0 100644
--- a/iphone/Maps/UI/Editor/MWMEditorViewController.mm
+++ b/iphone/Maps/UI/Editor/MWMEditorViewController.mm
@@ -21,16 +21,12 @@
#import "MWMPlacePageOpeningHoursCell.h"
#import "MWMStreetEditorViewController.h"
#import "MapViewController.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
-#import "UIViewController+Navigation.h"
#include "Framework.h"
#include "indexer/osm_editor.hpp"
-#include "std/algorithm.hpp"
-
namespace
{
NSString * const kAdditionalNamesEditorSegue = @"Editor2AdditionalNamesEditorSegue";
@@ -146,7 +142,8 @@ vector<MWMEditorCellType> cellsForProperties(vector<osm::Props> const & props)
case Props::Stars:
case Props::Elevation:
case Props::Flats:
- case Props::BuildingLevels: break;
+ case Props::BuildingLevels:
+ case Props::Level: break;
}
}
return res;
@@ -317,8 +314,7 @@ void registerCellsForTableView(vector<MWMEditorCellType> const & cells, UITableV
- (void)showDropDown
{
- UIViewController * parent = static_cast<UIViewController *>([MapViewController controller]);
- MWMDropDown * dd = [[MWMDropDown alloc] initWithSuperview:parent.view];
+ MWMDropDown * dd = [[MWMDropDown alloc] initWithSuperview:[MapViewController controller].view];
[dd showWithMessage:L(@"editor_edits_sent_message")];
}
diff --git a/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.h b/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.h
index cc5f79dafc..9d8c181309 100644
--- a/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.h
+++ b/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.h
@@ -1,9 +1,12 @@
#import "MWMViewController.h"
-#include "indexer/editable_map_object.hpp"
-
#include "std/string.hpp"
+namespace osm
+{
+class EditableMapObject;
+} // namespace osm
+
@protocol MWMObjectsCategorySelectorDelegate <NSObject>
- (void)reloadObject:(osm::EditableMapObject const &)object;
diff --git a/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.mm b/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.mm
index b3ab59930c..9bbe77a66e 100644
--- a/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.mm
+++ b/iphone/Maps/UI/Editor/MWMObjectsCategorySelectorController.mm
@@ -13,9 +13,7 @@
#include "Framework.h"
-#include "indexer/search_string_utils.hpp"
-
-#include "platform/platform.hpp"
+#include "indexer/new_feature_categories.hpp"
using namespace osm;
diff --git a/iphone/Maps/UI/Migration/MWMMigrationViewController.mm b/iphone/Maps/UI/Migration/MWMMigrationViewController.mm
index b8418c6d70..5a4f44a55c 100644
--- a/iphone/Maps/UI/Migration/MWMMigrationViewController.mm
+++ b/iphone/Maps/UI/Migration/MWMMigrationViewController.mm
@@ -1,6 +1,4 @@
-#import "MapsAppDelegate.h"
#import "MWMAlertViewController.h"
-#import "MWMCircularProgress.h"
#import "MWMLocationManager.h"
#import "MWMMapDownloaderViewController.h"
#import "MWMMigrationView.h"
@@ -10,9 +8,6 @@
#include "Framework.h"
-#include "platform/platform.hpp"
-#include "storage/storage.hpp"
-
namespace
{
NSString * const kDownloaderSegue = @"Migration2MapDownloaderSegue";
@@ -177,7 +172,8 @@ using namespace storage;
if ([segue.identifier isEqualToString:kDownloaderSegue])
{
MWMMapDownloaderViewController * dvc = segue.destinationViewController;
- [dvc setParentCountryId:@(GetFramework().GetStorage().GetRootId().c_str()) mode:mwm::DownloaderMode::Downloaded];
+ [dvc setParentCountryId:@(GetFramework().GetStorage().GetRootId().c_str())
+ mode:MWMMapDownloaderModeDownloaded];
}
}
diff --git a/iphone/Maps/UI/PlacePage/MWMPlacePageData.h b/iphone/Maps/UI/PlacePage/MWMPlacePageData.h
index d298d718e6..b75f480eb6 100644
--- a/iphone/Maps/UI/PlacePage/MWMPlacePageData.h
+++ b/iphone/Maps/UI/PlacePage/MWMPlacePageData.h
@@ -1,10 +1,10 @@
#import "MWMPlacePageActionBar.h"
-#include "local_ads/event.hpp"
+#include "partners_api/taxi_provider.hpp"
-#include "partners_api/booking_api.hpp"
+#include "storage/index.hpp"
-#include "map/place_page_info.hpp"
+#include "map/routing_mark.hpp"
#include <vector>
@@ -12,13 +12,29 @@
@class MWMUGCReviewVM;
@class MWMCianItemModel;
+struct BookmarkAndCategory;
+struct FeatureID;
+
namespace ugc
{
struct Review;
-}
+} // ugc
+
+namespace local_ads
+{
+enum class EventType;
+} // local_ads
+
+namespace booking
+{
+struct HotelReview;
+struct HotelFacility;
+} // namespace booking
namespace place_page
{
+class Info;
+
enum class Sections
{
Preview,
@@ -126,7 +142,6 @@ using CianIsReady = void (^)(NSArray<MWMCianItemModel *> * items);
} // namespace place_page
-
@class MWMGalleryItemModel;
@class MWMViatorItemModel;
@class MWMCianItemModel;
@@ -201,7 +216,7 @@ using CianIsReady = void (^)(NSArray<MWMCianItemModel *> * items);
- (NSString *)bookmarkColor;
- (NSString *)bookmarkDescription;
- (NSString *)bookmarkCategory;
-- (BookmarkAndCategory)bac;
+- (BookmarkAndCategory)bookmarkAndCategory;
// Local Ads
- (NSString *)localAdsURL;
diff --git a/iphone/Maps/UI/PlacePage/MWMPlacePageData.mm b/iphone/Maps/UI/PlacePage/MWMPlacePageData.mm
index aff5cc87f1..aa507b8210 100644
--- a/iphone/Maps/UI/PlacePage/MWMPlacePageData.mm
+++ b/iphone/Maps/UI/PlacePage/MWMPlacePageData.mm
@@ -1,22 +1,18 @@
#import "MWMPlacePageData.h"
-#import "AppInfo.h"
#import "MWMBannerHelpers.h"
-#import "MWMLocationManager.h"
#import "MWMNetworkPolicy.h"
-#import "MWMSettings.h"
#import "MWMUGCReviewVM.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
-#import <FBAudienceNetwork/FBAudienceNetwork.h>
-
#include "Framework.h"
-#include "partners_api/banner.hpp"
+#include "local_ads/event.hpp"
+
+#include "partners_api/booking_api.hpp"
-#include "ugc/api.hpp"
+#include "ugc/types.hpp"
-#include "base/string_utils.hpp"
+#include "map/place_page_info.hpp"
#include "3party/opening_hours/opening_hours.hpp"
@@ -185,6 +181,7 @@ using namespace place_page;
case Props::Stars:
case Props::Flats:
case Props::BuildingLevels:
+ case Props::Level:
case Props::Fax: break;
}
}
@@ -698,7 +695,7 @@ using namespace place_page;
return m_info.IsBookmark() ? @(m_info.GetBookmarkCategoryName().c_str()) : nil;
}
-- (BookmarkAndCategory)bac;
+- (BookmarkAndCategory)bookmarkAndCategory
{
return m_info.IsBookmark() ? m_info.GetBookmarkAndCategory() : BookmarkAndCategory();
}
diff --git a/iphone/Maps/UI/PlacePage/MWMPlacePageManager.mm b/iphone/Maps/UI/PlacePage/MWMPlacePageManager.mm
index fcc1c8f99a..9a64ba580b 100644
--- a/iphone/Maps/UI/PlacePage/MWMPlacePageManager.mm
+++ b/iphone/Maps/UI/PlacePage/MWMPlacePageManager.mm
@@ -1,11 +1,8 @@
#import "MWMPlacePageManager.h"
-#import <Pushwoosh/PushNotificationManager.h>
#import "CLLocation+Mercator.h"
#import "MapViewController.h"
#import "MWMAPIBar.h"
#import "MWMActivityViewController.h"
-#import "MWMCircularProgress.h"
-#import "MWMEditBookmarkController.h"
#import "MWMFrameworkListener.h"
#import "MWMFrameworkObservers.h"
#import "MWMLocationHelpers.h"
@@ -15,21 +12,16 @@
#import "MWMPlacePageLayout.h"
#import "MWMRoutePoint+CPP.h"
#import "MWMRouter.h"
-#import "MWMSideButtons.h"
#import "MWMStorage.h"
#import "MWMUGCReviewController.h"
#import "MWMUGCReviewVM.h"
-#import "MWMViewController.h"
#import "Statistics.h"
-#import "SwiftBridge.h"
-#include "geometry/distance_on_sphere.hpp"
-#include "geometry/point2d.hpp"
+#include "Framework.h"
-#include "platform/measurement_utils.hpp"
-#include "platform/platform.hpp"
+#include "map/bookmark.hpp"
-#include "ugc/api.hpp"
+#include "geometry/distance_on_sphere.hpp"
extern NSString * const kBookmarkDeletedNotification;
extern NSString * const kBookmarkCategoryDeletedNotification;
@@ -128,11 +120,13 @@ void logSponsoredEvent(MWMPlacePageData * data, NSString * eventName)
return;
auto value = static_cast<NSValue *>(notification.object);
- auto deletedBac = BookmarkAndCategory();
- [value getValue:&deletedBac];
- NSAssert(deletedBac.IsValid(), @"Place page must have valid bookmark and category.");
- auto bac = data.bac;
- if (bac.m_bookmarkIndex != deletedBac.m_bookmarkIndex || bac.m_categoryIndex != deletedBac.m_categoryIndex)
+ auto deletedBookmarkAndCategory = BookmarkAndCategory();
+ [value getValue:&deletedBookmarkAndCategory];
+ NSAssert(deletedBookmarkAndCategory.IsValid(),
+ @"Place page must have valid bookmark and category.");
+ auto bookmarkAndCategory = data.bookmarkAndCategory;
+ if (bookmarkAndCategory.m_bookmarkIndex != deletedBookmarkAndCategory.m_bookmarkIndex ||
+ bookmarkAndCategory.m_categoryIndex != deletedBookmarkAndCategory.m_categoryIndex)
return;
[self shouldClose];
@@ -146,7 +140,7 @@ void logSponsoredEvent(MWMPlacePageData * data, NSString * eventName)
return;
auto deletedIndex = static_cast<NSNumber *>(notification.object).integerValue;
- auto index = data.bac.m_categoryIndex;
+ auto index = data.bookmarkAndCategory.m_categoryIndex;
if (index != deletedIndex)
return;
diff --git a/iphone/Maps/UI/PlacePage/MWMPlacePageProtocol.h b/iphone/Maps/UI/PlacePage/MWMPlacePageProtocol.h
index 3bab234dea..461bce5113 100644
--- a/iphone/Maps/UI/PlacePage/MWMPlacePageProtocol.h
+++ b/iphone/Maps/UI/PlacePage/MWMPlacePageProtocol.h
@@ -1,8 +1,6 @@
#import "MWMMapViewControlsManager.h"
#import "MWMPlacePageButtonsProtocol.h"
-#include "Framework.h"
-
@class MWMViewController;
@protocol MWMActionBarProtocol<NSObject>
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.h b/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.h
index ccef526d84..23861bcdd1 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.h
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.h
@@ -1,6 +1,6 @@
-@class MWMPlacePageData;
+#import "MWMCircularProgressState.h"
-#import "MWMCircularProgress.h"
+@class MWMPlacePageData;
@protocol MWMActionBarSharedData<NSObject>
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.mm
index d0770476c1..d5af4ba1e8 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/ActionBar/MWMPlacePageActionBar.mm
@@ -1,15 +1,11 @@
#import "MWMPlacePageActionBar.h"
#import "AppInfo.h"
#import "MWMActionBarButton.h"
-#import "MWMCommon.h"
+#import "MWMCircularProgress.h"
+#import "MWMNavigationDashboardManager.h"
#import "MWMPlacePageProtocol.h"
#import "MWMRouter.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
-
-#include "Framework.h"
-
-#include "std/vector.hpp"
extern NSString * const kAlohalyticsTapEventKey;
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/BookmarkCell/MWMBookmarkCell.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/BookmarkCell/MWMBookmarkCell.mm
index cb4ff80d54..8909d56436 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/BookmarkCell/MWMBookmarkCell.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/BookmarkCell/MWMBookmarkCell.mm
@@ -1,6 +1,5 @@
#import "MWMBookmarkCell.h"
#import "MWMPlacePageCellUpdateProtocol.h"
-
#import "MWMPlacePageProtocol.h"
namespace
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.h b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.h
index f3361327b1..a035b48bf6 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.h
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.h
@@ -1,9 +1,13 @@
-#import "MWMPlacePageData.h"
#import "MWMTableViewCell.h"
#import "MWMTypes.h"
@protocol MWMPlacePageButtonsProtocol;
+namespace place_page
+{
+enum class ButtonsRows;
+} // namespace place_page
+
@interface MWMPlacePageButtonCell : MWMTableViewCell
- (void)configWithTitle:(NSString *)title
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.mm
index 457f234cf8..dc2049fc45 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/ButtonCell/MWMPlacePageButtonCell.mm
@@ -1,6 +1,5 @@
#import "MWMPlacePageButtonCell.h"
-#import "MWMCommon.h"
-#import "MWMPlacePageProtocol.h"
+#import "MWMPlacePageData.h"
#import "SwiftBridge.h"
@interface MWMPlacePageButtonCell ()
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/RegularCell/MWMPlacePageRegularCell.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/RegularCell/MWMPlacePageRegularCell.mm
index 7120406494..82acf283e1 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/RegularCell/MWMPlacePageRegularCell.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/RegularCell/MWMPlacePageRegularCell.mm
@@ -6,6 +6,8 @@
#import "Statistics.h"
#import "UIImageView+Coloring.h"
+#include "local_ads/event.hpp"
+
#include "platform/measurement_utils.hpp"
#include "platform/settings.hpp"
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/UGC/MWMUGCReviewVM.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/UGC/MWMUGCReviewVM.mm
index 4fd57b1ad9..50cbdbe34a 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/UGC/MWMUGCReviewVM.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/UGC/MWMUGCReviewVM.mm
@@ -1,10 +1,9 @@
-#import "Framework.h"
#import "MWMUGCReviewVM.h"
#import "SwiftBridge.h"
-#include "ugc/api.hpp"
+#include "Framework.h"
-#include <vector>
+#include "ugc/types.hpp"
@interface MWMUGCReviewVM () <MWMUGCSpecificReviewDelegate, MWMUGCTextReviewDelegate>
{
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.h b/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.h
index c922aaf5d3..7229253889 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.h
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.h
@@ -1,4 +1,7 @@
-#include "storage/storage_defines.hpp"
+namespace storage
+{
+enum class NodeStatus;
+} // namespace storage
@protocol MWMPlacePageLayoutDelegate<NSObject>
diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.mm b/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.mm
index a518560556..d5f1e3c29e 100644
--- a/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.mm
+++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/MWMPlacePageLayout.mm
@@ -1,14 +1,12 @@
#import "MWMPlacePageLayout.h"
-#import <MyTrackerSDK/MRMyTracker.h>
#import "MWMBookmarkCell.h"
-#import "MWMCircularProgress.h"
#import "MWMOpeningHoursLayoutHelper.h"
#import "MWMPPPreviewLayoutHelper.h"
#import "MWMPPReviewCell.h"
+#import "MWMPPView.h"
#import "MWMPlacePageButtonCell.h"
#import "MWMPlacePageCellUpdateProtocol.h"
#import "MWMPlacePageData.h"
-#import "MWMPlacePageLayoutImpl.h"
#import "MWMPlacePageRegularCell.h"
#import "MWMUGCCommentCell.h"
#import "MWMiPadPlacePageLayoutImpl.h"
@@ -18,10 +16,9 @@
#include "ugc/types.hpp"
-#include "storage/storage.hpp"
+#include "partners_api/booking_api.hpp"
-#include "std/array.hpp"
-#include "std/map.hpp"
+#include "storage/storage_defines.hpp"
namespace
{
diff --git a/iphone/Maps/UI/Search/Console/MWMConsole.h b/iphone/Maps/UI/Search/Console/MWMConsole.h
deleted file mode 100644
index 9d2e883470..0000000000
--- a/iphone/Maps/UI/Search/Console/MWMConsole.h
+++ /dev/null
@@ -1,5 +0,0 @@
-@interface MWMConsole : NSObject
-
-+ (BOOL)performCommand:(NSString *)cmd;
-
-@end
diff --git a/iphone/Maps/UI/Search/Console/MWMConsole.mm b/iphone/Maps/UI/Search/Console/MWMConsole.mm
deleted file mode 100644
index cd6bf3304a..0000000000
--- a/iphone/Maps/UI/Search/Console/MWMConsole.mm
+++ /dev/null
@@ -1,13 +0,0 @@
-#import "MapsAppDelegate.h"
-#import "MWMConsole.h"
-
-#include "Framework.h"
-
-@implementation MWMConsole
-
-+ (BOOL)performCommand:(NSString *)cmd
-{
- return NO;
-}
-
-@end
diff --git a/iphone/Maps/UI/Search/Filters/MWMSearchFilterViewController.h b/iphone/Maps/UI/Search/Filters/MWMSearchFilterViewController.h
index b6a9d8e75b..7218a66dd1 100644
--- a/iphone/Maps/UI/Search/Filters/MWMSearchFilterViewController.h
+++ b/iphone/Maps/UI/Search/Filters/MWMSearchFilterViewController.h
@@ -1,6 +1,14 @@
#import "MWMTableViewController.h"
-#include "search/hotels_filter.hpp"
+#include "std/shared_ptr.hpp"
+
+namespace search
+{
+namespace hotels_filter
+{
+struct Rule;
+} // namespace hotels_filter
+} // namespace search
@interface MWMSearchFilterViewController : MWMTableViewController
diff --git a/iphone/Maps/UI/Search/Filters/MWMSearchHotelsFilterViewController.mm b/iphone/Maps/UI/Search/Filters/MWMSearchHotelsFilterViewController.mm
index 474d5c381b..b44bac3e1e 100644
--- a/iphone/Maps/UI/Search/Filters/MWMSearchHotelsFilterViewController.mm
+++ b/iphone/Maps/UI/Search/Filters/MWMSearchHotelsFilterViewController.mm
@@ -2,10 +2,7 @@
#import "MWMSearchFilterViewController_Protected.h"
#import "SwiftBridge.h"
-#include "base/stl_helpers.hpp"
-
-#include <array>
-#include <vector>
+#include "search/hotels_filter.hpp"
namespace
{
diff --git a/iphone/Maps/UI/Search/MWMSearchManager.h b/iphone/Maps/UI/Search/MWMSearchManager.h
index a902b81c42..5a71a839fa 100644
--- a/iphone/Maps/UI/Search/MWMSearchManager.h
+++ b/iphone/Maps/UI/Search/MWMSearchManager.h
@@ -1,5 +1,4 @@
#import "MWMAlertViewController.h"
-#import "MWMMapDownloaderTypes.h"
#import "MWMSearchManagerObserver.h"
#import "MWMSearchManagerState.h"
#import "MWMSearchTextField.h"
diff --git a/iphone/Maps/UI/Search/MWMSearchManager.mm b/iphone/Maps/UI/Search/MWMSearchManager.mm
index 56edd8ec78..46f9466096 100644
--- a/iphone/Maps/UI/Search/MWMSearchManager.mm
+++ b/iphone/Maps/UI/Search/MWMSearchManager.mm
@@ -1,14 +1,10 @@
#import "MWMSearchManager.h"
-#import "CLLocation+Mercator.h"
#import "MWMCommon.h"
-#import "MWMConsole.h"
#import "MWMFrameworkListener.h"
-#import "MWMLocationManager.h"
#import "MWMMapViewControlsManager.h"
#import "MWMNoMapsViewController.h"
#import "MWMRoutePoint+CPP.h"
#import "MWMRouter.h"
-#import "MWMSearch.h"
#import "MWMSearchChangeModeView.h"
#import "MWMSearchFilterTransitioningManager.h"
#import "MWMSearchManager+Filter.h"
@@ -17,15 +13,9 @@
#import "MWMSearchTabbedViewController.h"
#import "MWMSearchTableViewController.h"
#import "MapViewController.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
-#include "storage/storage_helpers.hpp"
-
-#include "Framework.h"
-
extern NSString * const kAlohalyticsTapEventKey;
extern NSString * const kSearchStateKey = @"SearchStateKey";
@@ -141,15 +131,8 @@ using Observers = NSHashTable<Observer>;
if (text.length > 0)
{
[self clearFilter];
- if ([MWMConsole performCommand:text])
- {
- self.state = MWMSearchManagerStateHidden;
- }
- else
- {
- [self beginSearch];
- [MWMSearch searchQuery:text forInputLocale:textField.textInputMode.primaryLanguage];
- }
+ [self beginSearch];
+ [MWMSearch searchQuery:text forInputLocale:textField.textInputMode.primaryLanguage];
}
else
{
diff --git a/iphone/Maps/UI/Search/TabbedView/CategoriesTab/MWMSearchCategoriesManager.mm b/iphone/Maps/UI/Search/TabbedView/CategoriesTab/MWMSearchCategoriesManager.mm
index 2e0031697b..03c7697c2d 100644
--- a/iphone/Maps/UI/Search/TabbedView/CategoriesTab/MWMSearchCategoriesManager.mm
+++ b/iphone/Maps/UI/Search/TabbedView/CategoriesTab/MWMSearchCategoriesManager.mm
@@ -1,14 +1,11 @@
#import "MWMSearchCategoriesManager.h"
#import <MyTrackerSDK/MRMyTracker.h>
-#import "AppInfo.h"
#import "MWMSearchCategoryCell.h"
#import "Statistics.h"
#import "SwiftBridge.h"
#include "Framework.h"
-#include "base/macros.hpp"
-
extern NSString * const kCianCategory = @"cian";
@implementation MWMSearchCategoriesManager
diff --git a/iphone/Maps/UI/Search/TabbedView/HistoryTab/MWMSearchHistoryManager.mm b/iphone/Maps/UI/Search/TabbedView/HistoryTab/MWMSearchHistoryManager.mm
index 2fddb2ca53..0e0103efec 100644
--- a/iphone/Maps/UI/Search/TabbedView/HistoryTab/MWMSearchHistoryManager.mm
+++ b/iphone/Maps/UI/Search/TabbedView/HistoryTab/MWMSearchHistoryManager.mm
@@ -1,10 +1,6 @@
#import "MWMSearchHistoryManager.h"
-#import "MWMCommon.h"
-#import "MWMLocationManager.h"
#import "MWMSearchHistoryClearCell.h"
#import "MWMSearchHistoryRequestCell.h"
-#import "MWMSearchNoResults.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
#import "SwiftBridge.h"
diff --git a/iphone/Maps/UI/Search/TabbedView/MWMSearchTabbedViewController.mm b/iphone/Maps/UI/Search/TabbedView/MWMSearchTabbedViewController.mm
index 3516c6c735..9250897943 100644
--- a/iphone/Maps/UI/Search/TabbedView/MWMSearchTabbedViewController.mm
+++ b/iphone/Maps/UI/Search/TabbedView/MWMSearchTabbedViewController.mm
@@ -2,10 +2,7 @@
#import "MWMCommon.h"
#import "MWMSearchCategoriesManager.h"
#import "MWMSearchHistoryManager.h"
-#import "MWMSearchTabbedCollectionViewCell.h"
#import "MWMSearchTabbedViewLayout.h"
-#import "MWMSearchTabbedViewProtocol.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#include "Framework.h"
@@ -117,7 +114,7 @@ BOOL isOffsetInButton(CGFloat offset, MWMSearchTabButtonsView * button)
- (void)tabButtonPressed:(MWMSearchTabButtonsView *)sender
{
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
[self.tablesCollectionView
scrollToItemAtIndexPath:[NSIndexPath indexPathForItem:sender.tag inSection:0]
atScrollPosition:UICollectionViewScrollPositionCenteredHorizontally
@@ -131,7 +128,7 @@ BOOL isOffsetInButton(CGFloat offset, MWMSearchTabButtonsView * button)
CGFloat const btnMid = position + 0.5 * scrollIndicatorWidth;
if (isInterfaceRightToLeft())
position = scrollIndicatorWidth - position;
- runAsyncOnMainQueue(^{
+ dispatch_async(dispatch_get_main_queue(), ^{
self.scrollIndicatorOffset.constant = nearbyint(position);
});
MWMSearchTabButtonsView * selectedButton = self.selectedButton;
diff --git a/iphone/Maps/UI/Search/TableView/MWMSearchCommonCell.mm b/iphone/Maps/UI/Search/TableView/MWMSearchCommonCell.mm
index ef0fc9adaf..06aebb06e0 100644
--- a/iphone/Maps/UI/Search/TableView/MWMSearchCommonCell.mm
+++ b/iphone/Maps/UI/Search/TableView/MWMSearchCommonCell.mm
@@ -1,10 +1,6 @@
#import "MWMSearchCommonCell.h"
#import "CLLocation+Mercator.h"
-#import "MWMCommon.h"
#import "MWMLocationManager.h"
-#import "MapsAppDelegate.h"
-
-#include "Framework.h"
#include "geometry/mercator.hpp"
#include "platform/measurement_utils.hpp"
diff --git a/iphone/Maps/UI/Search/TableView/MWMSearchTableViewController.mm b/iphone/Maps/UI/Search/TableView/MWMSearchTableViewController.mm
index 827d128648..165b97c084 100644
--- a/iphone/Maps/UI/Search/TableView/MWMSearchTableViewController.mm
+++ b/iphone/Maps/UI/Search/TableView/MWMSearchTableViewController.mm
@@ -1,10 +1,7 @@
#import "MWMSearchTableViewController.h"
-#import "MWMLocationManager.h"
-#import "MWMSearchChangeModeView.h"
#import "MWMSearchCommonCell.h"
#import "MWMSearchSuggestionCell.h"
#import "MWMSearchTableView.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
#import "SwiftBridge.h"
diff --git a/iphone/Maps/UI/Settings/MWMAboutController.mm b/iphone/Maps/UI/Settings/MWMAboutController.mm
index 1621a89198..ee605aca00 100644
--- a/iphone/Maps/UI/Settings/MWMAboutController.mm
+++ b/iphone/Maps/UI/Settings/MWMAboutController.mm
@@ -4,13 +4,10 @@
#import "Statistics.h"
#import "SwiftBridge.h"
#import "WebViewController.h"
-
#import "3party/Alohalytics/src/alohalytics_objc.h"
#include "Framework.h"
-#include "platform/platform.hpp"
-
extern NSString * const kAlohalyticsTapEventKey;
@interface MWMAboutController ()<MFMailComposeViewControllerDelegate>
diff --git a/iphone/Maps/UI/Settings/MWMNightModeController.mm b/iphone/Maps/UI/Settings/MWMNightModeController.mm
index e9d31bd50d..c342587c31 100644
--- a/iphone/Maps/UI/Settings/MWMNightModeController.mm
+++ b/iphone/Maps/UI/Settings/MWMNightModeController.mm
@@ -1,11 +1,8 @@
#import "MWMNightModeController.h"
#import "MWMSettings.h"
-#import "MapsAppDelegate.h"
#import "Statistics.h"
#import "SwiftBridge.h"
-#include "Framework.h"
-
@interface MWMNightModeController ()
@property(weak, nonatomic) IBOutlet SettingsTableViewSelectableCell * autoSwitch;
diff --git a/iphone/Maps/UI/Settings/MWMRecentTrackSettingsController.mm b/iphone/Maps/UI/Settings/MWMRecentTrackSettingsController.mm
index 292b1538c5..2071f0c780 100644
--- a/iphone/Maps/UI/Settings/MWMRecentTrackSettingsController.mm
+++ b/iphone/Maps/UI/Settings/MWMRecentTrackSettingsController.mm
@@ -1,5 +1,4 @@
#import "MWMRecentTrackSettingsController.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
#include "Framework.h"
diff --git a/iphone/Maps/UI/Settings/MWMSettingsViewController.mm b/iphone/Maps/UI/Settings/MWMSettingsViewController.mm
index 5482efb5e5..3dbe1a6aed 100644
--- a/iphone/Maps/UI/Settings/MWMSettingsViewController.mm
+++ b/iphone/Maps/UI/Settings/MWMSettingsViewController.mm
@@ -1,14 +1,10 @@
#import "MWMSettingsViewController.h"
-#import "LocaleTranslator.h"
#import "MWMAuthorizationCommon.h"
#import "MWMNetworkPolicy.h"
-#import "MWMSettings.h"
#import "MWMTextToSpeech+CPP.h"
-#import "Statistics.h"
#import "SwiftBridge.h"
-#import "WebViewController.h"
-#import "3party/Alohalytics/src/alohalytics_objc.h"
+#include "LocaleTranslator.h"
#include "Framework.h"