WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
100249
Add setMediaTypeOverride to window.internals.settings
https://bugs.webkit.org/show_bug.cgi?id=100249
Summary
Add setMediaTypeOverride to window.internals.settings
Mikhail Pozdnyakov
Reported
2012-10-24 07:26:20 PDT
WebKitTestRunner needs testRunner.setMediaType as it's used in fast/media/print-restores-previous-mediatype.html.
Attachments
patch
(9.28 KB, patch)
2012-10-25 01:58 PDT
,
Mikhail Pozdnyakov
kenneth
: review+
buildbot
: commit-queue-
Details
Formatted Diff
Diff
patch v2
(12.65 KB, patch)
2012-10-25 05:47 PDT
,
Mikhail Pozdnyakov
kenneth
: review+
gtk-ews
: commit-queue-
Details
Formatted Diff
Diff
patch v3
(12.66 KB, patch)
2012-10-25 06:26 PDT
,
Mikhail Pozdnyakov
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Kenneth Rohde Christiansen
Comment 1
2012-10-24 07:31:12 PDT
It is better to convert it to a window.internals.settings like setMediaTypeOverride, that also makes it cross platform
Mikhail Pozdnyakov
Comment 2
2012-10-25 01:58:42 PDT
Created
attachment 170590
[details]
patch
Kenneth Rohde Christiansen
Comment 3
2012-10-25 02:00:36 PDT
Comment on
attachment 170590
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=170590&action=review
> Source/WebCore/page/Settings.cpp:128 > + , m_mediaTypeOverride("screen")
why not pick the current one? Some ports might change it.
Kenneth Rohde Christiansen
Comment 4
2012-10-25 02:01:39 PDT
Comment on
attachment 170590
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=170590&action=review
>> Source/WebCore/page/Settings.cpp:128 >> + , m_mediaTypeOverride("screen") > > why not pick the current one? Some ports might change it.
or say someone does this while printing? then it will be 'print'
> Source/WebCore/page/Settings.cpp:484 > + mainFrame->document()->styleResolverChanged(RecalcStyleImmediately); > + view->layout();
I think the setDeviceScaleFactor does this slightly different
Build Bot
Comment 5
2012-10-25 02:30:22 PDT
Comment on
attachment 170590
[details]
patch
Attachment 170590
[details]
did not pass win-ews (win): Output:
http://queues.webkit.org/results/14569516
kov's GTK+ EWS bot
Comment 6
2012-10-25 03:34:15 PDT
Comment on
attachment 170590
[details]
patch
Attachment 170590
[details]
did not pass gtk-ews (gtk): Output:
http://queues.webkit.org/results/14559585
Kenneth Rohde Christiansen
Comment 7
2012-10-25 04:45:01 PDT
Comment on
attachment 170590
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=170590&action=review
> LayoutTests/fast/media/print-restores-previous-mediatype.html:8 > if (window.testRunner) {
shouldnt we check for internals as well?
>> Source/WebCore/page/Settings.cpp:484 >> + view->layout(); > > I think the setDeviceScaleFactor does this slightly different
setNeedsRecalcStyleInAllFrames(); m_page->pageCache()->markPagesForFullStyleRecalc(m_page); This is what setDeviceScaleFactor does, I am not sure of the exact difference
Kenneth Rohde Christiansen
Comment 8
2012-10-25 04:49:19 PDT
> setNeedsRecalcStyleInAllFrames();
> m_page->pageCache()->markPagesForFullStyleRecalc(m_page);
I think this boils down to whether this is supposed to affect globally (ie. change things in cache and everything alive), or just the page. What does other settings do?
Mikhail Pozdnyakov
Comment 9
2012-10-25 05:17:41 PDT
(In reply to
comment #8
)
> > setNeedsRecalcStyleInAllFrames(); > > > m_page->pageCache()->markPagesForFullStyleRecalc(m_page); > > I think this boils down to whether this is supposed to affect globally (ie. change things in cache and everything alive), or just the page. > > What does other settings do?
other settings live with just with setNeedsRecalcStyleInAllFrames, I do not think this should be applied to all pages
Mikhail Pozdnyakov
Comment 10
2012-10-25 05:47:21 PDT
Created
attachment 170620
[details]
patch v2 Changed the style update in Settings::setMediaTypeOverride, hopefully fixed build on MAC, WIN and GTK bots.
Kenneth Rohde Christiansen
Comment 11
2012-10-25 05:50:52 PDT
Comment on
attachment 170620
[details]
patch v2 why didnt you remove the dead qt code? isnt it dead?
Mikhail Pozdnyakov
Comment 12
2012-10-25 05:53:43 PDT
(In reply to
comment #11
)
> (From update of
attachment 170620
[details]
) > why didnt you remove the dead qt code? isnt it dead?
should be dead. would do it in a separate patch when this one lands..
kov's GTK+ EWS bot
Comment 13
2012-10-25 06:11:58 PDT
Comment on
attachment 170620
[details]
patch v2
Attachment 170620
[details]
did not pass gtk-ews (gtk): Output:
http://queues.webkit.org/results/14546619
Mikhail Pozdnyakov
Comment 14
2012-10-25 06:26:41 PDT
Created
attachment 170625
[details]
patch v3 another attempt, added missing ';' to symbols.filter
WebKit Review Bot
Comment 15
2012-10-25 07:04:12 PDT
Comment on
attachment 170625
[details]
patch v3 Clearing flags on attachment: 170625 Committed
r132480
: <
http://trac.webkit.org/changeset/132480
>
WebKit Review Bot
Comment 16
2012-10-25 07:04:18 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug