inline-table wrapper should be generated for display: inline element only
https://bugs.webkit.org/show_bug.cgi?id=92054

Reviewed by Abhishek Arya.

Source/WebCore:

CSS 2.1 only takes into account the display when determining if we should generate
an inline-table. My misreading of the spec would make us generate an inline-table
wrapper for any inline formatting context.

Test: fast/table/inline-block-generates-table-wrapper.html

* rendering/RenderTable.cpp:
(WebCore::RenderTable::createAnonymousWithParentRenderer):
Changed to use display instead of isInline to properly match the spec.

LayoutTests:

For some reason, using dumpAsText didn't dump the 2 lines properly so the test
is a reftest to work-around that.

* fast/table/inline-block-generates-table-wrapper-expected.html: Added.
* fast/table/inline-block-generates-table-wrapper.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123492 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium/mac] Remove webcore_resource_files from WebCore.gypi
https://bugs.webkit.org/show_bug.cgi?id=92129

Reviewed by Adam Barth.

It was added in http://trac.webkit.org/changeset/81706/trunk/Source/WebCore/WebCore.gypi .
The changes in that revision were mostly reverted in http://trac.webkit.org/changeset/119921 ,
but this block was forgotten. Since it just confused me for a bit, remove it.

* WebCore.gyp/WebCore.gyp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123493 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: Snippets UI polish
https://bugs.webkit.org/show_bug.cgi?id=92142

Reviewed by Pavel Feldman.

Changed snippets context menu items.
Added run snippet status bar button.
Removed unused edit source button.

* English.lproj/localizedStrings.js:
* inspector/front-end/Images/statusbarButtonGlyphs.png:
* inspector/front-end/ScriptSnippetModel.js:
(WebInspector.SnippetJavaScriptSourceFrame):
(WebInspector.SnippetJavaScriptSourceFrame.prototype.statusBarItems):
(WebInspector.SnippetJavaScriptSourceFrame.prototype._runButtonClicked):
* inspector/front-end/ScriptsNavigator.js:
(WebInspector.SnippetsNavigatorView.prototype.getOrCreateFolderTreeElement):
(WebInspector.SnippetsNavigatorView.prototype.handleContextMenu):
* inspector/front-end/ScriptsPanel.js:
(WebInspector.ScriptsPanel.prototype._updateScriptViewStatusBarItems):
(WebInspector.ScriptsPanel.prototype._createSourceFrame):
* inspector/front-end/SourceFrame.js:
(WebInspector.SourceFrame.prototype.statusBarItems):
* inspector/front-end/inspector.css:
* inspector/front-end/scriptsPanel.css:
(.evaluate-snippet-status-bar-item .glyph):
(.evaluate-snippet-status-bar-item.toggled .glyph):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123494 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Files from drag and file <input> should use getMIMETypeForExtension to determine content type.
https://bugs.webkit.org/show_bug.cgi?id=91702

Reviewed by Jian Li.

Awhile back, we changed File to only use getWellKnownMIMETypeForExtension to prevent web
pages from being able to detect what applications a user has installed indirectly through
the MIME types. However, some sites like YouTube's drag and drop uploader use MIME types
that aren't in WebKit's internal list, so we relax the restriction for Files that originate
from an user action.

* fileapi/File.cpp:
(WebCore::getContentTypeFromFileName):
(WebCore::createBlobDataForFile):
(WebCore::createBlobDataForFileWithName):
(WebCore::createBlobDataForFileWithMetadata):
(WebCore::File::createWithRelativePath):
(WebCore::File::File):
* fileapi/File.h:
(File):
(WebCore::File::create):
(WebCore::File::createWithName):
* html/FileInputType.cpp:
(WebCore::FileInputType::createFileList):
* platform/chromium/ChromiumDataObject.cpp:
(WebCore::ChromiumDataObject::addFilename):
* platform/gtk/ClipboardGtk.cpp:
(WebCore::ClipboardGtk::files):
* platform/mac/ClipboardMac.mm:
(WebCore::ClipboardMac::files):
* platform/qt/ClipboardQt.cpp:
(WebCore::ClipboardQt::files):
* platform/win/ClipboardWin.cpp:
(WebCore::ClipboardWin::files):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123495 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Use native (non-cygwin) binaries for perl, gperf, and bison in Chromium
https://bugs.webkit.org/show_bug.cgi?id=91667

Patch by Scott Graham <scottmg@chromium.org> on 2012-07-24
Reviewed by Tony Chang.

Using native tools instead of cygwin version improves build time
performance by roughly 50% (on top of previous cl-instead-of-gcc
change).

Also, use - instead of / for cl flags, otherwise preprocessing fails
very slowly (due to retry loop). And, replace \ with / in gperf
command line. Without this, gperf emits the filename literally in
#line directives which causes VS to error with "unescaped \ in
string". Bizarrely, building ColorData.cpp with those \ in place
causes the IDE to exit with no error message, which was the cause of
the previous canary failures.

No new tests.

* WebCore.gyp/WebCore.gyp:
* WebCore.gyp/scripts/rule_bison.py:
* bindings/scripts/preprocessor.pm:
(applyPreprocessor):
* make-hash-tools.pl:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123496 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed expectations change for chromium to address lint error from r90190.

* platform/chromium/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123497 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix regressions in replay performance tests
https://bugs.webkit.org/show_bug.cgi?id=92052

