OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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.customtabs; | 5 package org.chromium.chrome.browser.customtabs; |
6 | 6 |
7 import android.content.Intent; | 7 import android.content.Intent; |
8 import android.net.Uri; | 8 import android.net.Uri; |
9 import android.os.Bundle; | 9 import android.os.Bundle; |
10 import android.os.IBinder; | 10 import android.os.IBinder; |
(...skipping 18 matching lines...) Expand all Loading... |
29 public void onCreate() { | 29 public void onCreate() { |
30 ProcessInitializationHandler.getInstance().initializePreNative(); | 30 ProcessInitializationHandler.getInstance().initializePreNative(); |
31 // Kick off the first access to avoid random StrictMode violations in cl
ients. | 31 // Kick off the first access to avoid random StrictMode violations in cl
ients. |
32 RequestThrottler.loadInBackground(getApplication()); | 32 RequestThrottler.loadInBackground(getApplication()); |
33 super.onCreate(); | 33 super.onCreate(); |
34 } | 34 } |
35 | 35 |
36 @Override | 36 @Override |
37 public IBinder onBind(Intent intent) { | 37 public IBinder onBind(Intent intent) { |
38 mBindIntent = intent; | 38 mBindIntent = intent; |
39 mConnection = CustomTabsConnection.getInstance(getApplication()); | 39 mConnection = CustomTabsConnection.getInstance(); |
40 mConnection.logCall("Service#onBind()", true); | 40 mConnection.logCall("Service#onBind()", true); |
41 return super.onBind(intent); | 41 return super.onBind(intent); |
42 } | 42 } |
43 | 43 |
44 @Override | 44 @Override |
45 public boolean onUnbind(Intent intent) { | 45 public boolean onUnbind(Intent intent) { |
46 super.onUnbind(intent); | 46 super.onUnbind(intent); |
47 if (mConnection != null) mConnection.logCall("Service#onUnbind()", true)
; | 47 if (mConnection != null) mConnection.logCall("Service#onUnbind()", true)
; |
48 return false; // No support for onRebind(). | 48 return false; // No support for onRebind(). |
49 } | 49 } |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 FirstRunFlowSequencer.checkIfFirstRunIsNecessary( | 105 FirstRunFlowSequencer.checkIfFirstRunIsNecessary( |
106 getApplicationContext(), mBindIntent, showLightweightFre
) | 106 getApplicationContext(), mBindIntent, showLightweightFre
) |
107 != null; | 107 != null; |
108 if (!firstRunNecessary) { | 108 if (!firstRunNecessary) { |
109 mBindIntent = null; | 109 mBindIntent = null; |
110 return true; | 110 return true; |
111 } | 111 } |
112 return false; | 112 return false; |
113 } | 113 } |
114 } | 114 } |
OLD | NEW |