Upstream version 10.39.225.0
[platform/framework/web/crosswalk.git] / src / chrome / android / sync_shell / chrome_main_delegate_chrome_sync_shell_android.cc
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/android/sync_shell/chrome_main_delegate_chrome_sync_shell_android.h"
6
7 #include "base/android/jni_android.h"
8 #include "base/android/jni_registrar.h"
9 #include "components/search_engines/template_url_prepopulate_data.h"
10 #include "sync/test/fake_server/android/fake_server_helper_android.h"
11
12 static const char kDefaultCountryCode[] = "US";
13
14 ChromeMainDelegateAndroid* ChromeMainDelegateAndroid::Create() {
15   return new ChromeMainDelegateChromeSyncShellAndroid();
16 }
17
18 ChromeMainDelegateChromeSyncShellAndroid::
19 ChromeMainDelegateChromeSyncShellAndroid() {
20 }
21
22 ChromeMainDelegateChromeSyncShellAndroid::
23 ~ChromeMainDelegateChromeSyncShellAndroid() {
24 }
25
26 bool
27 ChromeMainDelegateChromeSyncShellAndroid::RegisterApplicationNativeMethods(
28     JNIEnv* env) {
29   return ChromeMainDelegateAndroid::RegisterApplicationNativeMethods(env) &&
30       FakeServerHelperAndroid::Register(env);
31 }
32
33 bool ChromeMainDelegateChromeSyncShellAndroid::BasicStartupComplete(
34     int* exit_code) {
35   TemplateURLPrepopulateData::InitCountryCode(kDefaultCountryCode);
36   return ChromeMainDelegateAndroid::BasicStartupComplete(exit_code);
37 }
38