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

Side by Side Diff: chrome/browser/dom_distiller/dom_distiller_service_factory_android.cc

Issue 340403004: Java wrapper for DistilledPagePrefs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Spacing and indentation Created 6 years, 5 months 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 | Annotate | Revision Log
OLDNEW
(Empty)
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 "base/android/jni_android.h"
6 #include "base/android/jni_string.h"
7
8 #include "chrome/browser/dom_distiller/dom_distiller_service_factory.h"
9 #include "chrome/browser/dom_distiller/dom_distiller_service_factory_android.h"
10 #include "chrome/browser/profiles/profile.h"
11 #include "chrome/browser/profiles/profile_android.h"
12
13 #include "jni/DomDistillerServiceFactory_jni.h"
14
15 static jlong GetDomDistillerServiceForProfile(JNIEnv* env,
nyquist 2014/06/30 20:33:22 Could this instead return the jobject for DomDisti
sunangel 2014/07/07 21:21:29 Done.
16 jclass clazz,
17 jobject j_profile) {
18 Profile* nativeProfilePointer = ProfileAndroid::FromProfileAndroid(j_profile);
nyquist 2014/06/30 20:33:22 Just |profile|
sunangel 2014/07/07 21:21:29 Done.
19 dom_distiller::DomDistillerService* service =
20 dom_distiller::DomDistillerServiceFactory::GetForBrowserContext(
21 nativeProfilePointer);
22 return reinterpret_cast<intptr_t>(service);
nyquist 2014/06/30 20:33:23 I think here you can new the DomDistillerServiceAn
sunangel 2014/07/07 21:21:29 Done.
23 }
24
25 bool RegisterDomDistillerServiceFactory(JNIEnv* env) {
26 return RegisterNativesImpl(env);
27 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698