Flash of white when exiting full screen HTML5 video
https://bugs.webkit.org/show_bug.cgi?id=85438

.:

Reviewed by Sam Weinig.

* ManualTests/fullscreen/full-screen-flash.html: Added.

Source/WebKit2:

Reviewed by Maciej Stachowiak.

Force a repaint before displaying the newly exited WebView window.  This gives the window
a chance to seamlessly repaint before enabling screen updates.

Also, send the WebProcess the didExitFullScreen and setAnimatingFullScreen(false) messages
after swapping the WebView back into its original window. Doing otherwise seems to cause
forceRepaint to paint a white frame.

* UIProcess/mac/WKFullScreenWindowController.mm:
(-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
(-[WKFullScreenWindowController completeFinishExitFullScreenAnimationAfterRepaint]):
(completeFinishExitFullScreenAnimationAfterRepaint):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116188 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add "combining short stroke overlay character (u0335)" to lookalike characters blacklist.
https://bugs.webkit.org/show_bug.cgi?id=85440

Patch by Yongjun Zhang <yongjun_zhang@apple.com> on 2012-05-04
Reviewed by David Kilzer.

We should add u0335 to the characters blacklist.

* platform/mac/WebCoreNSURLExtras.mm:
(WebCore::isLookalikeCharacter):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116189 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] enable msvs_error_on_missing_sources at gyp time
https://bugs.webkit.org/show_bug.cgi?id=85683

Reviewed by Adam Barth.

This flag checks for missing files, which cause compile times to be
slow on Windows. Since this flag is on by default for the
build.chromium.org bots, we should add it here too so everyone can fix
these errors.

* DEPS: Roll to a chromium version that has no missing files.
* gyp_webkit: Add the flag.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116190 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Prevent early EventListener deletion
https://bugs.webkit.org/show_bug.cgi?id=73970

Reviewed by Oliver Hunt.

Source/WebCore:

Test: fast/events/attribute-listener-deletion-crash.html

* bindings/js/JSEventListener.h:
(WebCore::JSEventListener::jsFunction):

LayoutTests:

* fast/events/attribute-listener-deletion-crash-expected.txt: Added.
* fast/events/attribute-listener-deletion-crash.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116191 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION: Cursor jumps to the first line after deleting the last word.
https://bugs.webkit.org/show_bug.cgi?id=85334
<rdar://problem/11210059>

Reviewed by Ryosuke Niwa.

Source/WebCore: 

This regression was introduced with the work to remove redundant divs.
When we decide to remove a DIV, we need to adjust the selection, if it is
expressed in terms of the node being removed. The new position was computed
using updatePositionForNodeRemoval that was not designed for the case where we
remove preserving children.
This patch adds a new method to CompositeEditCommand to do this properly.
        
Test: editing/deleting/delete-word-from-unstyled-div.html

* editing/CompositeEditCommand.cpp:
(WebCore::CompositeEditCommand::isRemovableBlock): Code clenup.
(WebCore::CompositeEditCommand::updatePositionForNodeRemovalPreservingChildren): Added.
 * editing/CompositeEditCommand.h:
* editing/DeleteSelectionCommand.cpp:
(WebCore::DeleteSelectionCommand::removeRedundantBlocks): Uses updatePositionForNodeRemovalPreservingChildren.

LayoutTests: 

* editing/deleting/delete-word-from-unstyled-div-expected.txt: Added.
* editing/deleting/delete-word-from-unstyled-div.html: Added.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116192 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Make capitalization and descriptions in FeatureList.pm more consistent to make easier to autogenerate
https://bugs.webkit.org/show_bug.cgi?id=85583

Reviewed by Daniel Bates.

* Scripts/webkitperl/FeatureList.pm:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116193 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed; build fix after r116191.

* bindings/js/JSEventListener.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116194 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Changes to layer tree structure need to be tracked properly
https://bugs.webkit.org/show_bug.cgi?id=85421

Reviewed by Adrienne Walker.

Unit test added: TreeSynchronizerTest.syncSimpleTreeAndTrackStackingOrderChange

Source/WebCore:

Earlier, we were relying on WebCore behavior that always called
setNeedsDisplay whenever the layer tree structure changed.
However, in general it is more correct to consider layer tree
changes even when things don't need repainting; for example Aura
code is encountring this bug now. This patch corrects the
compositor so that layer tree structural changes are considered
property changes, without requiring that layers needed to be
repainted.

* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::LayerChromium):
(WebCore::LayerChromium::insertChild):
(WebCore::LayerChromium::pushPropertiesTo):
* platform/graphics/chromium/LayerChromium.h:
(LayerChromium):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::setStackingOrderChanged):
(WebCore):
* platform/graphics/chromium/cc/CCLayerImpl.h:
(CCLayerImpl):

Source/WebKit/chromium:

