Changeset 195511 in webkit


Ignore:
Timestamp:
Jan 23, 2016 2:51:40 PM (8 years ago)
Author:
commit-queue@webkit.org
Message:

[GTK] Fix media controls displaying without controls attribute
https://bugs.webkit.org/show_bug.cgi?id=152500

Media controls is not displayed without controls attribute by default
when the video element has text track. It'll be displayed on fullscreen
regardless of controls attribute.

Patch by Wonchul Lee <wonchul.lee@collabora.co.uk> on 2016-01-23
Reviewed by Michael Catanzaro.

Source/WebCore:

  • Modules/mediacontrols/mediaControlsGtk.js:

(ControllerGtk.prototype.shouldHaveControls):
(ControllerGtk.prototype.reconnectControls):
(ControllerGtk.prototype.removeControls):
(ControllerGtk.prototype.configureControls): Deleted.

LayoutTests:

  • media/video-controls-no-display-with-text-track-expected.txt: Added.
  • media/video-controls-no-display-with-text-track.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r195508 r195511  
     12016-01-23  Wonchul Lee  <wonchul.lee@collabora.co.uk>
     2
     3        [GTK] Fix media controls displaying without controls attribute
     4        https://bugs.webkit.org/show_bug.cgi?id=152500
     5
     6        Media controls is not displayed without controls attribute by default
     7        when the video element has text track. It'll be displayed on fullscreen
     8        regardless of controls attribute.
     9
     10        Reviewed by Michael Catanzaro.
     11
     12        * media/video-controls-no-display-with-text-track-expected.txt: Added.
     13        * media/video-controls-no-display-with-text-track.html: Added.
     14
    1152016-01-23  Brady Eidson  <beidson@apple.com>
    216
  • trunk/Source/WebCore/ChangeLog

    r195509 r195511  
     12016-01-23  Wonchul Lee  <wonchul.lee@collabora.co.uk>
     2
     3        [GTK] Fix media controls displaying without controls attribute
     4        https://bugs.webkit.org/show_bug.cgi?id=152500
     5
     6        Media controls is not displayed without controls attribute by default
     7        when the video element has text track. It'll be displayed on fullscreen
     8        regardless of controls attribute.
     9
     10        Reviewed by Michael Catanzaro.
     11
     12        * Modules/mediacontrols/mediaControlsGtk.js:
     13        (ControllerGtk.prototype.shouldHaveControls):
     14        (ControllerGtk.prototype.reconnectControls):
     15        (ControllerGtk.prototype.removeControls):
     16        (ControllerGtk.prototype.configureControls): Deleted.
    1172016-01-23  Alex Christensen  <achristensen@webkit.org>
    218
  • trunk/Source/WebCore/Modules/mediacontrols/mediaControlsGtk.js

    r177015 r195511  
    5555    },
    5656
    57     configureControls: function() {
    58         if (this.controls.configured)
    59             return;
     57    shouldHaveControls: function()
     58    {
     59        return this.video.controls || this.isFullScreen();
     60    },
     61
     62    reconnectControls: function()
     63    {
     64        Controller.prototype.disconnectControls.apply(this, arguments);
    6065
    6166        this.configureInlineControls();
    62         this.controls.configured = true;
    63         this.addControls();
    64     },
    65 
    66     reconnectControls: function()
    67     {
    68         this.configureControls();
     67
     68        if (this.shouldHaveControls())
     69            this.addControls();
    6970    },
    7071
     
    134135    },
    135136
     137    removeControls: function()
     138    {
     139        if (this.controls.enclosure.parentNode)
     140            this.controls.enclosure.parentNode.removeChild(this.controls.enclosure);
     141        this.destroyCaptionMenu();
     142    },
     143
    136144    addControls: function()
    137145    {
Note: See TracChangeset for help on using the changeset viewer.