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

Side by Side Diff: content/child/blink_platform_impl.cc

Issue 1079323002: Support text track selection in video controls (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge Blink repo changes and addressed comments from philipj and UX Created 4 years, 10 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "content/child/blink_platform_impl.h" 5 #include "content/child/blink_platform_impl.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after
398 case WebLocalizedString::ValidationValueMissingForMultipleFile: 398 case WebLocalizedString::ValidationValueMissingForMultipleFile:
399 return IDS_FORM_VALIDATION_VALUE_MISSING_MULTIPLE_FILE; 399 return IDS_FORM_VALIDATION_VALUE_MISSING_MULTIPLE_FILE;
400 case WebLocalizedString::ValidationValueMissingForRadio: 400 case WebLocalizedString::ValidationValueMissingForRadio:
401 return IDS_FORM_VALIDATION_VALUE_MISSING_RADIO; 401 return IDS_FORM_VALIDATION_VALUE_MISSING_RADIO;
402 case WebLocalizedString::ValidationValueMissingForSelect: 402 case WebLocalizedString::ValidationValueMissingForSelect:
403 return IDS_FORM_VALIDATION_VALUE_MISSING_SELECT; 403 return IDS_FORM_VALIDATION_VALUE_MISSING_SELECT;
404 case WebLocalizedString::WeekFormatTemplate: 404 case WebLocalizedString::WeekFormatTemplate:
405 return IDS_FORM_INPUT_WEEK_TEMPLATE; 405 return IDS_FORM_INPUT_WEEK_TEMPLATE;
406 case WebLocalizedString::WeekNumberLabel: 406 case WebLocalizedString::WeekNumberLabel:
407 return IDS_FORM_WEEK_NUMBER_LABEL; 407 return IDS_FORM_WEEK_NUMBER_LABEL;
408 case WebLocalizedString::TextTracksNoLabel:
409 return IDS_MEDIA_TRACKS_NO_LABEL;
410 case WebLocalizedString::TextTracksOff:
411 return IDS_MEDIA_TRACKS_OFF;
408 // This "default:" line exists to avoid compile warnings about enum 412 // This "default:" line exists to avoid compile warnings about enum
409 // coverage when we add a new symbol to WebLocalizedString.h in WebKit. 413 // coverage when we add a new symbol to WebLocalizedString.h in WebKit.
410 // After a planned WebKit patch is landed, we need to add a case statement 414 // After a planned WebKit patch is landed, we need to add a case statement
411 // for the added symbol here. 415 // for the added symbol here.
412 default: 416 default:
413 break; 417 break;
414 } 418 }
415 return -1; 419 return -1;
416 } 420 }
417 421
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after
811 ui::SCALE_FACTOR_100P}, 815 ui::SCALE_FACTOR_100P},
812 {"mediaplayerOverlayCastOffNew", 816 {"mediaplayerOverlayCastOffNew",
813 IDR_MEDIAPLAYER_OVERLAY_CAST_BUTTON_OFF_NEW, 817 IDR_MEDIAPLAYER_OVERLAY_CAST_BUTTON_OFF_NEW,
814 ui::SCALE_FACTOR_100P}, 818 ui::SCALE_FACTOR_100P},
815 {"mediaplayerOverlayPlay", 819 {"mediaplayerOverlayPlay",
816 IDR_MEDIAPLAYER_OVERLAY_PLAY_BUTTON, 820 IDR_MEDIAPLAYER_OVERLAY_PLAY_BUTTON,
817 ui::SCALE_FACTOR_100P}, 821 ui::SCALE_FACTOR_100P},
818 {"mediaplayerOverlayPlayNew", 822 {"mediaplayerOverlayPlayNew",
819 IDR_MEDIAPLAYER_OVERLAY_PLAY_BUTTON_NEW, 823 IDR_MEDIAPLAYER_OVERLAY_PLAY_BUTTON_NEW,
820 ui::SCALE_FACTOR_100P}, 824 ui::SCALE_FACTOR_100P},
825 {"mediaplayerTrackSelectionCheckmark",
826 IDR_MEDIAPLAYER_TRACKSELECTION_CHECKMARK,
827 ui::SCALE_FACTOR_100P},
828 {"mediaplayerTrackSelectionCheckmarkNew",
829 IDR_MEDIAPLAYER_TRACKSELECTION_CHECKMARK_NEW,
830 ui::SCALE_FACTOR_100P},
831 {"mediaplayerClosedCaptionsIcon",
832 IDR_MEDIAPLAYER_CLOSEDCAPTIONS_ICON,
833 ui::SCALE_FACTOR_100P},
834 {"mediaplayerClosedCaptionsIconNew",
835 IDR_MEDIAPLAYER_CLOSEDCAPTIONS_ICON_NEW,
836 ui::SCALE_FACTOR_100P},
837 {"mediaplayerSubtitlesIcon",
838 IDR_MEDIAPLAYER_SUBTITLES_ICON,
839 ui::SCALE_FACTOR_100P},
840 {"mediaplayerSubtitlesIconNew",
841 IDR_MEDIAPLAYER_SUBTITLES_ICON_NEW,
842 ui::SCALE_FACTOR_100P},
821 {"searchCancel", IDR_SEARCH_CANCEL, ui::SCALE_FACTOR_100P}, 843 {"searchCancel", IDR_SEARCH_CANCEL, ui::SCALE_FACTOR_100P},
822 {"searchCancelPressed", IDR_SEARCH_CANCEL_PRESSED, ui::SCALE_FACTOR_100P}, 844 {"searchCancelPressed", IDR_SEARCH_CANCEL_PRESSED, ui::SCALE_FACTOR_100P},
823 {"searchMagnifier", IDR_SEARCH_MAGNIFIER, ui::SCALE_FACTOR_100P}, 845 {"searchMagnifier", IDR_SEARCH_MAGNIFIER, ui::SCALE_FACTOR_100P},
824 {"searchMagnifierResults", 846 {"searchMagnifierResults",
825 IDR_SEARCH_MAGNIFIER_RESULTS, 847 IDR_SEARCH_MAGNIFIER_RESULTS,
826 ui::SCALE_FACTOR_100P}, 848 ui::SCALE_FACTOR_100P},
827 {"textAreaResizeCorner", IDR_TEXTAREA_RESIZER, ui::SCALE_FACTOR_100P}, 849 {"textAreaResizeCorner", IDR_TEXTAREA_RESIZER, ui::SCALE_FACTOR_100P},
828 {"textAreaResizeCorner@2x", IDR_TEXTAREA_RESIZER, ui::SCALE_FACTOR_200P}, 850 {"textAreaResizeCorner@2x", IDR_TEXTAREA_RESIZER, ui::SCALE_FACTOR_200P},
829 {"generatePassword", IDR_PASSWORD_GENERATION_ICON, ui::SCALE_FACTOR_100P}, 851 {"generatePassword", IDR_PASSWORD_GENERATION_ICON, ui::SCALE_FACTOR_100P},
830 {"generatePasswordHover", 852 {"generatePasswordHover",
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
1198 return WebString::fromUTF8(ui::KeycodeConverter::DomKeyToKeyString( 1220 return WebString::fromUTF8(ui::KeycodeConverter::DomKeyToKeyString(
1199 static_cast<ui::DomKey>(dom_key))); 1221 static_cast<ui::DomKey>(dom_key)));
1200 } 1222 }
1201 1223
1202 int BlinkPlatformImpl::domKeyEnumFromString(const WebString& key_string) { 1224 int BlinkPlatformImpl::domKeyEnumFromString(const WebString& key_string) {
1203 return static_cast<int>( 1225 return static_cast<int>(
1204 ui::KeycodeConverter::KeyStringToDomKey(key_string.utf8())); 1226 ui::KeycodeConverter::KeyStringToDomKey(key_string.utf8()));
1205 } 1227 }
1206 1228
1207 } // namespace content 1229 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698