[ios] Removed "?sound" hook.

This commit is contained in:
v.mikhaylenko 2015-11-12 15:13:55 +03:00
parent c5ff1461cc
commit 9c5202e67f

View file

@ -3,9 +3,6 @@
#include "Framework.h"
extern NSString * const kMwmTextToSpeechEnable;
extern NSString * const kMwmTextToSpeechDisable;
@implementation MWMConsole
+ (BOOL)performCommand:(NSString *)cmd
@ -13,9 +10,6 @@ extern NSString * const kMwmTextToSpeechDisable;
if ([self performMapStyle:cmd])
return YES;
if ([self performSound:cmd])
return YES;
return NO;
}
@ -35,21 +29,4 @@ extern NSString * const kMwmTextToSpeechDisable;
return YES;
}
+ (BOOL)performSound:(NSString *)cmd
{
// Hook for shell command on change map style
BOOL const sound = [cmd isEqualToString:@"?sound"];
BOOL const nosound = sound ? NO : [cmd isEqualToString:@"?nosound"];
if (!sound && !nosound)
return NO;
if (sound)
[[NSNotificationCenter defaultCenter] postNotificationName:kMwmTextToSpeechEnable object:nil];
if (nosound)
[[NSNotificationCenter defaultCenter] postNotificationName:kMwmTextToSpeechDisable object:nil];
return YES;
}
@end