* tests/TreeSynchronizerTest.cpp:
(WebKitTests):
(WebKitTests::TEST):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116195 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CG] Minor refactor of ImageBuffer::CGImageToDataURL and its callers
https://bugs.webkit.org/show_bug.cgi?id=85280

Reviewed by Kenneth Russell.

This patch means to simplify the diff of an upcoming patch. Refactoring
here in preparation for that patch.

No new tests. No behavioral change. Covered by canvas 2d and 3d tests:
  canvas/philip/tests/*toDataURL*.html
  fast/canvas/webgl/premultiplyalpha-test.html

* platform/graphics/cg/ImageBufferCG.cpp:
(WebCore::CGImageToDataURL): Move the invalid image (!image) test here.
The comments are about JPEG images; say that. Rename out to base64Data.
(WebCore::ImageBuffer::toDataURL): Remove the !image test.
(WebCore::ImageDataToDataURL): Move and define variables where used and
make the code flow read similarly to toDataURL. Remove the !image test.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116196 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Rebaseline chromium after r116069 (bug 85031)
https://bugs.webkit.org/show_bug.cgi?id=85626

Patch by David Barr <davidbarr@chromium.org> on 2012-05-04
Reviewed by Ojan Vafai.

* fast/block/float/016-expected.txt: Renamed from LayoutTests/platform/efl/fast/block/float/016-expected.txt.
* platform/chromium-linux/fast/block/float/016-expected.png:
* platform/chromium-linux/fast/css/border-solid-single-edge-antialias-expected.png: Added.
* platform/chromium-mac-leopard/fast/block/float/016-expected.png:
* platform/chromium-mac-snowleopard/fast/block/float/016-expected.png:
* platform/chromium-mac/fast/block/float/016-expected.png:
* platform/chromium-win/fast/block/float/016-expected.png:
* platform/chromium-win/fast/css/border-solid-single-edge-antialias-expected.png: Added.
* platform/chromium/test_expectations.txt:
* platform/gtk/fast/block/float/016-expected.txt: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116197 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove uses of ASSERT(false)
https://bugs.webkit.org/show_bug.cgi?id=85686

Reviewed by Dean Jackson.

Replace uses of ASSERT(false) with ASSERT_NOT_REACHED(). Also, in two places, there was code structured like:

if (expr) {
    // do something
} else {
    ASSERT(false);
}

Replace this with:

ASSERT(expr);
if (!expr)
    return;

// do something

* Modules/webdatabase/DatabaseTracker.cpp:
(WebCore::DatabaseTracker::deleteOrigin):
(WebCore::DatabaseTracker::doneCreatingDatabase):
(WebCore::DatabaseTracker::doneDeletingDatabase):
(WebCore::DatabaseTracker::deleteDatabase):
* bridge/objc/objc_instance.mm:
(ObjcInstance::invokeObjcMethod):
* bridge/objc/objc_utility.mm:
(JSC::Bindings::convertObjcValueToValue):
(JSC::Bindings::objcValueTypeForType):
* dom/Node.cpp:
(WebCore::Node::createRenderer):
* loader/icon/IconDatabase.cpp:
(WebCore::IconDatabase::setIconURLForPageURLInSQLDatabase):
(WebCore::IconDatabase::setIconIDForPageURLInSQLDatabase):
* platform/graphics/GraphicsContext3D.cpp:
(WebCore::doPacking):
* platform/text/BidiResolver.h:
(WebCore::::createBidiRunsForLine):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116198 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Blackberry] Implement over-scroll background image
https://bugs.webkit.org/show_bug.cgi?id=85538

Patch by Andrew Lo <anlo@rim.com> on 2012-05-04
Reviewed by Rob Buis.

Use over-scroll image when set instead of the solid colour.
Internal PR146652

* Api/BackingStore.cpp:
(WebKit):
(BlackBerry::WebKit::BackingStorePrivate::ensureOverScrollImage):
(BlackBerry::WebKit::BackingStorePrivate::paintDefaultBackground):
* Api/BackingStore_p.h:
(BackingStorePrivate):
* Api/WebSettings.cpp:
(WebKit):
(BlackBerry::WebKit::WebSettings::standardSettings):
(BlackBerry::WebKit::WebSettings::overScrollImagePath):
(BlackBerry::WebKit::WebSettings::setOverScrollImagePath):
* Api/WebSettings.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116199 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix a leak in WebProcess when it is used to launch the UI process.

Rubber-stamped by Anders Carlsson.

* WebProcess/mac/WebProcessMainMac.mm:
(WebKit::WebProcessMain): Destory the attributes and file actions after
spawning the subprocess.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116200 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Oscillator must implement noteOn() and noteOff()
https://bugs.webkit.org/show_bug.cgi?id=85236

Reviewed by Kenneth Russell.

Source/WebCore:

Test: webaudio/oscillator-scheduling.html
to be landed separately to get proper platform baselines

* Modules/webaudio/AudioBufferSourceNode.cpp:
(WebCore::AudioBufferSourceNode::process):
Simplify/remove zeroing-out silence at end of buffer, since it's now handled in the base-class AudioScheduledSourceNode::updateSchedulingInfo().

* Modules/webaudio/AudioContext.cpp:
(WebCore::AudioContext::createBufferSource):
Improve comment about ownership and dynamic-lifetime of AudioBufferSourceNode.

(WebCore::AudioContext::createOscillator):
AudioContext keeps a reference to the Oscillator and that reference is released in AudioScheduledSourceNode,
when it has finished playing.

* Modules/webaudio/AudioScheduledSourceNode.h:
* Modules/webaudio/AudioScheduledSourceNode.cpp:
(WebCore::AudioScheduledSourceNode::updateSchedulingInfo):
updateSchedulingInfo() is now responsible for zeroing out the very start (before a note starts)
and the very end (after note ends) of the output AudioBus.  We've also simplified the number
of arguments passed to this method, because of this. It now handles playbackState transition to FINISHED_STATE.

* Modules/webaudio/Oscillator.cpp:
(WebCore::Oscillator::Oscillator):
(WebCore::Oscillator::calculateSampleAccuratePhaseIncrements):
The frequency value needs to snap immediately to its correct value the very first time.
This bug needs to be fixed here so that the Oscillator layout scheduling test works correctly.

(WebCore::Oscillator::process):
Since Oscillator in now changing to be a AudioScheduledSourceNode, we need to call AudioScheduledSourceNode::updateSchedulingInfo()
to handle playbackState for us.

(WebCore::Oscillator::propagatesSilence):
Add scheduling logic for propagatesSilence().

(Oscillator):
* Modules/webaudio/Oscillator.idl:
Add noteOn(), noteOff() methods and playbackState according to specification.

LayoutTests:

* webaudio/oscillator-scheduling-expected.wav: Added.
* webaudio/resources/oscillator-testing.js:
(generateExponentialOscillatorSweep):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116201 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove InlineBox::next()
https://bugs.webkit.org/show_bug.cgi?id=85668

Reviewed by Nikolas Zimmermann.

InlineBox::next() not needed since nextOnLine() does the same.

* rendering/InlineBox.h:
(InlineBox):
* rendering/InlineFlowBox.h:
(WebCore::InlineFlowBox::setConstructed):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116202 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Leaf non self-painting layers should bail out early in RenderLayer::paintLayer
https://bugs.webkit.org/show_bug.cgi?id=85678

Reviewed by Darin Adler.

Performance optimization, no expected change in behavior.

The gist of the change is that leaf non self-painting layers don't need to be painted as their
associated RenderBoxModelObject should properly paint itself without any help.

For RenderLayer trees that have a large number of leafs nodes (like a table with a leaf RenderLayer for
each cells), not bailing out is a big overhead as it ends up doing a lot of computation for no real
painting. See http://dglazkov.github.com/performance-tests/biggrid.html for a benchmark for that. On
my machine, it reduces the paint time when scrolling to 70ms from 120ms (45% speedup).

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::paintLayer):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116203 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Rename ICULocale to LocaleICU, part 1
https://bugs.webkit.org/show_bug.cgi?id=85688

Reviewed by Kentaro Hara.

Source/WebCore:

Rename it for consistency. Our convention is Foo<Platform>.{cpp,h}.
This patch changes only file names. We'll rename ICULocale class
by a following patch.

No behavior changes.

* WebCore.gypi:
* platform/text/LocaleICU.cpp: Renamed from Source/WebCore/platform/text/ICULocale.cpp.
* platform/text/LocaleICU.h: Renamed from Source/WebCore/platform/text/ICULocale.h.
* platform/text/LocalizedDateICU.cpp: Rename ICULocale.h to LocaleICU.h.
* platform/text/LocalizedNumberICU.cpp: ditto.

Source/WebKit/chromium:

* tests/LocalizedNumberICUTest.cpp: Rename ICULocale.h to LocaleICU.h.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116204 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Simplify how libWebCoreModules is linked in, and fix WebKit2 build
https://bugs.webkit.org/show_bug.cgi?id=85691

Source/WebCore:

* GNUmakefile.am: link libWebCoreModules into libWebCore.

Source/WebKit/gtk:

* GNUmakefile.am: no longer link libwebkitgtk to libWebCoreModules.

Source/WebKit2:

* GNUmakefile.am: no longer link libWebCoreModules, and remove -no-
fast-install and -no-install from link flags, since we want those
programs installed.

Tools:

* GNUmakefile.am: no longer link libWebCoreModules to DumpRenderTree.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116205 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Unreviewed, rebaseline after r116009.

* platform/efl/fast/block/float/float-not-removed-from-next-sibling4-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@116206 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Gardening; skip tests that depend on beginDragWithFiles.

* platform/efl/Skipped:

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