Changeset 149942 in webkit


Ignore:
Timestamp:
May 11, 2013 2:42:44 PM (11 years ago)
Author:
Antoine Quint
Message:

[Mac] The captions menu should not use a canned max-width and max-height
https://bugs.webkit.org/show_bug.cgi?id=115968

Reviewed by Eric Carlson.

Use more real estate to display the captions menu should the caption names
be long.

  • css/mediaControlsQuickTime.css:

(video::-webkit-media-controls-closed-captions-container):
(video::-webkit-media-controls-closed-captions-track-list):
Make the captions menu scale to a max-width and max-height to allow 4px
above and below the menu, except on the right where it always aligns with
the captions icon in the media controller.

  • html/shadow/MediaControlsApple.cpp:

(WebCore::MediaControlsApple::createControls):
Move the captions menu element to be a child of the controls instead of
the panel such that it may scale relative to the controls when using %
CSS values.

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r149936 r149942  
     12013-05-11  Antoine Quint  <graouts@apple.com>
     2
     3        [Mac] The captions menu should not use a canned max-width and max-height
     4        https://bugs.webkit.org/show_bug.cgi?id=115968
     5
     6        Reviewed by Eric Carlson.
     7
     8        Use more real estate to display the captions menu should the caption names
     9        be long.
     10
     11        * css/mediaControlsQuickTime.css:
     12        (video::-webkit-media-controls-closed-captions-container):
     13        (video::-webkit-media-controls-closed-captions-track-list):
     14        Make the captions menu scale to a max-width and max-height to allow 4px
     15        above and below the menu, except on the right where it always aligns with
     16        the captions icon in the media controller.
     17        * html/shadow/MediaControlsApple.cpp:
     18        (WebCore::MediaControlsApple::createControls):
     19        Move the captions menu element to be a child of the controls instead of
     20        the panel such that it may scale relative to the controls when using %
     21        CSS values.
     22
    1232013-05-11  Jochen Eisinger  <jochen@chromium.org>
    224
  • trunk/Source/WebCore/css/mediaControlsQuickTime.css

    r149237 r149942  
    253253    right: 38px;
    254254    bottom: 29px;
     255    max-width: -webkit-calc(100% - 48px); /* right + 10px */
     256    max-height: -webkit-calc(100% - 39px); /* bottom + 10px */
     257    overflow-x: hidden;
     258    overflow-y: scroll;
    255259    background-color: rgba(0, 0, 0, 0.85);
    256260    border: 3px solid rgba(128, 128, 128, 0.75);
     
    262266video::-webkit-media-controls-closed-captions-track-list {
    263267    display: block;
    264     max-width: 250px;
    265     max-height: 250px;
    266     overflow-x: hidden;
    267     overflow-y: scroll;
    268268    text-align: left;
    269269    font-family: "Helvetica Bold", Helvetica;
  • trunk/Source/WebCore/html/shadow/MediaControlsApple.cpp

    r148099 r149942  
    164164
    165165        controls->m_closedCaptionsContainer = closedCaptionsContainer.get();
    166         panel->appendChild(closedCaptionsContainer.release(), ec, AttachLazily);
     166        controls->appendChild(closedCaptionsContainer.release(), ec, AttachLazily);
    167167        if (ec)
    168168            return 0;
Note: See TracChangeset for help on using the changeset viewer.