mirror of
https://codeberg.org/comaps/comaps
synced 2026-01-04 11:53:47 +00:00
[ios] Fixed category search for unsupported translations.
Signed-off-by: Kiryl Kaveryn <kirylkaveryn@gmail.com>
This commit is contained in:
committed by
Konstantin Pastbin
parent
d649e46ef2
commit
aa71668eab
@@ -7,6 +7,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
+ (NSArray<NSString *> *)searchCategories;
|
||||
|
||||
+ (BOOL)isSearchHistoryEmpty;
|
||||
+ (BOOL)isLanguageSupported:(NSString *)languageCode;
|
||||
+ (NSArray<NSString *> *)lastSearchQueries;
|
||||
+ (void)clearSearchHistory;
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#import "MWMSearchFrameworkHelper.h"
|
||||
|
||||
#include "platform/preferred_languages.hpp"
|
||||
#include "search/displayed_categories.hpp"
|
||||
|
||||
#include "Framework.h"
|
||||
|
||||
@@ -20,6 +21,11 @@
|
||||
return GetFramework().GetSearchAPI().GetLastSearchQueries().empty();
|
||||
}
|
||||
|
||||
+ (BOOL)isLanguageSupported:(NSString *)languageCode
|
||||
{
|
||||
return search::DisplayedCategories::IsLanguageSupported(languageCode.UTF8String);
|
||||
}
|
||||
|
||||
+ (NSArray<NSString *> *)lastSearchQueries
|
||||
{
|
||||
NSMutableArray * result = [NSMutableArray array];
|
||||
|
||||
Reference in New Issue
Block a user