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

Unified Diff: chrome/browser/android/offline_pages/offline_page_bridge.cc

Issue 1521193002: [Offline pages] Refactor URL conversions from TabAndroid (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing feedback, updating tests, moving functions to a static class Created 5 years 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/android/offline_pages/offline_page_bridge.cc
diff --git a/chrome/browser/android/offline_pages/offline_page_bridge.cc b/chrome/browser/android/offline_pages/offline_page_bridge.cc
index 62f1aac5f78675ce4864fccdca9811b80bda76e8..54f42a4e2d9cfa712348c9aa457289a4f9b0b07b 100644
--- a/chrome/browser/android/offline_pages/offline_page_bridge.cc
+++ b/chrome/browser/android/offline_pages/offline_page_bridge.cc
@@ -7,7 +7,6 @@
#include "base/android/jni_array.h"
#include "base/android/jni_string.h"
#include "base/basictypes.h"
-#include "base/strings/string_util.h"
#include "chrome/browser/android/offline_pages/offline_page_mhtml_archiver.h"
#include "chrome/browser/android/offline_pages/offline_page_model_factory.h"
#include "chrome/browser/profiles/profile.h"
@@ -248,16 +247,6 @@ ScopedJavaLocalRef<jobject> OfflinePageBridge::CreateOfflinePageItem(
offline_page.last_access_time.ToJavaTime());
}
-// static
-bool OfflinePageBridge::MightBeOfflineURL(const GURL& url) {
- // It has to be a file URL ending with .mhtml extension.
- return url.is_valid() &&
- url.SchemeIsFile() &&
- base::EndsWith(url.spec(),
- OfflinePageMHTMLArchiver::GetFileNameExtension(),
- base::CompareCase::INSENSITIVE_ASCII);
-}
-
static jlong Init(JNIEnv* env,
const JavaParamRef<jobject>& obj,
const JavaParamRef<jobject>& j_profile) {

Powered by Google App Engine
This is Rietveld 408576698