Confusing CGImageRef memory management in ImageBuffer::copyImage
https://bugs.webkit.org/show_bug.cgi?id=122605

Source/WebCore:

BitmapImage::create was adopting the CGImage passed into it, which
resulted in some strange contortions in ImageBuffer::copyImage that
made it look like it was leaking CGImages, when in fact it was just
relying on BitmapImage to adopt the extra references.

BitmapImage::create now retains the passed-in CGImage, and I updated
the two callers to it to expect that (one here, one in WebKit2). I
also changed ImageBuffer::copyNativeImage to return a RetainPtr to
reduce the number of adoptCF()s needed and make it harder to make
programming mistakes.

Reviewed by Simon Fraser.

No new tests because this is just a code cleanup.

* platform/graphics/ImageBuffer.h: Changed copyNativeImage to return a
RetainPtr<CGImageRef.

* platform/graphics/cg/BitmapImageCG.cpp:
(WebCore::BitmapImage::BitmapImage): Adopt the passed-in CGImage,
since we're taking ownership of it. (We release it in
FrameData::clear.)

* platform/graphics/cg/ImageBufferCG.cpp:
(WebCore::ImageBuffer::copyImage): Updated for copyNativeImage's new
return type and to take into account BitmapImage::create's new
retaining semantics. This makes this function not have to be so clever
about retain counts.

(WebCore::ImageBuffer::copyNativeImage): Changed to return a
RetainPtr<CGImageRef>.

(WebCore::ImageBuffer::draw):
(WebCore::ImageBuffer::clip):
(WebCore::ImageBuffer::putByteArray):
(WebCore::ImageBuffer::toDataURL):
Updated for changes to copyNativeImage.

Source/WebKit2:

Reviewed by Simon Fraser.

* Shared/cg/ShareableBitmapCG.cpp:
(WebKit::ShareableBitmap::createImage): BitmapImage::create now
retains the passed-in CGImage, so we don't need to dance around it
anymore. Also changed to use nullptr instead of 0 while I was in here.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157310 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LeaksViewer fails to present recent results list if current build is still updating svn
https://bugs.webkit.org/show_bug.cgi?id=122670

Reviewed by Adam Roben.

* BuildSlaveSupport/build.webkit.org-config/public_html/LeaksViewer/RecentBuildsLoader.js:
(RecentBuildsLoader.prototype.start): Skip builds that don't have an svn revision yet.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157311 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LeaksViewer fails to present recent results list if current build is still updating svn
https://bugs.webkit.org/show_bug.cgi?id=122670

Fixed an obvious mistake in the previous patch.

* BuildSlaveSupport/build.webkit.org-config/public_html/LeaksViewer/RecentBuildsLoader.js:
(RecentBuildsLoader.prototype.start):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157312 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Transition op_new_* JITStubs to JIT operations.
https://bugs.webkit.org/show_bug.cgi?id=122460.

Reviewed by Michael Saboff.

Also:
- Removed the redundant operationNewFunctionExpression().  It is identical to
  operationNewFunctionNoCheck().
- Sorted JIT operation signature keys in the comment in JITOperations.h.
- Removed the unused returnValue2Register definition for X86_64.

* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileNewFunctionExpression):
* jit/CCallHelpers.h:
(JSC::CCallHelpers::setupArgumentsWithExecState):
* jit/JIT.h:
* jit/JITInlines.h:
(JSC::JIT::callOperation):
* jit/JITOpcodes.cpp:
(JSC::JIT::emitSlow_op_new_object):
(JSC::JIT::emit_op_new_func):
(JSC::JIT::emit_op_new_func_exp):
(JSC::JIT::emit_op_new_array):
(JSC::JIT::emit_op_new_array_with_size):
(JSC::JIT::emit_op_new_array_buffer):
* jit/JITOpcodes32_64.cpp:
(JSC::JIT::emitSlow_op_new_object):
* jit/JITOperations.cpp:
* jit/JITOperations.h:
* jit/JITStubs.cpp:
* jit/JITStubs.h:
* jit/JSInterfaceJIT.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157313 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove some dead code from PlatformCALayer*
https://bugs.webkit.org/show_bug.cgi?id=122641

Reviewed by Anders Carlsson.

Remove some unused getters from PlatformCALayer and its implementations.

No new tests, just removing dead code.

* platform/graphics/ca/PlatformCALayer.h:
* platform/graphics/ca/mac/PlatformCALayerMac.mm:
* platform/graphics/ca/win/PlatformCALayerWin.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157314 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed gardening. Rebaseline after 157292.

* platform/gtk/editing/unsupported-content/table-delete-001-expected.txt:
* platform/gtk/editing/unsupported-content/table-delete-003-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157315 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove gesture event support from WebCore
https://bugs.webkit.org/show_bug.cgi?id=122650

Reviewed by Ryosuke Niwa.

Source/WebCore:

* CMakeLists.txt:
* GNUmakefile.list.am:
* WebCore.exp.in:
* WebCore.xcodeproj/project.pbxproj:
* dom/GestureEvent.cpp: Removed.
* dom/GestureEvent.h: Removed.
* dom/Node.cpp:
* dom/Node.h:
* page/EventHandler.cpp:
(WebCore::EventHandler::EventHandler):
(WebCore::EventHandler::clear):
(WebCore::EventHandler::sendContextMenuEventForKey):
* page/EventHandler.h:
* platform/PlatformGestureEvent.h: Removed.
* platform/Scrollbar.cpp:
* platform/Scrollbar.h:
* platform/mac/PlatformEventFactoryMac.h:
* platform/mac/PlatformEventFactoryMac.mm:

Source/WTF:

* wtf/FeatureDefines.h:
* wtf/nix/FeatureDefinesNix.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157316 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r157307.
http://trac.webkit.org/changeset/157307
https://bugs.webkit.org/show_bug.cgi?id=122671

Many assertion failures (Requested by ap on #webkit).

* jit/ThunkGenerators.cpp:
(JSC::arrayIteratorNextThunkGenerator):
* jit/ThunkGenerators.h:
* runtime/ArrayIteratorPrototype.cpp:
(JSC::ArrayIteratorPrototype::finishCreation):
(JSC::createIteratorResult):
(JSC::arrayIteratorPrototypeNext):
* runtime/Intrinsic.h:
* runtime/JSArrayIterator.cpp:
(JSC::JSArrayIterator::finishCreation):
* runtime/VM.cpp:
(JSC::thunkGeneratorForIntrinsic):

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