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

Unified Diff: sync/util/get_session_name_ios.mm

Issue 11360194: Bring up minimal sync and sync unittest targets on iOS. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« sync/util/get_session_name_ios.h ('K') | « sync/util/get_session_name_ios.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/util/get_session_name_ios.mm
diff --git a/sync/util/get_session_name_win.h b/sync/util/get_session_name_ios.mm
similarity index 55%
copy from sync/util/get_session_name_win.h
copy to sync/util/get_session_name_ios.mm
index 8ec903f6094a15a0bb3b2cc38b5fb70fd3d89da2..dbc04f44db86f778cad68f25f5fe1831aefa7db0 100644
--- a/sync/util/get_session_name_win.h
+++ b/sync/util/get_session_name_ios.mm
@@ -2,17 +2,18 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef SYNC_UTIL_GET_SESSION_NAME_WIN_H_
-#define SYNC_UTIL_GET_SESSION_NAME_WIN_H_
+#include "sync/util/get_session_name_ios.h"
qsr 2012/11/13 10:58:12 Same thing here about copy
blundell 2012/11/13 14:07:42 Done.
-#include <string>
+#import <UIKit/UIKit.h>
+
+#include "base/sys_string_conversions.h"
namespace syncer {
namespace internal {
-std::string GetComputerName();
+std::string GetComputerName() {
+ return base::SysNSStringToUTF8([[UIDevice currentDevice] name]);
+}
} // namespace internal
} // namespace syncer
-
-#endif // SYNC_UTIL_GET_SESSION_NAME_WIN_H_
« sync/util/get_session_name_ios.h ('K') | « sync/util/get_session_name_ios.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698