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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/webapps/GooglePlayWebApkInstallDelegate.java

Issue 2728053002: [Android:WebAPK] Don't add webapp to homescreen if WebAPK install times out part 2/3 (Closed)
Patch Set: Merge branch 'refactor_shortcut_helper3' into refactor_shortcut_helper4 Created 3 years, 9 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
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstaller.java » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 package org.chromium.chrome.browser.webapps; 5 package org.chromium.chrome.browser.webapps;
6 6
7 import android.support.annotation.IntDef; 7 import android.support.annotation.IntDef;
8 8
9 import org.chromium.base.Callback; 9 import org.chromium.base.Callback;
10 10
(...skipping 20 matching lines...) Expand all
31 public static final int INSTALL_ERROR = 5; 31 public static final int INSTALL_ERROR = 5;
32 public static final int INSTALLED = 6; 32 public static final int INSTALLED = 6;
33 33
34 /** 34 /**
35 * Uses Google Play to install WebAPK asynchronously. 35 * Uses Google Play to install WebAPK asynchronously.
36 * @param packageName The package name of WebAPK to install. 36 * @param packageName The package name of WebAPK to install.
37 * @param version The version of WebAPK to install. 37 * @param version The version of WebAPK to install.
38 * @param title The title of the WebAPK to display during installation. 38 * @param title The title of the WebAPK to display during installation.
39 * @param token The token from WebAPK Minter Server. 39 * @param token The token from WebAPK Minter Server.
40 * @param url The start URL of the WebAPK to install. 40 * @param url The start URL of the WebAPK to install.
41 * @param callback The callback to invoke when the install is either complet ed or failed. 41 * @param callback The callback to invoke when the install completes, times out or fails.
42 */ 42 */
43 void installAsync(String packageName, int version, String title, String toke n, String url, 43 void installAsync(String packageName, int version, String title, String toke n, String url,
44 Callback<Boolean> callback); 44 Callback<Integer> callback);
45 45
46 /** 46 /**
47 * Calls the callback once the installation either succeeded or failed. 47 * Calls the callback once the installation either succeeded or failed.
48 * @param packageName The package name of WebAPK for the installation. 48 * @param packageName The package name of WebAPK for the installation.
49 * @param event The result of the install. 49 * @param event The result of the install.
50 */ 50 */
51 void onGotInstallEvent(String packageName, @InstallerPackageEvent int event) ; 51 void onGotInstallEvent(String packageName, @InstallerPackageEvent int event) ;
52
53 /**
54 * Checks whether Google Play Install API is available.
55 * @param callback The callback to invoke when the check is done.
56 */
57 void canInstallWebApk(Callback<Boolean> callback);
58 } 52 }
OLDNEW
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstaller.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698