Bug 135759 - Adjustments to CueBox CSS Width calculations
Summary: Adjustments to CueBox CSS Width calculations
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
: 135720 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-08-08 10:58 PDT by Roger Fong
Modified: 2014-08-08 14:42 PDT (History)
13 users (show)

See Also:


Attachments
patch (8.52 KB, patch)
2014-08-08 11:59 PDT, Roger Fong
eric.carlson: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Roger Fong 2014-08-08 10:58:45 PDT
<rdar://problem/17954473>

This is a followup patch to http://trac.webkit.org/changeset/172224

It addresses the bugs I introduced with that revision and fixes the two test failures skipped here:
https://bugs.webkit.org/show_bug.cgi?id=135720
Comment 1 Roger Fong 2014-08-08 11:59:27 PDT
Created attachment 236293 [details]
patch
Comment 2 Eric Carlson 2014-08-08 12:15:32 PDT
Comment on attachment 236293 [details]
patch

View in context: https://bugs.webkit.org/attachment.cgi?id=236293&action=review

r=me with a few nits.

Thanks!

> Source/WebCore/html/shadow/MediaControlElements.cpp:1243
> +        toVTTCue(cue)->shouldChange();

The call to setFontSize should set m_displayTreeShouldChange automatically.

> Source/WebCore/html/track/TextTrackCueGeneric.cpp:87
> +            setInlineStyleProperty(CSSPropertyWidth, std::min(size * multiplier, 100.0f), CSSPrimitiveValue::CSS_PERCENTAGE);

Nit:The "f" isn't necessary, "100.0" should be sufficient.

> Source/WebCore/html/track/TextTrackCueGeneric.cpp:89
> +            setInlineStyleProperty(CSSPropertyHeight, std::min(size * multiplier, 100.0f),  CSSPrimitiveValue::CSS_PERCENTAGE);

Ditto.

> Source/WebCore/html/track/VTTCue.cpp:176
> +        setInlineStyleProperty(CSSPropertyWidth, std::min(static_cast<float>(m_cue.getCSSSize() * multiplier), 100.0f), CSSPrimitiveValue::CSS_PERCENTAGE);

Ditto.

> Source/WebCore/html/track/VTTCue.cpp:184
> +        setInlineStyleProperty(CSSPropertyMaxHeight, 100.0 - position.second, CSSPrimitiveValue::CSS_PERCENTAGE);

Ditto.
Comment 3 Roger Fong 2014-08-08 13:11:53 PDT
Landed: http://trac.webkit.org/changeset/172351
Comment 4 Alexey Proskuryakov 2014-08-08 14:42:32 PDT
*** Bug 135720 has been marked as a duplicate of this bug. ***