1. 07 Apr, 2008 21 commits
    • beidson@apple.com's avatar
      WebCore: · c2e6fd7e
      beidson@apple.com authored
      2008-04-07  Brady Eidson  <beidson@apple.com>
              Lovingly reviewed by Sam Weinig
              <rdar://problem/5797684> - HTML5 SessionStorage and underpinnings for LocalStorage
              Tests: storage/domstorage/sessionstorage/iframe-events.html
              * Configurations/WebCore.xcconfig: Define to enable DOM_STORAGE
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::mark): Add optionalSessionStorage case
              * bindings/js/JSEventCustom.cpp:
              (WebCore::toJS): Add StorageEvent case
              * bindings/js/JSStorageCustom.cpp:
              (WebCore::JSStorage::nameGetter): If the property doesn't exist on the object, call through to getItem()
              (WebCore::JSStorage::customPut): If the property doesn't exist on the object, call through to setItem()
              * dom/Event.cpp:
              * dom/Event.h:
              * dom/EventNames.h: Add "storage"
              * dom/EventTargetNode.cpp:
              * dom/EventTargetNode.h:
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::createWindow): After a new page has been created, set its SessionStorage object
                to a copy of the previous Page's
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::sessionStorage): Accessor to pull the appropriate OriginStorage out of the Page's
              (WebCore::DOMWindow::localStorage): To be filled in later
              * page/DOMWindow.h:
              (WebCore::DOMWindow::optionalSessionStorage): Return the session Storage object for this window to mark, 
                if any exists
              * page/DOMWindow.idl:
              * page/Page.cpp:
              (WebCore::Page::sessionStorage):  Create and/or return the SessionStorage for this Page.
              (WebCore::Page::setSessionStorage): Set the SessionStorage for this Page - used in FrameLoader after a
              * page/Page.h:
              * storage/OriginStorage.cpp: Intermediate layer between individual Storage objects, and shared StorageMap 
                objects.  There is one OriginStorage object per SecurityOrigin in each "unique set of storage areas", such
                as the SessionStorage.  This layer forwards DOM-level calls down to the backing StorageMap, handles 
                copy-on-write along with the StorageMap, fires StorageEvents to the DOM when a value is changed, and will
                eventually handle quota enforcement.
              * storage/OriginStorage.h:
              * storage/SessionStorage.cpp: From the HTML5 spec:
                "Each top-level browsing context has a unique set of session storage areas, one for each origin."
                This object represents that "unique set of session storage areas", and creates or returns the Storage
                object for the requested SecurityOrigin
              * storage/SessionStorage.h:
              * storage/Storage.cpp: Representation of the DOM-level object, wrapped by JSStorage.  There is a unique
                Storage object per Window (per-Frame) that wraps a specific shared OriginStorage object.
              * storage/Storage.h:
              * storage/Storage.idl:
              * storage/StorageEvent.cpp:
              * storage/StorageEvent.h:
              * storage/StorageMap.cpp: The physical map of key/value pairs that is shared between OriginStorage objects, 
                and implements copy-on-write semantics whenever a value is changed
              (WebCore::StorageMap::invalidateIterator): Used to support the key(unsigned i) part of the API
              (WebCore::StorageMap::setIteratorToIndex): Ditto
              * storage/StorageMap.h:
      2008-04-07  Brady Eidson  <beidson@apple.com>
              Begrudgingly reviewed by Sam Weinig
              Initial suite of layout tests for HTML5 key/value SessionStorage (<rdar://problem/5797684>)
              * fast/dom/Window/window-properties-expected.txt:
              * storage/domstorage: Added.
              * storage/domstorage/localstorage: Added.
              * storage/domstorage/sessionstorage: Added.
              * storage/domstorage/sessionstorage/iframe-events-expected.txt: Added.
              * storage/domstorage/sessionstorage/iframe-events.html: Added.
              * storage/domstorage/sessionstorage/index-get-and-set-expected.txt: Added.
              * storage/domstorage/sessionstorage/index-get-and-set.html: Added.
              * storage/domstorage/sessionstorage/resources: Added.
              * storage/domstorage/sessionstorage/resources/clearSessionStorage.js: Added.
              * storage/domstorage/sessionstorage/resources/iframe-events-second.html: Added.
              * storage/domstorage/sessionstorage/resources/window-open-second.html: Added.
              * storage/domstorage/sessionstorage/simple-events-expected.txt: Added.
              * storage/domstorage/sessionstorage/simple-events.html: Added.
              * storage/domstorage/sessionstorage/simple-usage-expected.txt: Added.
              * storage/domstorage/sessionstorage/simple-usage.html: Added.
              * storage/domstorage/sessionstorage/window-open-expected.txt: Added.
              * storage/domstorage/sessionstorage/window-open.html: Added.
              * storage/domstorage/window-attributes-exist-expected.txt: Added.
              * storage/domstorage/window-attributes-exist.html: Added.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31697 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Renamed various functions that are internal to the Console object to have an underscore prefix. · f02a7bed
      timothy@apple.com authored
      Rubber-stamped by Adam Roben.
      * page/inspector/Console.js:
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31696 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Renamed various functions and properties that are internal to an object to... · dee8e986
      timothy@apple.com authored
      Renamed various functions and properties that are internal to an object to have an underscore prefix.
      Rubber-stamped by Adam Roben.
      * page/inspector/Resource.js:
      * page/inspector/ResourcesPanel.js:
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31695 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • aroben@apple.com's avatar
      Windows build fix · 1527713a
      aroben@apple.com authored
              * wtf/ThreadingWin.cpp: Back out some changes I didn't mean to land.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31694 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Fixes coding style for two utility getters. · fc31cea8
      timothy@apple.com authored
      * page/inspector/utilities.js: Fix coding style for the
      totalOffsetLeft and totalOffsetTop getters.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31693 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • sullivan@apple.com's avatar
      2008-04-07 John Sullivan <sullivan@apple.com> · ac65fe30
      sullivan@apple.com authored
              Reviewed by Tim
              - made the JavaScript text input panel not block Quit (part of 4133196)
              * English.lproj/WebJavaScriptTextInputPanel.nib/classes.nib:
              * English.lproj/WebJavaScriptTextInputPanel.nib/info.nib:
              * English.lproj/WebJavaScriptTextInputPanel.nib/keyedobjects.nib:
              Made the panel be a NonBlockingPanel
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31692 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • aroben@apple.com's avatar
      Export some more WTF functions from WebKit.dll · 5f28cd98
      aroben@apple.com authored
              Reviewed by Alexey Proskuryakov.
              * WebKit.vcproj/WebKit.def:
              * WebKit.vcproj/WebKit_debug.def:
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31691 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • aroben@apple.com's avatar
      Add WTF::isMainThread · a3af6a64
      aroben@apple.com authored
              Reviewed by Alexey Proskuryakov.
              * wtf/Threading.h: Declare the new function.
              * wtf/ThreadingGtk.cpp:
              (WTF::initializeThreading): Initialize the main thread identifier.
              (WTF::isMainThread): Added.
              * wtf/ThreadingNone.cpp: Ditto ThreadingGtk.cpp.
              * wtf/ThreadingPthreads.cpp: Ditto.
              * wtf/ThreadingWin.cpp: Ditto.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31690 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • mitz@apple.com's avatar
      Reviewed by Dave Hyatt. · 7cda5b10
      mitz@apple.com authored
              - fix http://bugs.webkit.org/show_bug.cgi?id=18311
                <rdar://problem/5842980> REGRESSION (r31620): Font variants (e.g. Helvetica Neue *Light*) don't render correctly
              * platform/mac/WebFontCache.mm:
              (+[WebFontCache internalFontWithFamily:traits:weight:size:]): Changed to
              match by family name first, and only if that fails, look for a match by
              full (PostScript) name. Reverted the full name-based match logic to only
              distinguish between the broad categories of "bold" and "not bold".
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31689 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      When the WebInspector.currentFocusElement changes, move the caret selection to... · 7e1bec54
      timothy@apple.com authored
      When the WebInspector.currentFocusElement changes, move the caret selection to be inside the focused element. This makes sure the caret moves in and out of the console when the focus changes.
      Reviewed by Adam Roben.
      * page/inspector/TextPrompt.js:
      (TextPrompt.prototype.isCaretInsidePrompt): Just call isInsertionCaretInside.
      * page/inspector/inspector.js:
      (WebInspector.set currentFocusElement): Make a caret selection inside
      the focused element if there isn't a range selection and there isn't
      already a caret selection inside.
      * page/inspector/utilities.js:
      (Element.prototype.isInsertionCaretInside): Added. Tests if the
      selection is collapsed and is inside the element.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31688 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • beidson@apple.com's avatar
      2008-04-07 Brady Eidson <beidson@apple.com> · f65c9fae
      beidson@apple.com authored
              Reviewed by Tim Hatcher
              Add 1 more empty file for upcoming work, as a separate step, to keep all build-systems working
              * GNUmakefile.am:
              * WebCore.pro:
              * WebCore.vcproj/WebCore.vcproj:
              * WebCore.xcodeproj/project.pbxproj:
              * WebCoreSources.bkl:
              * bindings/js/JSStorageCustom.cpp: Added.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31687 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • ap@webkit.org's avatar
      Reviewed by Dan Bernstein. · b5383bee
      ap@webkit.org authored
              <rdar://problem/5574946> Inline frame ISO-8859-1 even though parent character set is UTF-8
              Test: fast/loader/inherit-charset-to-empty-frame.html
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::write): Treat an empty m_encoding the same as null one.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31686 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Rename some Inspector panel objects to facilitate the up-coming · 75cbef39
      timothy@apple.com authored
      UI refresh changes.
      Reviewed by Adam Roben.
      * page/inspector/DatabasesPanel.js: Renamed ResourcePanel to ResourceView.
      * page/inspector/ElementsPanel.js: Renamed SourcePanel to SourceView.
      * page/inspector/FontView.js: Renamed FontPanel to FontView.
      * page/inspector/ImageView.js: Renamed ImagePanel to ImageView.
      * page/inspector/Resource.js: Instantiate the new "View" named objects.
      * page/inspector/ResourceView.js: Renamed ResourcePanel to ResourceView.
      * page/inspector/SourceView.js: Renamed SourcePanel to SourceView.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31685 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Fix an exception and remove code that was missed when TextPrompt · 2f93c80b
      timothy@apple.com authored
      was added. This makes the Console work again.
      Reviewed by Adam Roben.
      * page/inspector/Console.js: Removed code that used non-existent
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31684 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • timothy@apple.com's avatar
      Remove the workaround for bug 11399 now that it is fixed. · 9c2d8071
      timothy@apple.com authored
      Reviewed by Adam Roben.
      * page/inspector/Console.js: Removed the 'with' statement
      around the eval and call eval directly on the inspected window.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31683 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • alp@webkit.org's avatar
      2008-04-07 Luca Bruno <lethalman88@gmail.com> · b46c9feb
      alp@webkit.org authored
              Reviewed by Alp Toker.
              Bug #18297 - Acid2/Acid3 -tests don't load load with soup.
              Fixes in the libsoup backend: data url parsing, acid tests, redirects,
              response headers handling and re-entrancy issues on job cancellation.
              Thanks to Dan Winship for libsoup hints.
              * platform/network/ResourceHandleInternal.h:
              (WebCore::ResourceHandleInternal::ResourceHandleInternal): add m_cancelled and remove unuseful m_session
              * platform/network/soup/ResourceHandleSoup.cpp:
              (WebCore::restartedCallback): added to route redirects to webkit
              (WebCore::dataCallback): add response headers, some checks and fix re-entrancy
              (WebCore::parseDataUrl): be an idle callback for the main loop
              (WebCore::ResourceHandle::cancel): fixed re-entrancy
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31682 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • ap@webkit.org's avatar
      Build fix, rubber-stamped and landed by ap. · c266b3f7
      ap@webkit.org authored
              * configure.ac: Add autoconf flag for HTML5 client-side session and persistent storage support.
              * GNUmakefile.am: Fix dom_storage conditional and typo: ENABLE_DOM_STORAG.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31681 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • beidson@apple.com's avatar
      2008-04-07 Brady Eidson <beidson@apple.com> · 5ad07575
      beidson@apple.com authored
              Whoops, idls don't go in the vcproj!
              * WebCore.vcproj/WebCore.vcproj:
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31680 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • beidson@apple.com's avatar
      2008-04-06 Brady Eidson <beidson@apple.com> · 860faa5f
      beidson@apple.com authored
              Attempt to tickle Windows build into accepting this idl
              * storage/StorageEvent.idl:
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31679 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • beidson@apple.com's avatar
      2008-04-06 Brady Eidson <beidson@apple.com> · cce3c766
      beidson@apple.com authored
              Reviewed by Sam
              HTML5 Session and Local Storage
              Land a bunch of empty files and interfaces to keep things building while 
              I finish off the rest of the implementation of SessionStorage
              * DerivedSources.make:
              * GNUmakefile.am:
              * WebCore.pro:
              * WebCore.vcproj/WebCore.vcproj:
              * WebCore.xcodeproj/project.pbxproj:
              * WebCoreSources.bkl:
              * storage/OriginStorage.cpp: Added.
              * storage/OriginStorage.h: Added.
              * storage/SessionStorage.cpp: Added.
              * storage/SessionStorage.h: Added.
              * storage/Storage.cpp: Added.
              * storage/Storage.h: Added.
              * storage/Storage.idl: Added.
              * storage/StorageEvent.cpp: Added.
              * storage/StorageEvent.h: Added.
              * storage/StorageEvent.idl: Added.
              * storage/StorageMap.cpp: Added.
              * storage/StorageMap.h: Added.
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31678 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    • ap@webkit.org's avatar
      Reviewed by Darin. · 11f3871c
      ap@webkit.org authored
              Make UString thread-safe.
              No change on SunSpider total, although individual tests have changed a lot, up to 3%.
              * kjs/InitializeThreading.cpp: (KJS::initializeThreading): Call UString::null() to initialize
              a static.
              * kjs/identifier.cpp:
              Use "true" for a boolean value instead of 1, because it's C++.
              * kjs/ustring.h:
              (KJS::CString::adopt): Added a method to create from a char* buffer without copying.
              (KJS::UString::Rep::ref): Removed an assertion for JSLock::lockCount, as it's no longer
              necessary to hold JSLock when working with strings.
              (KJS::UString::Rep::deref): Ditto.
              (KJS::UString::Rep::isStatic): Added a field to quickly determine that this is an empty
              or null static string.
              * kjs/ustring.cpp:
              (KJS::): Removed normalStatBufferSize and statBufferSize, as there is no reason to have such
              an advanced implementation of a debug-only ascii() method. Removed a long-obsolete comment
              about UChar.
              (KJS::UString::Rep::createCopying): Removed an assertion for JSLock::lockCount.
              (KJS::UString::Rep::create): Ditto.
              (KJS::UString::Rep::destroy): Ditto. Do not do anything for static null and empty strings,
              as refcounting is not reliable for those. Reordered branches for a noticeable speed gain -
              apparently this functiton is hot enough for SunSpider to see an effect from this!
              (KJS::UString::null): Moved a star, added a comment.
              (KJS::UString::cstring): Reimplemented to not call ascii(), which is not thread-safe.
              (KJS::UString::ascii): Simplified statBuffer handling logic.
              (KJS::UString::toDouble): Use cstring() instead of ascii().
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31677 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  2. 06 Apr, 2008 1 commit
  3. 05 Apr, 2008 11 commits
  4. 04 Apr, 2008 7 commits