Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(656)

Side by Side Diff: ios/chrome/common/app_group/app_group_metrics_mainapp.mm

Issue 2502663002: [ObjC ARC] Converts ios/chrome/common/app_group to ARC (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ios/chrome/common/app_group/app_group_metrics_client.mm ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ios/chrome/common/app_group/app_group_metrics_mainapp.h" 5 #include "ios/chrome/common/app_group/app_group_metrics_mainapp.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/mac/scoped_nsobject.h" 10 #include "base/mac/scoped_nsobject.h"
11 #include "ios/chrome/common/app_group/app_group_constants.h" 11 #include "ios/chrome/common/app_group/app_group_constants.h"
12 #include "ios/chrome/common/app_group/app_group_metrics.h" 12 #include "ios/chrome/common/app_group/app_group_metrics.h"
13 13
14 #if !defined(__has_feature) || !__has_feature(objc_arc)
15 #error "This file requires ARC support."
16 #endif
17
14 namespace app_group { 18 namespace app_group {
15 19
16 namespace main_app { 20 namespace main_app {
17 21
18 void ProcessPendingLogs( 22 void ProcessPendingLogs(
19 const base::mac::ScopedBlock<ProceduralBlockWithData>& callback) { 23 const base::mac::ScopedBlock<ProceduralBlockWithData>& callback) {
20 NSFileManager* file_manager = [NSFileManager defaultManager]; 24 NSFileManager* file_manager = [NSFileManager defaultManager];
21 NSURL* store_url = [file_manager 25 NSURL* store_url = [file_manager
22 containerURLForSecurityApplicationGroupIdentifier:ApplicationGroup()]; 26 containerURLForSecurityApplicationGroupIdentifier:ApplicationGroup()];
23 NSURL* log_dir_url = 27 NSURL* log_dir_url =
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 65
62 void DisableMetrics() { 66 void DisableMetrics() {
63 base::scoped_nsobject<NSUserDefaults> shared_defaults( 67 base::scoped_nsobject<NSUserDefaults> shared_defaults(
64 [[NSUserDefaults alloc] initWithSuiteName:ApplicationGroup()]); 68 [[NSUserDefaults alloc] initWithSuiteName:ApplicationGroup()]);
65 [shared_defaults removeObjectForKey:@(kChromeAppClientID)]; 69 [shared_defaults removeObjectForKey:@(kChromeAppClientID)];
66 } 70 }
67 71
68 } // namespace main_app 72 } // namespace main_app
69 73
70 } // namespace app_group 74 } // namespace app_group
OLDNEW
« no previous file with comments | « ios/chrome/common/app_group/app_group_metrics_client.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698