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

Side by Side Diff: components/offline_pages/offline_page_model_impl.cc

Issue 2089423002: [Offline Pages] Connect the offline page logs to the internals page. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@i4
Patch Set: update naming and fix merge conflict Created 4 years, 6 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 #include "components/offline_pages/offline_page_model_impl.h" 5 #include "components/offline_pages/offline_page_model_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after
1040 static_cast<int32_t>(expired_page_count)); 1040 static_cast<int32_t>(expired_page_count));
1041 } 1041 }
1042 } 1042 }
1043 1043
1044 void OfflinePageModelImpl::PostClearStorageIfNeededTask() { 1044 void OfflinePageModelImpl::PostClearStorageIfNeededTask() {
1045 base::ThreadTaskRunnerHandle::Get()->PostTask( 1045 base::ThreadTaskRunnerHandle::Get()->PostTask(
1046 FROM_HERE, base::Bind(&OfflinePageModelImpl::ClearStorageIfNeeded, 1046 FROM_HERE, base::Bind(&OfflinePageModelImpl::ClearStorageIfNeeded,
1047 weak_ptr_factory_.GetWeakPtr(), 1047 weak_ptr_factory_.GetWeakPtr(),
1048 base::Bind(&OfflinePageModelImpl::OnStorageCleared, 1048 base::Bind(&OfflinePageModelImpl::OnStorageCleared,
1049 weak_ptr_factory_.GetWeakPtr()))); 1049 weak_ptr_factory_.GetWeakPtr())));
1050 }
dpapad 2016/06/24 22:14:53 Accidental? I think this is causing the tryjobs to
chili 2016/06/24 22:35:23 Bad merge :(
1051 1050
1052 void OfflinePageModelImpl::RunWhenLoaded(const base::Closure& task) { 1051 void OfflinePageModelImpl::RunWhenLoaded(const base::Closure& task) {
1053 if (!is_loaded_) { 1052 if (!is_loaded_) {
1054 delayed_tasks_.push_back(task); 1053 delayed_tasks_.push_back(task);
1055 return; 1054 return;
1056 } 1055 }
1057 1056
1058 base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, task); 1057 base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, task);
1059 } 1058 }
1060 1059
1061 } // namespace offline_pages 1060 } // namespace offline_pages
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698