Index: chrome/browser/io_thread.h |
diff --git a/chrome/browser/io_thread.h b/chrome/browser/io_thread.h |
index f57bc395a0eb16e6b0e6966ac96c5461a152ea8d..79478046277be138a1ec696f440f089248864866 100644 |
--- a/chrome/browser/io_thread.h |
+++ b/chrome/browser/io_thread.h |
@@ -39,6 +39,7 @@ class CommandLine; |
#if defined(OS_ANDROID) |
namespace chrome { |
namespace android { |
+class DataUseTabModel; |
class ExternalDataUseObserver; |
} |
} |
@@ -267,9 +268,13 @@ class IOThread : public content::BrowserThreadDelegate { |
static bool ShouldEnableQuicForDataReductionProxy(); |
#if defined(OS_ANDROID) |
-chrome::android::ExternalDataUseObserver* external_data_use_observer() const { |
- return external_data_use_observer_.get(); |
-} |
+ chrome::android::ExternalDataUseObserver* external_data_use_observer() const { |
+ return external_data_use_observer_.get(); |
+ } |
+ |
+ base::WeakPtr<chrome::android::DataUseTabModel> data_use_tab_model() const { |
sclittle
2015/11/18 21:42:04
Why expose this here? Why not just call external_d
tbansal1
2015/11/19 00:47:07
GetWeakPtr() needs to be called on IO thread. prof
|
+ return data_use_tab_model_; |
+ } |
#endif // defined(OS_ANDROID) |
private: |
@@ -539,6 +544,8 @@ chrome::android::ExternalDataUseObserver* external_data_use_observer() const { |
#if defined(OS_ANDROID) |
scoped_ptr<chrome::android::ExternalDataUseObserver> |
external_data_use_observer_; |
+ // WeakPtr to DataUseTabModel to be used on IO thread. |
+ base::WeakPtr<chrome::android::DataUseTabModel> data_use_tab_model_; |
#endif // defined(OS_ANDROID) |
const base::TimeTicks creation_time_; |