Reviewed by Dirk Pranke.

Fix regression that accumulated over time to make replay tests work again.

* DumpRenderTree/chromium/WebViewHost.cpp:
(WebViewHost::willSendRequest): Use the main document URL in the request since the main frame's
URL hadn't been updated yet When requesting a new URL on the main frame.
* Scripts/webkitpy/performance_tests/perftest.py:
(ReplayServer.wait_until_ready): Waiting for 6 seconds (3 tries) seems enough.
(ReplayPerfTest.prepare): Pass self._archive_path to run_signle as that is the current contract.
(ReplayPerfTest.run_single): Use the archive path to generate -expected.png path.
* Scripts/webkitpy/performance_tests/perftest_unittest.py:
(TestReplayPerfTest.test_run_single):
(TestReplayPerfTest.test_prepare):
(TestReplayPerfTest.test_prepare_calls_run_single.run_single):
(TestReplayPerfTest):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123498 268f45cc-cd09-0410-ab3c-d52691b4dbfc
MediaStream API: Update MediaStreamTrack to match the specification
https://bugs.webkit.org/show_bug.cgi?id=90180

Reviewed by Adam Barth.

Source/Platform:

* chromium/public/WebMediaStreamDescriptor.h:
(WebMediaStreamDescriptor):
* chromium/public/WebMediaStreamSource.h:
(WebMediaStreamSource):

Source/WebCore:

MediaStreamTracks are now required to show the status of the underlying source,
and trigger events when that status changes.

Test: fast/mediastream/MediaStreamTrack.html

* GNUmakefile.list.am:
* Modules/mediastream/MediaStream.cpp:
(WebCore::MediaStream::MediaStream):
(WebCore::MediaStream::addTrack):
* Modules/mediastream/MediaStreamTrack.cpp:
(WebCore::MediaStreamTrack::create):
(WebCore::MediaStreamTrack::MediaStreamTrack):
(WebCore::MediaStreamTrack::~MediaStreamTrack):
(WebCore::MediaStreamTrack::setEnabled):
(WebCore::MediaStreamTrack::readyState):
(WebCore):
(WebCore::MediaStreamTrack::sourceChangedState):
(WebCore::MediaStreamTrack::stop):
(WebCore::MediaStreamTrack::interfaceName):
(WebCore::MediaStreamTrack::scriptExecutionContext):
(WebCore::MediaStreamTrack::eventTargetData):
(WebCore::MediaStreamTrack::ensureEventTargetData):
* Modules/mediastream/MediaStreamTrack.h:
* Modules/mediastream/MediaStreamTrack.idl:
* WebCore.gypi:
* dom/EventNames.h:
(WebCore):
* dom/EventTargetFactory.in:
* platform/chromium/support/WebMediaStreamDescriptor.cpp:
* platform/chromium/support/WebMediaStreamSource.cpp:
(WebKit::WebMediaStreamSource::setReadyState):
(WebKit):
(WebKit::WebMediaStreamSource::readyState):
* platform/mediastream/MediaStreamSource.cpp: Copied from Source/WebCore/platform/mediastream/MediaStreamSource.h.
(WebCore):
(WebCore::MediaStreamSource::create):
(WebCore::MediaStreamSource::MediaStreamSource):
(WebCore::MediaStreamSource::setReadyState):
(WebCore::MediaStreamSource::addObserver):
(WebCore::MediaStreamSource::removeObserver):
* platform/mediastream/MediaStreamSource.h:
(Observer):
(WebCore::MediaStreamSource::Observer::~Observer):
(MediaStreamSource):
(WebCore::MediaStreamSource::readyState):
* platform/mediastream/chromium/MediaStreamCenterChromium.cpp:
(WebCore::MediaStreamCenterChromium::queryMediaStreamSources):
(WebCore::MediaStreamCenterChromium::didCreateMediaStream):

Tools:

Adding a Mock WebMediaStreamCenter to enable better LayoutTests.

* DumpRenderTree/DumpRenderTree.gypi:
* DumpRenderTree/chromium/MockWebKitPlatformSupport.cpp:
(MockWebKitPlatformSupport::createMediaStreamCenter):
* DumpRenderTree/chromium/MockWebMediaStreamCenter.cpp: Added.
(WebKit):
(WebKit::MockWebMediaStreamCenter::MockWebMediaStreamCenter):
(WebKit::MockWebMediaStreamCenter::queryMediaStreamSources):
(WebKit::MockWebMediaStreamCenter::didEnableMediaStreamTrack):
(WebKit::MockWebMediaStreamCenter::didDisableMediaStreamTrack):
(WebKit::MockWebMediaStreamCenter::didStopLocalMediaStream):
(WebKit::MockWebMediaStreamCenter::didCreateMediaStream):
(WebKit::MockWebMediaStreamCenter::constructSDP):
* DumpRenderTree/chromium/MockWebMediaStreamCenter.h: Copied from Tools/DumpRenderTree/chromium/MockWebKitPlatformSupport.cpp.
(WebKit):
(MockWebMediaStreamCenter):
(WebKit::MockWebMediaStreamCenter::MockWebMediaStreamCenter):

LayoutTests:

* fast/mediastream/MediaStreamTrack-expected.txt: Added.
* fast/mediastream/MediaStreamTrack.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@123499 268f45cc-cd09-0410-ab3c-d52691b4dbfc