forked from organicmaps/organicmaps
[iOS] fix iOS build after rebase
This commit is contained in:
parent
4c15e49177
commit
3f3dc1de52
7 changed files with 32 additions and 31 deletions
|
@ -72,7 +72,7 @@ using namespace storage;
|
|||
}
|
||||
} else {
|
||||
f.GetStorage().DeleteNode(countryId.UTF8String);
|
||||
f.GetNotificationManager().DeleteCandidatesForCountry(countryId);
|
||||
f.GetNotificationManager().DeleteCandidatesForCountry(countryId.UTF8String);
|
||||
return YES;
|
||||
}
|
||||
|
||||
|
|
|
@ -4,11 +4,12 @@
|
|||
#import "MWMDiscoveryControllerViewModel.h"
|
||||
#import "MWMDiscoveryHotelViewModel.h"
|
||||
#import "MWMDiscoverySearchViewModel.h"
|
||||
#import "CatalogPromoItem+Core.h"
|
||||
#import "MWMNetworkPolicy+UI.h"
|
||||
#import "Statistics.h"
|
||||
#import "SwiftBridge.h"
|
||||
|
||||
#import <CoreApi/CatalogPromoItem+Core.h>
|
||||
|
||||
#include "map/place_page_info.hpp"
|
||||
|
||||
#include "search/result.hpp"
|
||||
|
@ -375,8 +376,8 @@ using namespace discovery;
|
|||
[cell configWithAvatarURL:objectVM.imageUrl
|
||||
title:objectVM.guideName
|
||||
subtitle:objectVM.guideAuthor
|
||||
label:objectVM.label
|
||||
labelHexColor:objectVM.labelHexColor
|
||||
label:objectVM.categoryLabel
|
||||
labelHexColor:objectVM.hexColor
|
||||
onDetails:^{
|
||||
[weakSelf.delegate openURLForItem:ItemType::Promo atIndex:indexPath.row];
|
||||
}];
|
||||
|
|
|
@ -3,7 +3,8 @@
|
|||
#import "MWMDiscoveryMapObjects.h"
|
||||
#import "MWMDiscoveryHotelViewModel.h"
|
||||
#import "MWMDiscoverySearchViewModel.h"
|
||||
#import "CatalogPromoItem+Core.h"
|
||||
|
||||
#import <CoreApi/CatalogPromoItem+Core.h>
|
||||
|
||||
#include "map/place_page_info.hpp"
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
#import "MWMPlacePageData.h"
|
||||
#import "MWMDiscoveryCityGalleryObjects.h"
|
||||
#import "CatalogPromoItem+Core.h"
|
||||
#import "MWMBannerHelpers.h"
|
||||
#import "MWMUGCViewModel.h"
|
||||
#import "SwiftBridge.h"
|
||||
|
@ -12,6 +11,7 @@
|
|||
#include "3party/opening_hours/opening_hours.hpp"
|
||||
|
||||
#import <CoreApi/PlacePageData.h>
|
||||
#import <CoreApi/CatalogPromoItem+Core.h>
|
||||
|
||||
using namespace place_page;
|
||||
|
||||
|
@ -823,23 +823,23 @@ NSString * const kUserDefaultsLatLonAsDMSKey = @"UserDefaultsLatLonAsDMS";
|
|||
|
||||
#pragma mark - Helpers
|
||||
|
||||
- (NSString *)phoneNumber { return @(m_info.GetPhone().c_str()); }
|
||||
- (BOOL)isBookmark { return m_info.IsBookmark(); }
|
||||
- (BOOL)isApi { return m_info.HasApiUrl(); }
|
||||
- (BOOL)isBooking { return m_info.GetSponsoredType() == SponsoredType::Booking; }
|
||||
- (BOOL)isOpentable { return m_info.GetSponsoredType() == SponsoredType::Opentable; }
|
||||
- (BOOL)isPartner { return m_info.GetSponsoredType() == SponsoredType::Partner; }
|
||||
- (BOOL)isHolidayObject { return m_info.GetSponsoredType() == SponsoredType::Holiday; }
|
||||
- (NSString *)phoneNumber { return @([self getRawData].GetPhone().c_str()); }
|
||||
- (BOOL)isBookmark { return [self getRawData].IsBookmark(); }
|
||||
- (BOOL)isApi { return [self getRawData].HasApiUrl(); }
|
||||
- (BOOL)isBooking { return [self getRawData].GetSponsoredType() == SponsoredType::Booking; }
|
||||
- (BOOL)isOpentable { return [self getRawData].GetSponsoredType() == SponsoredType::Opentable; }
|
||||
- (BOOL)isPartner { return [self getRawData].GetSponsoredType() == SponsoredType::Partner; }
|
||||
- (BOOL)isHolidayObject { return [self getRawData].GetSponsoredType() == SponsoredType::Holiday; }
|
||||
- (BOOL)isPromoCatalog { return self.isLargeToponym || self.isSightseeing || self.isOutdoor; }
|
||||
- (BOOL)isLargeToponym { return m_info.GetSponsoredType() == SponsoredType::PromoCatalogCity; }
|
||||
- (BOOL)isSightseeing { return m_info.GetSponsoredType() == SponsoredType::PromoCatalogSightseeings; }
|
||||
- (BOOL)isOutdoor { return m_info.GetSponsoredType() == SponsoredType::PromoCatalogOutdoor; }
|
||||
- (BOOL)isBookingSearch { return !m_info.GetBookingSearchUrl().empty(); }
|
||||
- (BOOL)isMyPosition { return m_info.IsMyPosition(); }
|
||||
- (BOOL)isHTMLDescription { return strings::IsHTML(GetPreferredBookmarkStr(m_info.GetBookmarkData().m_description)); }
|
||||
- (BOOL)isRoutePoint { return m_info.IsRoutePoint(); }
|
||||
- (RoadWarningMarkType)roadType { return m_info.GetRoadType(); }
|
||||
- (BOOL)isPreviewPlus { return m_info.GetOpeningMode() == place_page::OpeningMode::PreviewPlus; }
|
||||
- (BOOL)isLargeToponym { return [self getRawData].GetSponsoredType() == SponsoredType::PromoCatalogCity; }
|
||||
- (BOOL)isSightseeing { return [self getRawData].GetSponsoredType() == SponsoredType::PromoCatalogSightseeings; }
|
||||
- (BOOL)isOutdoor { return [self getRawData].GetSponsoredType() == SponsoredType::PromoCatalogOutdoor; }
|
||||
- (BOOL)isBookingSearch { return ![self getRawData].GetBookingSearchUrl().empty(); }
|
||||
- (BOOL)isMyPosition { return [self getRawData].IsMyPosition(); }
|
||||
- (BOOL)isHTMLDescription { return strings::IsHTML(GetPreferredBookmarkStr([self getRawData].GetBookmarkData().m_description)); }
|
||||
- (BOOL)isRoutePoint { return [self getRawData].IsRoutePoint(); }
|
||||
- (RoadWarningMarkType)roadType { return [self getRawData].GetRoadType(); }
|
||||
- (BOOL)isPreviewPlus { return [self getRawData].GetOpeningMode() == place_page::OpeningMode::PreviewPlus; }
|
||||
- (BOOL)isPartnerAppInstalled
|
||||
{
|
||||
// TODO(): Load list of registered schemas from plist.
|
||||
|
@ -848,7 +848,7 @@ NSString * const kUserDefaultsLatLonAsDMSKey = @"UserDefaultsLatLonAsDMS";
|
|||
|
||||
- (nonnull NSString*)statPlacement
|
||||
{
|
||||
switch (m_info.GetSponsoredType())
|
||||
switch ([self getRawData].GetSponsoredType())
|
||||
{
|
||||
case SponsoredType::PromoCatalogCity:
|
||||
return kStatPlacePageToponims;
|
||||
|
@ -861,7 +861,7 @@ NSString * const kUserDefaultsLatLonAsDMSKey = @"UserDefaultsLatLonAsDMS";
|
|||
}
|
||||
}
|
||||
|
||||
+ (MWMRatingSummaryViewValueType)ratingValueType:(rating::Impress)impress
|
||||
+ (UgcSummaryRatingType)ratingValueType:(rating::Impress)impress
|
||||
{
|
||||
switch (impress)
|
||||
{
|
||||
|
@ -983,7 +983,7 @@ NSString * const kUserDefaultsLatLonAsDMSKey = @"UserDefaultsLatLonAsDMS";
|
|||
api->GetCityGallery(self.mercator, locale, UTM::LargeToponymsPlacepageGallery, resultHandler, errorHandler);
|
||||
} else {
|
||||
api->GetPoiGallery(self.mercator, locale,
|
||||
info.GetRawTypes(),
|
||||
[self getRawData].GetRawTypes(),
|
||||
[MWMFrameworkHelper isWiFiConnected],
|
||||
self.isOutdoor ? UTM::OutdoorPlacepageGallery : UTM::SightseeingsPlacepageGallery,
|
||||
resultHandler,
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
#import "MWMBookmarkCell.h"
|
||||
#import "MWMDiscoveryCityGalleryObjects.h"
|
||||
#import "MWMDiscoveryCollectionView.h"
|
||||
#import "CatalogPromoItem+Core.h"
|
||||
#import "MWMPlaceDescriptionCell.h"
|
||||
#import "MWMOpeningHoursLayoutHelper.h"
|
||||
#import "MWMPPPreviewLayoutHelper.h"
|
||||
|
@ -863,8 +862,8 @@ std::map<MetainfoRows, Class> const kMetaInfoCells = {
|
|||
[cell configWithAvatarURL:objectVM.imageUrl
|
||||
title:objectVM.guideName
|
||||
subtitle:objectVM.guideAuthor
|
||||
label:objectVM.label
|
||||
labelHexColor:objectVM.labelHexColor
|
||||
label:objectVM.categoryLabel
|
||||
labelHexColor:objectVM.hexColor
|
||||
onDetails:^{
|
||||
__strong __typeof__(weakSelf) strongSelf = weakSelf;
|
||||
if (!strongSelf) { return; }
|
||||
|
|
|
@ -14,7 +14,7 @@ class WhatsNewPresenter {
|
|||
private weak var view: IWelcomeView?
|
||||
private let router: WelcomeRouter
|
||||
private let config: WhatsNewConfig
|
||||
private let appVersion = AppInfo.shared()?.bundleVersion ?? ""
|
||||
private let appVersion = AppInfo.shared().bundleVersion ?? ""
|
||||
|
||||
init(view: IWelcomeView, router: WelcomeRouter, config: WhatsNewConfig) {
|
||||
self.view = view
|
||||
|
|
|
@ -2322,13 +2322,13 @@ void Framework::SetPlacePageListeners(PlacePageEvent::OnOpen const & onOpen,
|
|||
place_page::Info const & Framework::GetCurrentPlacePageInfo() const
|
||||
{
|
||||
CHECK(HasPlacePageInfo(), ());
|
||||
return m_currentPlacePageInfo.value();
|
||||
return *m_currentPlacePageInfo;
|
||||
}
|
||||
|
||||
place_page::Info & Framework::GetCurrentPlacePageInfo()
|
||||
{
|
||||
CHECK(HasPlacePageInfo(), ());
|
||||
return m_currentPlacePageInfo.value();
|
||||
return *m_currentPlacePageInfo;
|
||||
}
|
||||
|
||||
void Framework::ActivateMapSelection(std::optional<place_page::Info> const & info)
|
||||
|
|
Loading…
Add table
Reference in a new issue