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

Unified Diff: content/renderer/android/content_detector.h

Issue 2790893004: Delete Android content detectors. (Closed)
Patch Set: Rebase Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/android/address_detector.cc ('k') | content/renderer/android/content_detector.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/android/content_detector.h
diff --git a/content/renderer/android/content_detector.h b/content/renderer/android/content_detector.h
deleted file mode 100644
index ea85fc7e7256746875e1f5590d5e7f572d73bd20..0000000000000000000000000000000000000000
--- a/content/renderer/android/content_detector.h
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CONTENT_RENDERER_ANDROID_CONTENT_DETECTOR_H_
-#define CONTENT_RENDERER_ANDROID_CONTENT_DETECTOR_H_
-
-#include <stddef.h>
-
-#include "base/macros.h"
-#include "third_party/WebKit/public/platform/WebURL.h"
-#include "url/gurl.h"
-
-namespace blink {
-class WebHitTestResult;
-}
-
-namespace content {
-
-// Base class for text-based content detectors.
-class ContentDetector {
- public:
- virtual ~ContentDetector() {}
-
- // Returns an intent URL for the content around the hit_test.
- // If no content is found, an empty URL will be returned.
- blink::WebURL FindTappedContent(const blink::WebHitTestResult& hit_test);
-
- protected:
- ContentDetector() {}
-
- // Parses the input string defined by the begin/end iterators returning true
- // if the desired content is found. The start and end positions relative to
- // the input iterators are returned in start_pos and end_pos.
- // The end position is assumed to be non-inclusive.
- virtual bool FindContent(const base::string16::const_iterator& begin,
- const base::string16::const_iterator& end,
- size_t* start_pos,
- size_t* end_pos,
- std::string* content_text) = 0;
-
- // Returns the intent URL that should process the content, if any.
- virtual GURL GetIntentURL(const std::string& content_text) = 0;
-
- // Returns the maximum length of text to be extracted around the tapped
- // position in order to search for content.
- virtual size_t GetMaximumContentLength() = 0;
-
- bool FindContentRange(const blink::WebHitTestResult& hit_test,
- std::string* content_text);
-
- DISALLOW_COPY_AND_ASSIGN(ContentDetector);
-};
-
-} // namespace content
-
-#endif // CONTENT_RENDERER_ANDROID_CONTENT_DETECTOR_H_
« no previous file with comments | « content/renderer/android/address_detector.cc ('k') | content/renderer/android/content_detector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698