[Webkit-unassigned] [Bug 34405] MediaControlTimeDisplayElement should defer time formatting to the theme

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jan 31 20:53:04 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=34405


Nick Young <nicholas.young at nokia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #47811|                            |review?, commit-queue?
               Flag|                            |




--- Comment #1 from Nick Young <nicholas.young at nokia.com>  2010-01-31 20:53:03 PST ---
Created an attachment (id=47811)
 --> (https://bugs.webkit.org/attachment.cgi?id=47811)
Initial Patch

This patch addresses the problem by introducing three new virtual methods to
RenderTheme:

virtual String formatMediaControlsTime(float time);
virtual String formatMediaControlsCurrentTime(float currentTime, float
duration);
virtual String formatMediaControlsRemainingTime(float currentTime, float
duration);

The first method can be reimplemented by those only wishing to change how the
times are formatted.
The latter two methods can be reimplemented by those wishing to change what
times are shown in each element.

The motivating use case for this patch is to hide the time remaining element
and augment the current time element -

String RenderThemeXX::formatMediaCurrentTime(float currentTime, float duration)
{
    return formatMediaTime(currentTime) + " / " + formatMediaTime(duration);
}

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list