https://bugs.webkit.org/show_bug.cgi?id=97530
Regression, freeze applied to numeric properties of non-array objects

Reviewed by Filip Pizlo.

Object.freeze has a fast implementation in JSObject, but this hasn't been updated to take into account numeric properties in butterflies.
For now, just fall back to the generic implementation if the object has numeric properties.

Source/JavaScriptCore: 

* runtime/ObjectConstructor.cpp:
(JSC::objectConstructorFreeze):
    - fallback if the object has a non-zero indexed property vector length.

LayoutTests: 

* fast/js/preventExtensions-expected.txt:
* fast/js/script-tests/preventExtensions.js:
    - Added a test case for freezing an object with a numeric property.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129461 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Reland "Add in-place reload behavior to ImagesEnabled setting" with optimizations
https://bugs.webkit.org/show_bug.cgi?id=97055

Patch by Bo Liu <boliu@chromium.org> on 2012-09-24
Reviewed by Adam Barth.

Relanding 128780, 128676, 128645. Was reverted in 128914 due to
performance regression in Chromium.

New changes in addition to previously reverted patches:

Refactored CachedResource::requestResource, loadResource, and
revalidateResource. Moved CachedResource::load method to end of
requestResource so there is one place where load is called for all
resources.

Added a enum parameter for requestResource and
determineRevalidationPolicy so that FrameLoaderClient::allowImage call
do not need to be called multiple times.

Removed CachedImage::load call in requestImage so it is not called
twice.

Removed unnecessary Frame.h includes in CachedResource and
CachedImage.

Removed dead load() method declaration in CachedImage.

Updated text expectation for two image-permissions tests to reflect
the removed calls to allowImage.

.:

* Source/autotools/symbols.filter:

Source/WebCore:

Tests: fast/loader/display-image-unset-allows-cached-image-load.html
       fast/loader/display-image-unset-can-block-image-and-can-reload-in-place.html
       fast/loader/images-enabled-unset-can-block-image-and-can-reload-in-place.html

* WebCore.exp.in:
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::didBeginDocument):
* loader/SubresourceLoader.cpp:
(WebCore::SubresourceLoader::willSendRequest):
* loader/cache/CachedImage.cpp:
* loader/cache/CachedImage.h:
* loader/cache/CachedResource.cpp:
(WebCore::CachedResource::didAddClient):
* loader/cache/CachedResource.h:
(WebCore):
(WebCore::CachedResource::stillNeedsLoad):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::CachedResourceLoader):
(WebCore::CachedResourceLoader::requestImage):
(WebCore::CachedResourceLoader::canRequest):
(WebCore::CachedResourceLoader::requestResource):
(WebCore::CachedResourceLoader::revalidateResource):
(WebCore::CachedResourceLoader::loadResource):
(WebCore::CachedResourceLoader::determineRevalidationPolicy):
(WebCore::CachedResourceLoader::setAutoLoadImages):
(WebCore):
(WebCore::CachedResourceLoader::setImagesEnabled):
(WebCore::CachedResourceLoader::clientDefersImage):
(WebCore::CachedResourceLoader::shouldDeferImageLoad):
(WebCore::CachedResourceLoader::reloadImagesIfNotDeferred):
* loader/cache/CachedResourceLoader.h:
(CachedResourceLoader):
* page/Settings.cpp:
(WebCore::setImageLoadingSettings):
(WebCore::Settings::Settings):
(WebCore::Settings::setLoadsImagesAutomatically):
(WebCore::Settings::imageLoadingSettingsTimerFired):
(WebCore::Settings::setImagesEnabled):
* page/Settings.h:
(Settings):
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::Backup):
(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::setImagesEnabled):
(WebCore):
* testing/InternalSettings.h:
(Backup):
(InternalSettings):
* testing/InternalSettings.idl:

Source/WebKit2:

* win/WebKit2.def:

LayoutTests:

* fast/loader/display-image-unset-allows-cached-image-load-expected.txt: Added.
* fast/loader/display-image-unset-allows-cached-image-load.html: Added.
* fast/loader/display-image-unset-can-block-image-and-can-reload-in-place-expected.txt: Added.
* fast/loader/display-image-unset-can-block-image-and-can-reload-in-place.html: Added.
* fast/loader/images-enabled-unset-can-block-image-and-can-reload-in-place-expected.txt: Added.
* fast/loader/images-enabled-unset-can-block-image-and-can-reload-in-place.html: Added.
* fast/loader/resources/image1.html: Added.
* fast/loader/resources/image2.html: Added.
* platform/chromium/permissionclient/image-permissions-expected.txt:
* platform/chromium/permissionclient/image-permissions.html:
* platform/chromium/permissionclient/resources/image.html:
* platform/wk2/Skipped:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129462 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION(r129346): It broke !ENABLE(INSPECTOR) build
https://bugs.webkit.org/show_bug.cgi?id=97490

Patch by Vivek Galatage <vivekgalatage@gmail.com> on 2012-09-25
Reviewed by Csaba Osztrogonác.

The dummy class implementation must be under the ENABLE(INSPECTOR)
guard. Added them to prevent from braking the build with --minimal
option for build-webkit

No new tests as caused by missing compile guard.

* testing/Internals.cpp:
(WebCore):

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