2008-05-21 Geoffrey Garen Reviewed by Tim Hatcher. Merged with trunk WebCore's new debugger. * page/InspectorController.cpp: (WebCore::currentCallFrame): Updated to use the DebuggerCallFrame API. (WebCore::InspectorController::pauseInDebugger): Updated for name change explained below. (WebCore::InspectorController::resumeDebugger): ditto (WebCore::InspectorController::didParseSource): Fixed a bug that would produce garbled text in some cases: Don't treat JS source as null- terminated UTF8; it's UTF16. * page/JavaScriptCallFrame.cpp: * page/JavaScriptCallFrame.h: Changed this class to do all of its processing through a JavaScriptCore DebuggerCallFrame. We have to copy the DebuggerCallFrame because it's a temporary. (WebCore::JavaScriptCallFrame::update): Added an API for updating a call frame during execution: this is how we handle "with" and "eval". * page/JavaScriptDebugServer.cpp: Separated "m_paused" from "m_doneProcessingDebuggerEvents", because they have different semantics: "m_paused" is the flag the debug server uses to indicate that new debugger callbacks should be ignored, because they come from the debugger's own JS code; "m_doneProcessingDebuggerEvents" is the flag the debugger UI uses to indicate that it's done processing events, and would like execution to continue. When these flags were one, the debugger would erroneously process callbacks that ocurred while unwinding from its own JS code. (WebCore::toPage): Removed some unnecessary NULL checking. Added some missing NULL checking. (WebCore::JavaScriptDebugServer::pauseIfNeeded): Changed pause tracking to track a JavaScriptCallFrame instead of an ExecState, since ExecState is no longer a unique identifier for a call frame. I removed the updateCurrentCallFrame scheme, and replaced it with individual tracking inside these callbacks: (WebCore::JavaScriptDebugServer::callEvent): (WebCore::JavaScriptDebugServer::atStatement): (WebCore::JavaScriptDebugServer::returnEvent): (WebCore::JavaScriptDebugServer::exception): The updateCurrentCallFrame scheme was just too incompatible with the squirrelfish execution model. Everything still works as before, except for eval, which no longer shows up as an independent call frame. We'll need to augment our debugger callbacks to bring back support for that. * page/inspector/ScopeChainSidebarPane.js: Updated to use the activation class's new name. 2008-05-21 Maciej Stachowiak Reviewed by Oliver. - write directly to the slot we used to check for override properties, when possible 2.6% speedup on in-browser SunSpider * bindings/js/JSDOMWindowCustom.h: (WebCore::JSDOMWindow::customPut): 2008-05-20 Maciej Stachowiak Reviewed by Oliver. - inline JSDOMWindow security checks 0.9% speedup to SunSpider in-browser * bindings/js/JSDOMWindowBase.cpp: * bindings/js/JSDOMWindowCustom.h: (WebCore::JSDOMWindowBasePrivate::JSDOMWindowBasePrivate): (WebCore::JSDOMWindowBase::allowsAccessFrom): (WebCore::JSDOMWindowBase::allowsAccessFromNoErrorMessage): (WebCore::JSDOMWindowBase::allowsAccessFromPrivate): * bindings/js/kjs_binding.cpp: 2008-05-20 Maciej Stachowiak Reviewed by Adam. - use ALWAYS_INLINE on customGetOwnPropertySlot since it wasn't inlining 2% speedup to SunSpider in-browser * bindings/js/JSDOMWindowCustom.h: (WebCore::JSDOMWindow::customGetOwnPropertySlot): 2008-05-20 Maciej Stachowiak Reviewed by Adam. - inline JSDOMWindow's customPut and customGetOwnPropertySlot methods 1.2% speedup to SunSpider in-browser The approach here is to make the code generator include a JS{classname}Custom.h header in the autogenerated implementation, which we can use to provide inline versions. * bindings/js/JSCSSStyleDeclarationCustom.cpp: * bindings/js/JSCSSStyleDeclarationCustom.h: Added. * bindings/js/JSDOMWindowCustom.cpp: * bindings/js/JSDOMWindowCustom.h: (WebCore::asJSDOMWindow): (WebCore::JSDOMWindow::customGetOwnPropertySlot): (WebCore::JSDOMWindow::customPut): * bindings/js/JSHTMLAppletElementCustom.cpp: * bindings/js/JSHTMLAppletElementCustom.h: Added. * bindings/js/JSHTMLEmbedElementCustom.cpp: * bindings/js/JSHTMLEmbedElementCustom.h: Added. * bindings/js/JSHTMLObjectElementCustom.cpp: * bindings/js/JSHTMLObjectElementCustom.h: Added. * bindings/js/JSHistoryCustom.cpp: * bindings/js/JSHistoryCustom.h: Added. * bindings/js/JSLocationCustom.cpp: * bindings/js/JSLocationCustom.h: Added. * bindings/js/JSStorageCustom.cpp: * bindings/js/JSStorageCustom.h: Added. * bindings/scripts/CodeGeneratorJS.pm: 2008-05-19 Maciej Stachowiak Reviewed by Anders. - inline asDOMWindow (using a new JSDOMWindowCustom.h header) since it is just a cast 1% speedup to SunSpider in-browser * WebCore.vcproj/WebCore.vcproj: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSCustomVoidCallback.cpp: * bindings/js/JSCustomXPathNSResolver.cpp: * bindings/js/JSDOMApplicationCacheCustom.cpp: * bindings/js/JSDOMWindowBase.cpp: * bindings/js/JSDOMWindowBase.h: * bindings/js/JSDOMWindowCustom.cpp: * bindings/js/JSDOMWindowCustom.h: Added. (WebCore::asJSDOMWindow): * bindings/js/JSDatabaseCustom.cpp: * bindings/js/JSDocumentCustom.cpp: * bindings/js/JSLocationCustom.cpp: * bindings/js/JSSQLTransactionCustom.cpp: * bindings/js/JSXMLHttpRequestCustom.cpp: * page/JavaScriptDebugServer.cpp: 2008-05-19 Maciej Stachowiak Reviewed by Oliver. - obtain current inner window of outer window in a more efficient way 1.6% speedup to SunSpider in-browser * bindings/js/JSDOMWindowBase.cpp: (WebCore::JSDOMWindowBase::allowsAccessFromPrivate): 2008-05-19 Maciej Stachowiak Reviewed by Adam. - make impl() method for JSWindow inline 0.6% speedup to SunSpider in-browser * WebCore.base.exp: Remove now-inline symbol * bindings/scripts/CodeGeneratorJS.pm: Make the codegen script inline impl() even for classes with a parent class. 2008-05-17 Geoffrey Garen Reviewed by Oliver Hunt. Updated for API changes in KJS::Debugger. 2008-05-13 Geoffrey Garen Reviewed by Oliver Hunt. Updated for API changes in KJS::Debugger. * page/JavaScriptDebugServer.cpp: (WebCore::JavaScriptDebugServer::callEvent): (WebCore::JavaScriptDebugServer::atStatement): (WebCore::JavaScriptDebugServer::returnEvent): (WebCore::JavaScriptDebugServer::exception): * page/JavaScriptDebugServer.h: 2008-05-13 Geoffrey Garen Reviewed by Oliver Hunt. Updated JavaScriptDebugServer API to accept a SourceProvider instead of a UString, to avoid copying. * page/JavaScriptDebugServer.cpp: (WebCore::JavaScriptDebugServer::sourceParsed): Updated this function not to return a value. 2008-05-10 Maciej Stachowiak Build fix. - add missing forwarding header * ForwardingHeaders/kjs/SourceProvider.h: Added. 2008-05-10 Maciej Stachowiak Reviewed by Oliver. - JavaScriptGlue part of fix for: "SQUIRRELFISH: function toString broken after calling" https://bugs.webkit.org/show_bug.cgi?id=18869 * bindings/js/StringSourceProvider.h: Added. SourceProvider subclass backed by a WebCore::String. (WebCore::StringSourceProvider::create): (WebCore::StringSourceProvider::getRange): (WebCore::StringSourceProvider::data): (WebCore::StringSourceProvider::length): (WebCore::StringSourceProvider::StringSourceProvider): * bindings/js/kjs_proxy.cpp: (WebCore::KJSProxy::evaluate): Pass a StringSourceProvider to evaluate() instead of UChar* / length. * html/HTMLScriptElement.cpp: (WebCore::HTMLScriptElement::text): Modified to return the original string as-is when the script element contains only a single text node, to avoid excess memory use. * WebCore.vcproj/WebCore.vcproj: Add new file to build. * WebCore.xcodeproj/project.pbxproj: ditto 2008-05-09 Oliver Hunt Reviewed by Geoff. Build fixes for SquirrelFish on windows. * bindings/js/JSNavigatorCustom.cpp: 2008-05-08 Geoffrey Garen Reviewed by Oliver Hunt. Fixed platform/mac/plugins/bindings-test-objc.html. I've restored -[WebScriptObject setException] and +[WebScriptObject throwException]. Instead of mucking around in the JavaScript engine's execution state, throwing an exception sets a global exception string, along with the environment in which to throw it. An ObjC callback checks the global exception string and, if it's non-nil and the environment matches the current exceution environment, throws the global exception string as a JS exception. I also removed the old currentGlobalObject infrastructure: it's no longer used. 2008-05-06 Oliver Hunt Reviewed by Maciej. Bug 18866: SQUIRRELFISH: JS/ObjC bridge is broken Bug 18867: SQUIRRELFISH: JS/NPRuntime bridge is broken This fixes function binding logic for the ObjC and NPRuntime by replacing incorrect implementations of implementsCall (which is no longer virtual) with implementations of getCallData. * bindings/js/JSQuarantinedObjectWrapper.cpp: (WebCore::JSQuarantinedObjectWrapper::getCallData): * bindings/js/JSQuarantinedObjectWrapper.h: * bridge/c/c_instance.cpp: * bridge/c/c_instance.h: * bridge/objc/objc_instance.h: * bridge/objc/objc_instance.mm: * bridge/objc/objc_runtime.h: * bridge/objc/objc_runtime.mm: (ObjcFallbackObjectImp::getCallData): * bridge/runtime.h: * bridge/runtime_object.cpp: (RuntimeObjectImp::getCallData): * bridge/runtime_object.h: 2008-04-30 Geoffrey Garen Build fix: supply a parameter that used to be implicit to Interpreter::evaluate. 2008-04-30 Geoffrey Garen Build fix: #ifdef'd out some code that doesn't work anymore. * bindings/objc/WebScriptObject.mm: (+[WebScriptObject throwException:]): (-[WebScriptObject setException:]): 2008-04-14 Gabor Loki Reviewed by Geoffrey Garen. Bug 18489: Squirrelfish doesn't build on linux * WebCore.pro: Add JavaScriptCore/VM into include path 2008-04-10 Sam Weinig Reviewed by Geoffrey Garen. Adjusted WebCore JS functions to the new "getConstructData" calling convention. 2008-03-30 Geoffrey Garen Reviewed by Oliver Hunt. Adjusted WebCore JS functions to the new "getCallData" calling convention. 2008-05-19 Kuchhal Reviewed by Justin. Crash when Ctrl C is pressed after a series of specific mouse events (18506) * editing/markup.cpp: (WebCore::createMarkup): Null check. 2008-05-19 Chris Fleizach Reviewed by Beth Dakin. CrashTracer: [USER] 1 crash in Mail at -[AccessibilityObjectWrapper accessibilityAttributeValue:forParameter:] * page/mac/AccessibilityObjectWrapper.mm: (visiblePositionForTextMarker): 2008-05-19 Ada Chan Added CookieStorageWin.h/cpp, introducing methods to get/set the current CFHTTPCookieStorageRef. When setting cookies-related attributes in CFURLRequest, make sure we get them from the current CFHTTPCookieStorageRef. Also, set the cookie storage in CFURLRequest. Reviewed by Steve Falkenburg. * WebCore.vcproj/WebCore.vcproj: * platform/network/cf/ResourceHandleCFNet.cpp: (WebCore::makeFinalRequest): * platform/network/cf/ResourceRequestCFNet.cpp: (WebCore::ResourceRequest::doUpdatePlatformRequest): * platform/network/win/CookieJarCFNetWin.cpp: (WebCore::setCookies): (WebCore::cookies): (WebCore::cookiesEnabled): * platform/network/win/CookieStorageWin.cpp: Added. (WebCore::currentCookieStorage): (WebCore::setCurrentCookieStorage): * platform/network/win/CookieStorageWin.h: Added. 2008-05-19 Alexey Proskuryakov Reviewed by Darin. http://bugs.webkit.org/show_bug.cgi?id=18308 SVG Encoding error with fill attribute This is caused by problems with data: URL loading. Besides what is fixed by this patch, I filed for CFNetwork. While at it, fixed a related javascript: URL issue. Tests: fast/loader/data-url-encoding-html.html fast/loader/data-url-encoding-svg.html fast/loader/javascript-url-encoding.html * platform/KURL.cpp: (WebCore::KURL::parse): Fix a FIXME, use UTF-8 instead of dropping high bytes. This fixes javascript: URL handling. (WebCore::encodeRelativeString): Like mailto: URLs, data: ones are all UTF-8. Restructured the code to not search for "#" if both parts are to be encoded as UTF-8 anyway. 2008-05-19 Alexey Proskuryakov Reviewed by Darin. https://bugs.webkit.org/show_bug.cgi?id=18421 XMLHttpRequest does not properly encode & and < in outgoing messages Test: http/tests/xmlhttprequest/serialize-document.html * bindings/js/JSXMLHttpRequestCustom.cpp: (WebCore::JSXMLHttpRequest::send): Use createMarkup() instead of Document::toString(). * dom/Attr.cpp: * dom/Attr.h: * dom/Document.cpp: * dom/Document.h: * dom/DocumentFragment.cpp: * dom/DocumentFragment.h: * dom/Element.cpp: * dom/Element.h: * dom/Entity.cpp: * dom/Entity.h: * dom/EntityReference.cpp: * dom/EntityReference.h: * dom/Node.h: * dom/Text.cpp: * dom/Text.h: * html/HTMLElement.cpp: * html/HTMLElement.h: Removed most Node::toString() methods, which were massively wrong, and only used for XMLHttpRequest::send(). The remanining ones are still used in markup.cpp, but should probably be folded into it for consistency. 2008-05-19 Anders Carlsson Fix Windows build. * plugins/win/PluginViewWin.cpp: (WebCore::PluginView::userAgentStatic): (WebCore::PluginView::getValueStatic): (WebCore::PluginView::getValue): 2008-05-19 Chris Fleizach Reviewed by Darin Adler. AX: crash in text marker range * page/mac/AccessibilityObjectWrapper.mm: (textMarkerRangeFromMarkers): 2008-05-19 Darin Adler - fix WebKit build * WebCore.xcodeproj/project.pbxproj: Make CSSReflectionDirection.h "private" instead of "project". 2008-05-19 chris fleizach Reviewed by Darin Adler VO: VoiceOver should fall back to title attr if form element is not labeled * page/AccessibilityRenderObject.cpp: (WebCore::AccessibilityRenderObject::title): 2008-05-19 Darin Adler Reviewed by Mitz. - tweak CSSReflectValue, possibly fixing the leaks seen on the buildbot * WebCore.vcproj/WebCore.vcproj: Added CSSReflectionDirection.h. * WebCore.xcodeproj/project.pbxproj: Ditto. * css/CSSReflectionDirection.h: Added. * css/CSSComputedStyleDeclaration.cpp: (WebCore::valueForReflection): Changed to use CSSReflectValue::create. * css/CSSParser.cpp: (WebCore::CSSParser::parseReflect): Ditto. * css/CSSReflectValue.h: Added a create function. Got rid of the setter functions, which had const PassRefPtr& arguments -- those probably caused the leaks although I'm not exactly sure why. Made the contructor and all the data members private. * rendering/style/RenderStyle.h: Changed to include CSSReflectionDirection.h instead of CSSReflectValue.h so we can tweak CSSReflectValue without recompiling the world. 2008-05-19 Holger Hans Peter Freyther Rubber Stamped by Simon. Enforce the WebKit Coding Style. * plugins/PluginView.cpp: (WebCore::PluginView::load): (WebCore::PluginView::setValue): * plugins/gtk/PluginViewGtk.cpp: (WebCore::PluginView::setFocus): (WebCore::PluginView::show): (WebCore::PluginView::hide): (WebCore::PluginView::attachToWindow): (WebCore::PluginView::detachFromWindow): (WebCore::PluginView::getValueStatic): (WebCore::PluginView::getValue): * plugins/qt/PluginViewQt.cpp: (WebCore::PluginView::updateWindow): (WebCore::PluginView::detachFromWindow): (WebCore::PluginView::handlePostReadFile): (WebCore::PluginView::getValueStatic): (WebCore::PluginView::getValue): 2008-05-14 Marc Ordinas i Llopis Reviewed by Holger. https://bugs.webkit.org/show_bug.cgi?id=18882 https://bugs.webkit.org/show_bug.cgi?id=18892 Based also on work by Chris Lord. Provides support for NPAPI plugins that pass NULL as their instance info. There are two kinds: - Some call NPN_UserAgent and NPN_GetValue before a PluginView has been created. For those we provide static versions of those functions. - Others call NPN_* functions with a NULL instance inside NPP_* calls, for those we've added extra currentPluginView guards. * plugins/PluginView.cpp: Add additional currentPluginView guards and some small style changes. (WebCore::PluginView::start): (WebCore::PluginView::performRequest): (WebCore::PluginView::bindingInstance): (WebCore::PluginView::handlePost): * plugins/PluginView.h: Added static versions of NPN_UserAgent and NPN_GetValue. * plugins/gtk/PluginViewGtk.cpp: Add additional currentPluginView guards and some small style changes. (WebCore::PluginView::setNPWindowRect): (WebCore::PluginView::stop): (WebCore::PluginView::userAgentStatic): Added to deal with plugins that query this before having a PluginView. (WebCore::PluginView::getValueStatic): Added to deal with plugins that call this before we have created a PluginView. (WebCore::PluginView::getValue): Moved some code to getValueStatic. (WebCore::PluginView::init): * plugins/npapi.cpp: Call PluginView::userAgentStatic and PluginView::getValueStatic if no PluginView is present. (NPN_UserAgent): (NPN_GetValue): * plugins/qt/PluginPackageQt.cpp: (WebCore::PluginPackage::fetchInfo): Corrected split args because ignoring empty entries crashed. (WebCore::PluginPackage::load): Resolve all symbols when loading plugins to protect against XPCOM dependencies. * plugins/qt/PluginViewQt.cpp: Add additional currentPluginView guards and some small style changes. (WebCore::PluginView::updateWindow): (WebCore::PluginView::setNPWindowRect): (WebCore::PluginView::stop): (WebCore::PluginView::userAgentStatic): Added to deal with plugins that query this before having a PluginView. (WebCore::PluginView::handlePostReadFile): (WebCore::PluginView::getValueStatic): Added to deal with plugins that call this before we have created a PluginView. (WebCore::PluginView::getValue): Moved some code to getValueStatic. (WebCore::PluginView::init): m_needsXEmbed init was moved to constructor. 2008-05-19 Alp Toker GTK+ build fix on Mac. Conditionalize XP_UNIX use. * plugins/gtk/PluginPackageGtk.cpp: (WebCore::PluginPackage::fetchInfo): (WebCore::PluginPackage::load): * plugins/gtk/PluginViewGtk.cpp: 2008-05-18 Chris Fleizach Reviewed by Darin Adler WebKit can no longer find URL links with VoiceOVer-U command (19100) * page/AccessibilityObject.h: 2008-05-18 Darin Adler Reviewed by Sam. - fix crash due to stale ownerNode pointer Test: fast/dom/StyleSheet/ownerNode-lifetime.html * bindings/js/JSStyleSheetCustom.cpp: (WebCore::JSStyleSheet::mark): Added code to mark ownerNode. Includes a comment about how it would be even better to solve this in the DOM rather than just in the JavaScript binding. * css/StyleSheet.idl: Added CustomMarkFunction attribute. 2008-05-18 Brady Eidson Reviewed by Sam Weinig Fix for https://bugs.webkit.org/show_bug.cgi?id=19111 Allow `delete storage.itemName` syntax as an alias for `storage.removeItem("itemName")` Tests: storage/domstorage/localstorage/delete-removal.html storage/domstorage/sessionstorage/delete-removal.html * bindings/js/JSStorageCustom.cpp: (WebCore::JSStorage::deleteProperty): Only do the delete for non-built in properties * storage/Storage.idl: 2008-05-17 Sam Weinig Reviewed by Mark Rowe. Re-factor core setRequestHeader logic into setRequestHeaderInternal. * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::sameOriginRequest): (WebCore::XMLHttpRequest::setRequestHeader): (WebCore::XMLHttpRequest::setRequestHeaderInternal): * xml/XMLHttpRequest.h: 2008-05-17 Sam Weinig Reviewed by Mark Rowe. Differentiate between cancelation errors and generic network error in XHR. * loader/FrameLoader.cpp: (WebCore::FrameLoader::requestFromDelegate): (WebCore::FrameLoader::cancelledError): * platform/network/ResourceErrorBase.h: (WebCore::ResourceErrorBase::setIsCancelation): (WebCore::ResourceErrorBase::isCancelation): (WebCore::ResourceErrorBase::ResourceErrorBase): Add state that differentiates between errors created by cancelation and those made by all other generic network errors as this differentiation is needed by some specs. * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::open): (WebCore::XMLHttpRequest::loadRequestSynchronously): (WebCore::XMLHttpRequest::clearResponseEntityBody): (WebCore::XMLHttpRequest::genericError): (WebCore::XMLHttpRequest::networkError): (WebCore::XMLHttpRequest::abortError): (WebCore::XMLHttpRequest::didFail): * xml/XMLHttpRequest.h: * xml/XMLHttpRequestException.h: (WebCore::XMLHttpRequestException::): * xml/XMLHttpRequestException.idl: Add ABORT_ERR. This error cannot be raised with the current WebKit architecture as it requires the ability to cancel a synchronous XHR, which we cannot currently do. It may be possible in the future though. 2008-05-17 Mark Rowe Reviewed by Sam Weinig. Including wtf/Platform.h or using any of the macros it defines in headers that may be included from outside of the WebKit project causes any project using those headers to fail to build. * page/mac/WebDashboardRegion.h: 2008-05-17 Sam Weinig Reviewed by Brady Eidson. Re-factor send() logic a little to make adding cross-site requests easier. * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::send): (WebCore::XMLHttpRequest::sameOriginRequest): (WebCore::XMLHttpRequest::loadRequestSynchronously): (WebCore::XMLHttpRequest::loadRequestAsynchronously): * xml/XMLHttpRequest.h: 2008-05-16 Anders Carlsson Reviewed by Mitz. Copy appcache headers. * WebCore.vcproj/WebCore.vcproj: 2008-05-16 Antti Koivisto Reviewed by Anders. Fix Movie controller does not update on first load of http://www.apple.com/getamac/ads/ The issue is that we execute scripts while there are still pending stylesheet loads. If the script depends on a stylesheet having been applied it may fail. This will make external script execution block on external stylesheet loads. A full fix (as discussed with Hyatt) will also need to block inline script execution. Test: http/tests/local/stylesheet-and-script-load-order-http.html * html/HTMLTokenizer.cpp: (WebCore::HTMLTokenizer::notifyFinished): 2008-05-16 chris fleizach Reviewed by Jon Honeycutt Mail compose area needs to allow AXValue to be settable * page/AccessibilityRenderObject.cpp: (WebCore::AccessibilityRenderObject::isReadOnly): (WebCore::AccessibilityRenderObject::canSetValueAttribute): 2008-05-16 Stephanie Lewis Reviewed by Maciej. track onbeforeunlaod event counts. Pretty much identical to unload event tracking. Also rename methods from onunload tracking to be more clear. increment/decrement event counts when onunload and onbeforeunload events are added/removed * dom/Document.cpp: (WebCore::Document::removeHTMLWindowEventListener): (WebCore::Document::addWindowEventListener): (WebCore::Document::removeWindowEventListener): (WebCore::Document::addPendingFrameUnloadEventCount): (WebCore::Document::removePendingFrameUnloadEventCount): (WebCore::Document::addPendingFrameBeforeUnloadEventCount): (WebCore::Document::removePendingFrameBeforeUnloadEventCount): * dom/Document.h: clear onunload count after unload events are dispatched * loader/FrameLoader.cpp: (WebCore::FrameLoader::stopLoading): track onunload and onbeforeunload event counts for each frame * page/EventHandler.cpp: (WebCore::EventHandler::EventHandler): (WebCore::EventHandler::addPendingFrameUnloadEventCount): (WebCore::EventHandler::removePendingFrameUnloadEventCount): (WebCore::EventHandler::clearPendingFrameUnloadEventCount): (WebCore::EventHandler::pendingFrameBeforeUnloadEventCount): (WebCore::EventHandler::addPendingFrameBeforeUnloadEventCount): (WebCore::EventHandler::removePendingFrameBeforeUnloadEventCount): (WebCore::EventHandler::clearPendingFrameBeforeUnloadEventCount): * page/EventHandler.h: clear unbeforeunload count after unbeforeunload events are detached * page/Frame.cpp: (WebCore::Frame::shouldClose): track total event count at page level * page/Page.cpp: (WebCore::Page::Page): (WebCore::Page::changePendingUnloadEventCount): (WebCore::Page::pendingBeforeUnloadEventCount): (WebCore::Page::changePendingBeforeUnloadEventCount): * page/Page.h: 2008-05-16 Anders Carlsson Reviewed by Mitz. REGRESSION: fast/loader/xmlhttprequest-missing-file-exception.html fails on Windows. Replicate the Mac behavior when a sync load fails. * platform/network/cf/ResourceHandleCFNet.cpp: (WebCore::ResourceHandle::loadResourceSynchronously): 2008-05-16 Anders Carlsson Reviewed by Brady. Parse and set the headers on the response. * loader/appcache/ApplicationCacheStorage.cpp: (WebCore::ApplicationCacheStorage::store): (WebCore::parseHeader): (WebCore::parseHeaders): (WebCore::ApplicationCacheStorage::loadCache): 2008-05-16 Timothy Hatcher Adds the "this" object to the Local scope section of the Scope Variables pane. Web Inspector doesn't show the "this" object in its variables list (10438) Reviewed by Oliver Hunt. * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::thisObject): Returns the thisObject of the JavaScriptCallFrame impl. Returns jsNull if the impl is invalid. * page/JavaScriptCallFrame.cpp: (WebCore::JavaScriptCallFrame::thisObject): Return the thisValue from the ExecState. Return 0 if m_exec is null. * page/JavaScriptCallFrame.h: * page/JavaScriptCallFrame.idl: Add thisObject. * page/inspector/ObjectPropertiesSection.js: (WebInspector.ObjectPropertiesSection): Adds two new arguments. The ignoreHasOwnProperty tells the section to show all properties, including inherited ones. And extraProperties is an object of additional properties to show. (WebInspector.ObjectPropertiesSection.prototype): Honor the extraProperties and ignoreHasOwnProperty properties. * page/inspector/ScopeChainSidebarPane.js: (WebInspector.ScopeChainSidebarPane.prototype.update): Add a this property to an extra object that is passed to the ObjectPropertiesSection. Also pass true for ignoreHasOwnProperty since we want to show all properties. 2008-05-16 Anders Carlsson Reviewed by Brady. Add mimeType and textEncodingName to the resource table. * loader/appcache/ApplicationCacheStorage.cpp: (WebCore::ApplicationCacheStorage::openDatabase): (WebCore::ApplicationCacheStorage::store): (WebCore::ApplicationCacheStorage::loadCache): 2008-05-16 Kevin McCullough Reviewed by Tim. JavaScript profiler (10928) Use a Vector instead of a Deque since we don't use the extra capabilities of the Deque. * page/JavaScriptProfileNode.cpp: (WebCore::getChildren): (WebCore::toJS): 2008-05-16 Anders Carlsson Reviewed by Brady. Add a version table to the database. * loader/appcache/ApplicationCacheStorage.cpp: (WebCore::ApplicationCacheStorage::verifySchemaVersion): (WebCore::ApplicationCacheStorage::openDatabase): * loader/appcache/ApplicationCacheStorage.h: 2008-05-16 Timothy Hatcher Adds the ability to evaluate expressions in the local scope of the selected call frame. https://bugs.webkit.org/show_bug.cgi?id=19052 Reviewed by Geoff Garen. * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::evaluate): Pass the exception from evaluate to the calling ExecState. * page/JavaScriptCallFrame.cpp: (WebCore::JavaScriptCallFrame::evaluate): Added an exception out argument. Simplified the code by calling KJS:eval directly. * page/JavaScriptCallFrame.h: Change evalutate to take an exception out argument. * page/inspector/Console.js: Check if the debugger is paused and call evaluateInSelectedCallFrame on the Scripts panel. * page/inspector/ScriptsPanel.js: Added a paused getter and evaluateInSelectedCallFrame which does the evaluation and updates the scope variables pane afterwards. 2008-05-16 Timothy Hatcher Fixed the bug where the Inspector node highlight would not show in the correct place for nodes in frames. Elements in iframes are highlighted incorrectly (14408) Reviewed by John Sullivan. * page/InspectorController.cpp: (WebCore::convertFromFrameToMainFrame): Helper function to convert IntRect coordinates from one frame to the main frame. (WebCore::InspectorController::drawNodeHighlight): Call the convertFromFrameToMainFrame helper for all the rects we get from the node since they are in the owner frame's coordinate space. 2008-05-16 Julien Chaffraix Reviewed by Eric. Preparatory work for bug 9191: JS*ElementWrapperFactory should be autogenerated Make video tags use a header guard so that make_names.pl for factory generation. - Add video tag guard in HTMLTagNames.in & give an extraDefines parameter to make_names.pl when generating HTMLNames. - Modify the different build systems to accomodate the new parameter. - Small make_names.pl clean up (mainly code generated coding style issue). * DerivedSources.make: Add HTML_FLAGS and pass it to make_names.pl if it is defined (similar to SVG) * GNUmakefile.am: Add HTML_FEATURES & HTML_FLAGS and pass it to make_names.pl if HTML_FLAGS is defined. * WebCore.pro: Pass $${DEFINES} to make_names.pl. * dom/make_names.pl: * html/HTMLElement.cpp: (WebCore::inlineTagList): Add ENABLE(VIDEO) guard. * html/HTMLTagNames.in: Ditto. 2008-05-16 Anders Carlsson Reviewed by Mitz. Fire progress events. * loader/appcache/ApplicationCacheGroup.cpp: (WebCore::ApplicationCacheGroup::startLoadingEntry): 2008-05-16 Anders Carlsson Reviewed by John. Handle the case where the main resource load is cancelled while the cache attempt is in progress. * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::mainReceivedError): Tell the group that the main resource failed to load. * loader/appcache/ApplicationCacheGroup.cpp: (WebCore::ApplicationCacheGroup::failedLoadingMainResource): Call cacheUpdateFailed. (WebCore::ApplicationCacheGroup::cacheUpdateFailed): Stop loading if the update failed. * loader/appcache/ApplicationCacheGroup.h: 2008-05-16 Chris Fleizach Reviewed by Alice Liu REGRESSION:Selecting ranges of text should be possible using the keyboard (15310) * WebCore.base.exp: * editing/VisiblePosition.cpp: (WebCore::VisiblePosition::leftVisuallyDistinctCandidate): (WebCore::VisiblePosition::rightVisuallyDistinctCandidate): * page/AXObjectCache.cpp: * page/AXObjectCache.h: (WebCore::AXObjectCache::enableEnhancedUserInterfaceAccessibility): (WebCore::AXObjectCache::accessibilityEnabled): (WebCore::AXObjectCache::accessibilityEnhancedUserInterfaceEnabled): * page/AccessibilityRenderObject.cpp: (WebCore::AccessibilityRenderObject::visiblePositionRange): (WebCore::AccessibilityRenderObject::doSetAXSelectedTextMarkerRange): (WebCore::AccessibilityRenderObject::addChildren): (WebCore::AccessibilityRenderObject::actionVerb): * page/EventHandler.cpp: (WebCore::EventHandler::handleKeyboardSelectionMovement): (WebCore::EventHandler::defaultKeyboardEventHandler): * page/EventHandler.h: 2008-05-15 Ariya Hidayat Reviewed by Simon. Since WebKitGtk is fully using autotools now, clean-up the .pro/.pri files from gtk-port. * WebCore.pro: 2008-05-16 Simon Hausmann Fix the Gtk build. * GNUmakefile.am: Added rendering/style to the include paths. 2008-05-16 Simon Hausmann Fix the Qt build. * WebCore.pro: Added rendering/style to the include paths * page/AXObjectCache.cpp: (WebCore::AXObjectCache::handleActiveDescendantChanged): Don't compile this method unless a17n is enabled. 2008-05-15 Rob Buis Reviewed by Dave Hyatt. https://bugs.webkit.org/show_bug.cgi?id=17433 getComputedStyle() -> clip returns empty string Make getComputedStyle return a shape value for clip if it is set. Tests: fast/css/getPropertyValue-clip.html * css/CSSComputedStyleDeclaration.cpp: (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): 2008-05-15 Kevin Ollivier wx build fix. Add rendering/style to includes dir. * webcore-base.bkl: 2008-05-15 Alice Liu Reviewed by Beth Dakin. Fixed Implement ARIA aria-activedescendant Also added support for aria roles listbox and option, and aria-selected, and aria-multiselectable for listboxes * dom/Element.cpp: (WebCore::Element::attributeChanged): * dom/Element.h: * dom/StyledElement.cpp: (WebCore::StyledElement::attributeChanged): * html/HTMLAttributeNames.in: * page/AXObjectCache.cpp: (WebCore::AXObjectCache::handleActiveDescendantChanged): * page/AXObjectCache.h: (WebCore::AXObjectCache::accessibilityEnabled): (WebCore::AXObjectCache::handleActiveDescendantChanged): * page/AccessibilityListBox.cpp: (WebCore::AccessibilityListBox::selectedChildren): (WebCore::AccessibilityListBox::visibleChildren): * page/AccessibilityListBox.h: * page/AccessibilityListBoxOption.h: (WebCore::AccessibilityListBoxOption::selectedChildren): (WebCore::AccessibilityListBoxOption::visibleChildren): * page/AccessibilityObject.cpp: * page/AccessibilityObject.h: (WebCore::AccessibilityObject::isListBox): (WebCore::AccessibilityObject::shouldFocusActiveDescendant): (WebCore::AccessibilityObject::activeDescendant): (WebCore::AccessibilityObject::handleActiveDescendantChanged): * page/AccessibilityRenderObject.cpp: (WebCore::AccessibilityRenderObject::title): (WebCore::AccessibilityRenderObject::accessibilityShouldUseUniqueId): (WebCore::AccessibilityRenderObject::focusedUIElement): (WebCore::AccessibilityRenderObject::shouldFocusActiveDescendant): (WebCore::AccessibilityRenderObject::activeDescendant): (WebCore::AccessibilityRenderObject::handleActiveDescendantChanged): (WebCore::RoleEntry::): (WebCore::AccessibilityRenderObject::ariaRoleAttribute): (WebCore::AccessibilityRenderObject::ariaListboxSelectedChildren): (WebCore::AccessibilityRenderObject::selectedChildren): (WebCore::AccessibilityRenderObject::ariaListboxVisibleChildren): (WebCore::AccessibilityRenderObject::visibleChildren): * page/AccessibilityRenderObject.h: (WebCore::AccessibilityRenderObject::isDetached): * page/mac/AccessibilityObjectWrapper.mm: (-[AccessibilityObjectWrapper accessibilityAttributeValue:]): 2008-05-15 Timothy Hatcher Adds an error and warning count indicator at the bottom right in the Inspector's status bar. https://bugs.webkit.org/show_bug.cgi?id=18650 Initial implementation by Adam Roben. Reviewed by Sam Weinig. Test: manual-tests/inspector/error-warning-count.html * English.lproj/localizedStrings.js: Added new strings. * manual-tests/inspector/error-warning-count.html: Added. * page/inspector/Console.js: (WebInspector.Console.prototype.show): Don't do anything if visible. (WebInspector.Console.prototype.hide): Don't do anything if hidden. Temporally set properties and classes to mimic the post-animation values so panels like Elements in their updateStatusBarItems call will size things to fit the final location. * page/inspector/ElementsPanel.js: (WebInspector.ElementsPanel.prototype.updateBreadcrumbSizes): Account for the #error-warning-count width when sizing breadcrumbs. * page/inspector/Resource.js: (WebInspector.Resource.prototype.set errors): Update the global error count. (WebInspector.Resource.prototype.set warnings): Update the global warning count. * page/inspector/inspector.css: Make .hidden's display property !important to ensure things really hide, and added styling for the new #error-warning-count element. * page/inspector/inspector.html: Added an #error-warning-count div in the #anchored-status-bar-items div. * page/inspector/inspector.js: (WebInspector.get errors): Added. (WebInspector.set errors): Added. Calls _updateErrorAndWarningCounts. (WebInspector.get warnings): Added. (WebInspector.set warnings): Added. Calls _updateErrorAndWarningCounts. (WebInspector._updateErrorAndWarningCounts): Added. Update the #error-warning-count div with the current error/warning count. (WebInspector.loaded): Add a click event listener to the #error-warning-count element that will show the Console. Call _updateErrorAndWarningCounts to display the initial error/warning counts. 2008-05-15 Timothy Hatcher Fixes a bug in the view source parsing of text within