forked from organicmaps/organicmaps
[ios] Added logging.
This commit is contained in:
parent
aa5b655990
commit
2e1e8e1de2
3 changed files with 23 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
|||
#import "MWMMapViewStyleController.h"
|
||||
#import "SelectableCell.h"
|
||||
#import "Statistics.h"
|
||||
|
||||
#include "Framework.h"
|
||||
|
||||
|
@ -50,11 +51,24 @@
|
|||
_selectedCell = selectedCell;
|
||||
auto & f = GetFramework();
|
||||
bool is3d = false, is3dWithBuildings = false;
|
||||
|
||||
NSString * value = nil;
|
||||
if ([selectedCell isEqual:self.threeDimension])
|
||||
{
|
||||
value = kStat3DWithBuildings;
|
||||
is3d = true;
|
||||
}
|
||||
else if ([selectedCell isEqual:self.threeDimensionWithBuildings])
|
||||
{
|
||||
value = kStat3D;
|
||||
is3d = is3dWithBuildings = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
value = kStat2D;
|
||||
}
|
||||
|
||||
[[Statistics instance] logEvent:kStatEventName(kStatMapViewStyleSettings, kStatMapViewStyle)
|
||||
withParameters:@{kStatValue : value}];
|
||||
|
||||
f.Save3dMode(is3d, is3dWithBuildings);
|
||||
f.Allow3dMode(is3d, is3dWithBuildings);
|
||||
|
|
|
@ -259,6 +259,8 @@ Settings::Units unitsForIndex(NSInteger index)
|
|||
case SectionRouting:
|
||||
if (indexPath.row == 0)
|
||||
{
|
||||
[[Statistics instance] logEvent:kStatEventName(kStatSettings, kStatMapViewStyle)
|
||||
withParameters:@{kStatAction : kStatChangeMapViewStyle}];
|
||||
[self performSegueWithIdentifier:@"SettingsToMapViewSegue" sender:nil];
|
||||
}
|
||||
else if (indexPath.row == 2)
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
static NSString * const kStat2D = @"2D";
|
||||
static NSString * const kStat3D = @"3D";
|
||||
static NSString * const kStat3DWithBuildings= @"3D with buildings";
|
||||
static NSString * const kStatAPI = @"API";
|
||||
static NSString * const kStatAbout = @"About";
|
||||
static NSString * const kStatAction = @"Action";
|
||||
|
@ -20,6 +23,7 @@ static NSString * const kStatCategories = @"Categories";
|
|||
static NSString * const kStatChangeBookmarkColor = @"Change bookmark color";
|
||||
static NSString * const kStatChangeBookmarkDescription = @"Change bookmark description";
|
||||
static NSString * const kStatChangeBookmarkGroup = @"Change bookmark group";
|
||||
static NSString * const kStatChangeMapViewStyle = @"Change map view style";
|
||||
static NSString * const kStatChangeLanguage = @"Change language";
|
||||
static NSString * const kStatChangeMeasureUnits = @"Change measure units";
|
||||
static NSString * const kStatChangeRoutingMode = @"Change routing mode";
|
||||
|
@ -56,6 +60,8 @@ static NSString * const kStatLandscape = @"Landscape";
|
|||
static NSString * const kStatLanguage = @"Language";
|
||||
static NSString * const kStatLocation = @"Location";
|
||||
static NSString * const kStatMap = @"Map search";
|
||||
static NSString * const kStatMapViewStyle = @"Map view style";
|
||||
static NSString * const kStatMapViewStyleSettings = @"Map view style settings";
|
||||
static NSString * const kStatMenu = @"Menu";
|
||||
static NSString * const kStatMiles = @"Miles";
|
||||
static NSString * const kStatMoreApps = @"More apps";
|
||||
|
|
Loading…
Add table
Reference in a new issue