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

Side by Side Diff: chrome/browser/android/webapk/webapk_update_manager.h

Issue 2409453002: Fix crash on WebAPK startup (Closed)
Patch Set: Created 4 years, 2 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_ 5 #ifndef CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_
6 #define CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_ 6 #define CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_
7 7
8 #include "base/android/jni_android.h" 8 #include "base/android/jni_android.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 10
11 // WebApkUpdateManager is the C++ counterpart of org.chromium.chrome.browser's 11 // WebApkUpdateManager is the C++ counterpart of org.chromium.chrome.browser's
12 // WebApkUpdateManager in Java. It calls WebApkInstaller to send an update 12 // WebApkUpdateManager in Java. It calls WebApkInstaller to send an update
13 // request to WebAPK Server. 13 // request to WebAPK Server.
14 class WebApkUpdateManager { 14 class WebApkUpdateManager {
15 public: 15 public:
16 // Registers JNI hooks. 16 // Registers JNI hooks.
17 static bool Register(JNIEnv* env); 17 static bool Register(JNIEnv* env);
18 18
19 // Called after either a request to update the WebAPK has been sent, or the 19 // Called after either a request to update the WebAPK has been sent, or the
20 // update process fails. 20 // update process fails.
21 // |success| indicates whether the request was issued to the server. A "true" 21 // |success| indicates whether the request was issued to the server. A "true"
dominickn 2016/10/10 06:05:38 Minor nit: reflow this comment.
pkotwicz 2016/10/10 16:42:01 What do you mean? Are you suggesting that there sh
dominickn 2016/10/11 04:54:05 Yes, that's what I meant. Pretty minor, feel free
22 // value of |success| does not guarantee that the WebAPK will be successfully 22 // value of |success| does not guarantee that the WebAPK will be successfully
23 // updated. 23 // updated.
24 static void OnBuiltWebApk(bool success, const std::string& webapk_package); 24 static void OnBuiltWebApk(const std::string& id,
25 bool success,
26 const std::string& webapk_package);
25 27
26 private: 28 private:
27 DISALLOW_IMPLICIT_CONSTRUCTORS(WebApkUpdateManager); 29 DISALLOW_IMPLICIT_CONSTRUCTORS(WebApkUpdateManager);
28 }; 30 };
29 31
30 #endif // CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_ 32 #endif // CHROME_BROWSER_ANDROID_WEBAPK_WEBAPK_UPDATE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698