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

Unified Diff: Source/WebKit/chromium/public/WebInbandTextTrack.h

Issue 13968007: Create WebInbandTextTrack and WebInbandTextTrackClient (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 7 years, 7 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 | « Source/WebKit/chromium/WebKit.gyp ('k') | Source/WebKit/chromium/public/WebInbandTextTrackClient.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebKit/chromium/public/WebInbandTextTrack.h
diff --git a/Source/WebKit/chromium/public/WebValidationMessageClient.h b/Source/WebKit/chromium/public/WebInbandTextTrack.h
similarity index 66%
copy from Source/WebKit/chromium/public/WebValidationMessageClient.h
copy to Source/WebKit/chromium/public/WebInbandTextTrack.h
index 6ba1555272942b015102b4c3df0b3d2ba2e8867c..cebdf20b8552aee6e4cc4977ebcf6cb7ebbc1e02 100644
--- a/Source/WebKit/chromium/public/WebValidationMessageClient.h
+++ b/Source/WebKit/chromium/public/WebInbandTextTrack.h
@@ -28,30 +28,47 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebValidationMessageClient_h
-#define WebValidationMessageClient_h
-
-#include "WebTextDirection.h"
+#ifndef WebInbandTextTrack_h
+#define WebInbandTextTrack_h
namespace WebKit {
class WebString;
-struct WebRect;
+class WebInbandTextTrackClient;
-// Client interface to handle form validation message UI.
-class WebValidationMessageClient {
+class WebInbandTextTrack {
public:
- // Show a notification popup for the specified form vaidation messages
- // besides the anchor rectangle. An implementation of this function should
- // not hide the popup until hideValidationMessage call.
- virtual void showValidationMessage(const WebRect& anchorInScreen, const WebString& mainText, const WebString& supplementalText, WebTextDirection hint) { }
+ enum Kind {
+ KindSubtitles,
+ KindCaptions,
+ KindDescriptions,
+ KindChapters,
+ KindMetadata,
+ KindNone
+ };
+
+ enum Mode {
+ ModeDisabled,
+ ModeHidden,
+ ModeShowing
+ };
+
+ virtual ~WebInbandTextTrack() {}
+
+ virtual void setClient(WebInbandTextTrackClient*) = 0;
+ virtual WebInbandTextTrackClient* client() = 0;
+
+ virtual void setMode(Mode) = 0;
+ virtual Mode mode() const = 0;
- // Hide notifation popup for form validation messages.
- virtual void hideValidationMessage() { }
+ virtual Kind kind() const = 0;
+ virtual bool isClosedCaptions() const = 0;
+ virtual WebString label() const = 0;
+ virtual WebString language() const = 0;
+ virtual bool isDefault() const = 0;
-protected:
- virtual ~WebValidationMessageClient() { }
+ virtual int textTrackIndex() const = 0;
};
} // namespace WebKit
« no previous file with comments | « Source/WebKit/chromium/WebKit.gyp ('k') | Source/WebKit/chromium/public/WebInbandTextTrackClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698