1. 13 Apr, 2009 40 commits
    • eric.carlson@apple.com's avatar
      2009-04-13 Eric Carlson <eric.carlson@apple.com> · 80811805
      eric.carlson@apple.com authored
              Reviewed by Mark Rowe.
      
              https://bugs.webkit.org/show_bug.cgi?id=25177
      
              QTTrack's -media method always return NULL in 64-bit QTKit, so
              MediaPlayerPrivate::disableUnsupportedTracks should use
              QTTrackMediaTypeAttribute to get a track's type.
      
              * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
              (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42477 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      80811805
    • ggaren@apple.com's avatar
      2009-04-13 Geoffrey Garen <ggaren@apple.com> · 39bc926e
      ggaren@apple.com authored
              Reviewed by Cameron Zwarich.
      
              More fix for https://bugs.webkit.org/show_bug.cgi?id=21260
              Unbounded memory growth when churning elements with anonymous event handler functions
      
              Stop using protected event listeners on the window object.
      
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::mark): Mark our event listeners, since they're
              no longer protected.
      
              (WebCore::JSDOMWindow::addEventListener):
              (WebCore::JSDOMWindow::removeEventListener): Create unprotected event
              listeners, since we mark them now.
      
              * bindings/js/JSEventListener.h: Made some functions public so
              DOMWindow could call them.
      
              * bindings/js/JSNodeCustom.cpp: Moved markEventListeners to a header,
              so it could be shared.
      
              * bindings/scripts/CodeGeneratorJS.pm: Generate event listener marking
              and invalidating code for the DOMWindow.
      
              * dom/RegisteredEventListener.h:
              (WebCore::markEventListeners):
              (WebCore::invalidateEventListeners): Added helper functions.
      
              * page/DOMWindow.idl: Make the window's event listener attributes not
              protected.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42476 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      39bc926e
    • eric.carlson@apple.com's avatar
      2009-04-13 Eric Carlson <eric.carlson@apple.com> · ff925eee
      eric.carlson@apple.com authored
              Reviewed by Mark Rowe.
      
              OS X standalone media documents should not switch from <video> to <embed> when 
              QTKit load state is QTMovieLoadStateLoading as that happens frequently when a loading
              with a slow network connection or when a movie is not saved fast-start.
      
              * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
              (WebCore::MediaPlayerPrivate::updateStates): Don't open movie with plug-in when QTKit's
              loadstate is QTMovieLoadStateLoading, wait until it drops below QTMovieLoadStateError.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42475 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ff925eee
    • dimich@chromium.org's avatar
      2009-04-13 Dmitry Titov <dimich@chromium.org> · 56ff5c47
      dimich@chromium.org authored
              Reviewed by Darin Adler.
      
              https://bugs.webkit.org/show_bug.cgi?id=24453
              REGRESSION: If setTimeout is called on a iframe's window, the DOM changes to
              the main document that timer callback makes are not flushed.
      
              * bindings/js/ScheduledAction.cpp:
              (WebCore::ScheduledAction::execute):
              Use Document::updateStyleForAllDocuments() instead of document->updateStyleIfNeeded()
              since timers may affect documents other then their own.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42474 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      56ff5c47
    • kov@webkit.org's avatar
      2009-04-13 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> · 8a6603f7
      kov@webkit.org authored
              Reviewed by David Hyatt.
      
              Check document for nullity to avoid crashing on GTK+, when
              creating the WebView.
      
              * page/FrameView.cpp:
              (WebCore::FrameView::needsLayout):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42473 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8a6603f7
    • adachan@apple.com's avatar
      Forgot to capitalize the "US". · 568b988f
      adachan@apple.com authored
              * platform/text/win/TextBreakIteratorInternalICUWin.cpp:
              (WebCore::currentTextBreakLocaleID):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42472 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      568b988f
    • adachan@apple.com's avatar
      <rdar://problem/6564956> URL field double-click selects entire domain,... · 25ce3837
      adachan@apple.com authored
              <rdar://problem/6564956> URL field double-click selects entire domain, rather than single word or entire URL
              Revert back to the old word breaking behavior by using en_US_POSIX locale.        
      
              Reviewed by Steve Falkenburg.
      
              * platform/text/win/TextBreakIteratorInternalICUWin.cpp:
              (WebCore::currentTextBreakLocaleID):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42471 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      25ce3837
    • kdecker@apple.com's avatar
      Reviewed by Darin. · 97ca4d03
      kdecker@apple.com authored
              <rdar://problem/6784955> REGRESSION: closing a tab containing a PDF causes world leaks
              
              Simplify the _trackFirstResponder method by just caching the value instead of retaining
              a Cocoa object.
              
              * WebView/WebPDFView.h: Eliminated trackedFirstResponder object and replaced it with
              a firstResponderIsPDFDocumentView boolean.
              * WebView/WebPDFView.mm: 
              (-[WebPDFView dealloc]): Removed no longer necessary ASSERT.
              (-[WebPDFView viewWillMoveToWindow:]): Removed call to release and nil-out trackedFirstResponder,
              which no longer exists. In the new code all we do now is set firstResponderIsPDFDocumentView to NO.
              (-[WebPDFView _trackFirstResponder]): Rewrote this method to just cache the value instead
              of retaining an object.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42470 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      97ca4d03
    • darin@apple.com's avatar
      2009-04-13 Darin Adler <darin@apple.com> · a27e190b
      darin@apple.com authored
              Reviewed by Mark Rowe.
      
              * Scripts/check-for-exit-time-destructors: Add ERROR: and WARNING: prefixes to
              make these scripts work better with the build window in new versions of Xcode.
              * Scripts/check-for-global-initializers: Ditto.
              * Scripts/check-for-weak-vtables: Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42469 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a27e190b
    • darin@apple.com's avatar
      2009-04-13 Darin Adler <darin@apple.com> · 46f4848c
      darin@apple.com authored
              Reviewed by Dan Bernstein.
      
              * platform/cf/BinaryPropertyList.cpp: Added comment.
              * platform/cf/BinaryPropertyList.h: Fixed mistakes in comments.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42468 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      46f4848c
    • darin@apple.com's avatar
      WebCore: · c79077ea
      darin@apple.com authored
      2009-04-13  Darin Adler  <darin@apple.com>
      
              Reviewed by Dan Bernstein.
      
              Bug 25158: hit testing doesn't work right in some cases involving anonymous blocks
              https://bugs.webkit.org/show_bug.cgi?id=25158
              rdar://problem/6769693
      
              Test: editing/selection/click-after-nested-block.html
      
              * rendering/RenderBlock.cpp:
              (WebCore::isChildHitTestCandidate): Added. Helper so the two loops in positionForPoint
              can share code.
              (WebCore::RenderBlock::positionForPoint): Removed unneeded special case for first
              child box. Changed special case for last child box to propertly handle the various
              types of child box that are not hit test candidates (the same ones already handled
              by the hit test loop below), adding in a loop so we find the last candidate.
      
      LayoutTests:
      
      2009-04-13  Darin Adler  <darin@apple.com>
      
              Reviewed by Dan Bernstein.
      
              Bug 25158: hit testing doesn't work right in some cases involving anonymous blocks
              https://bugs.webkit.org/show_bug.cgi?id=25158
              rdar://problem/6769693
      
              * editing/selection/click-after-nested-block-expected.txt: Added.
              * editing/selection/click-after-nested-block.html: Added.
      
              * fast/events/pointer-events-expected.txt: Updated since this is now a plain-text test.
              * fast/events/pointer-events.html: Changed this to a plain-text test, because the old
              results reflected a difference in hit testing behavior that this test was not intended
              to exercise and it's better to have the test be more cross-platform. Also removed
              unneeded use of waitUntilDone.
      
              * fast/js/finally-codegen-failure.html: Replaced with standard wrapper created by
              running the make-js-test-wrappers script. If we want to include type and charset
              attributes in the script elements, we can change make-js-test-wrappers to do that
              for all tests at some point.
              * fast/js/function-apply-aliased.html: Ditto.
              * fast/js/function-call-aliased.html: Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42467 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c79077ea
    • ggaren@apple.com's avatar
      JavaScriptCore: · 640be50f
      ggaren@apple.com authored
      2009-04-13  Geoffrey Garen  <ggaren@apple.com>
      
              Reviewed by Sam Weinig.
      
              Disabled another JavaScriptCore test because it fails on Windows but
              not Mac, so it makes the bots red.
      
              * tests/mozilla/expected.html:
      
      WebKitTools:
      
      2009-04-13  Geoffrey Garen  <ggaren@apple.com>
      
              Reviewed by Sam Weinig.
      
              Disabled another JavaScriptCore test because it fails on Windows but
              not Mac, so it makes the bots red.
      
              * Scripts/run-javascriptcore-tests:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42466 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      640be50f
    • hyatt@apple.com's avatar
      Update accessibility layout test from last checkin. · 6e8e5f21
      hyatt@apple.com authored
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6e8e5f21
    • hyatt@apple.com's avatar
      Webcore: · aa5afdb5
      hyatt@apple.com authored
      2009-04-13  David Hyatt  <hyatt@apple.com>
      
              Reviewed by Sam Weinig.
      
              Fix for https://bugs.webkit.org/show_bug.cgi?id=25125.  Rework scrolling so that a layout happens first when
              it's already needed so that the code doesn't end up making bad decisions based off invalid document sizes.
      
              * WebCore.base.exp:
              * page/FrameView.h:
              (WebCore::FrameView::visibleContentsResized):
              * platform/ScrollView.cpp:
              (WebCore::ScrollView::ScrollView):
              (WebCore::ScrollView::updateScrollbars):
              * platform/ScrollView.h:
      
      WebKit/mac:
      
      2009-04-13  David Hyatt  <hyatt@apple.com>
      
              Reviewed by Sam Weinig.
      
              Fix for https://bugs.webkit.org/show_bug.cgi?id=25125.  Rework scrolling so that a layout happens first when
              it's already needed so that the code doesn't end up making bad decisions based off invalid document sizes.
      
              This patch also eliminates WebHTMLView's separate notion of needing a layout and just consolidates it with
              WebCore's notion of needing layout.
      
              * WebView/WebDynamicScrollBarsView.m:
              (-[WebDynamicScrollBarsView updateScrollers]):
              * WebView/WebHTMLView.mm:
              (-[WebHTMLView _frameOrBoundsChanged]):
              (-[WebHTMLView initWithFrame:]):
              (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
              (-[WebHTMLView setNeedsLayout:]):
              (-[WebHTMLView _layoutIfNeeded]):
              (-[WebHTMLView _needsLayout]):
              * WebView/WebHTMLViewInternal.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42464 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      aa5afdb5
    • aroben@apple.com's avatar
      Windows part 2 of <rdar://5438063> Saving history containing 100,000 entries... · efcf1d0c
      aroben@apple.com authored
      Windows part 2 of <rdar://5438063> Saving history containing 100,000 entries causes pauses of 2s while browsing
      
      WebCore:
      
              Add SharedBuffer::wrapCFData
      
              This is the CF-equivalent of wrapNSData.
      
              Reviewed by Brady Eidson.
      
              * platform/SharedBuffer.h:
              * platform/cf/SharedBufferCF.cpp:
              (WebCore::SharedBuffer::wrapCFData):
      
      WebKit/win:
      
              Windows part 2 of <rdar://5438063> Saving history containing 100,000
              entries causes pauses of 2s while browsing
      
              Reviewed by Brady Eidson.
      
              * Interfaces/IWebHistoryPrivate.idl: Added data, analagous to
              WebKit/mac's -[WebHistory _data] method.
      
              * WebHistory.cpp:
              (WebHistory::saveHistoryGuts): Changed to call data() to get the data for
              saving.
              (WebHistory::data): Added. Returns the data for saving as an IStream.
              (WebHistory::data): Added. Returns the data for saving as a CFDataRef.
      
              * WebHistory.h: Added data.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42463 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      efcf1d0c
    • kov@webkit.org's avatar
      2009-04-13 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> · 751c0a05
      kov@webkit.org authored
              Rubber-stamped by Holger Freyther.
      
              Further massage tests to disable tests that are failingto make the
              results more useful.
      
              * platform/gtk/Skipped:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42462 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      751c0a05
    • ggaren@apple.com's avatar
      JavaScriptCore: · 442bbec8
      ggaren@apple.com authored
      2009-04-13  Geoffrey Garen  <ggaren@apple.com>
      
              Reviewed by Sam Weinig.
              
              Disabled two JavaScriptCore tests because they fail on Window or Mac but
              not both, so they make the bots red.
      
              * tests/mozilla/expected.html: Updated expected results.
      
      WebKitTools:
      
      2009-04-13  Geoffrey Garen  <ggaren@apple.com>
      
              Reviewed by Sam Weinig.
      
              Disabled two JavaScriptCore tests because they fail on Window or Mac but
              not both, so they make the bots red.
      
              * Scripts/run-javascriptcore-tests:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42461 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      442bbec8
    • justin.garcia@apple.com's avatar
      Adding a comment to my previous code change. · 2c57beba
      justin.garcia@apple.com authored
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42460 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2c57beba
    • darin@apple.com's avatar
      2009-04-13 Darin Adler <darin@apple.com> · 5843eb42
      darin@apple.com authored
              * WebView/WebViewPrivate.h: Updated comments.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42459 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5843eb42
    • mitz@apple.com's avatar
      - build fix · acc5d87d
      mitz@apple.com authored
              * page/EventHandler.cpp:
              (WebCore::documentPointForWindowPoint):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42458 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      acc5d87d
    • antti@apple.com's avatar
      WebCore: · 1fef7a17
      antti@apple.com authored
      2009-04-13  Antti Koivisto  <antti@apple.com>
      
              Reviewed by Darin Adler.
      
              <rdar://problem/6740294> Increase the connection count per host
              
              Try to use six connections per host if possible.
      
              * WebCore.base.exp:
              * loader/loader.cpp:
              (WebCore::Loader::Loader):
              * platform/mac/WebCoreSystemInterface.h:
              * platform/mac/WebCoreSystemInterface.mm:
              * platform/network/ResourceRequestBase.cpp:
              (WebCore::initMaximumHTTPConnectionCountPerHost):
              * platform/network/ResourceRequestBase.h:
              * platform/network/mac/ResourceRequestMac.mm:
              (WebCore::initMaximumHTTPConnectionCountPerHost):
      
      WebKit/mac:
      
      2009-04-13  Antti Koivisto  <antti@apple.com>
      
              Reviewed by Darin Adler.
              
              <rdar://problem/6740294> Increase the connection count per host
      
              * WebCoreSupport/WebSystemInterface.m:
              (InitWebCoreSystemInterface):
      
      WebKitLibraries:
      
      2009-04-13  Antti Koivisto  <antti@apple.com>
      
              Reviewed by Darin Adler.
              
              <rdar://problem/6740294> Increase the connection count per host
      
              * WebKitSystemInterface.h:
              * libWebKitSystemInterfaceLeopard.a:
              * libWebKitSystemInterfaceTiger.a:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42457 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      1fef7a17
    • justin.garcia@apple.com's avatar
      WebCore: · d919c450
      justin.garcia@apple.com authored
      2009-04-13  Justin Garcia  <justin.garcia@apple.com>
      
              Reviewed by Adele Peterson.
      
              https://bugs.webkit.org/show_bug.cgi?id=25153
              Can't place the caret into text field that scrolls the window on focus
              
              We refetch the target node in the shadow node case, and when we do so the window coordinate for the mouse event may
              be invalid because of scrolling that the focus handler did.  Cache the document point (that we derived from the window
              coordinate) and use that any time we refetch.
      
              * page/EventHandler.cpp:
              (WebCore::documentPointForWindowPoint):
              (WebCore::EventHandler::handleMousePressEvent):
              (WebCore::EventHandler::prepareMouseEvent):
      
      LayoutTests:
      
      2009-04-13  Justin Garcia  <justin.garcia@apple.com>
      
              Reviewed by Adele Peterson.
              
              <rdar://problem/6748324> REGRESSION (Kirkwood): Can't type in Netflix search field
      
              * fast/forms/25153-expected.txt: Added.
              * fast/forms/25153.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42456 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d919c450
    • weinig@apple.com's avatar
      2009-04-13 Sam Weinig <sam@webkit.org> · 20f53539
      weinig@apple.com authored
              Fix bad expected result.
      
              * fast/frames/frame-unload-crash-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42455 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      20f53539
    • weinig@apple.com's avatar
      2009-04-13 Sam Weinig <sam@webkit.org> · 17db6edc
      weinig@apple.com authored
              Reviewed by Geoffrey Garen.
      
              Rename JavaScriptCanOpenWindowsAutomatically to javaScriptCanOpenWindowsAutomatically
              to conform to our style guidelines.
      
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::allowPopUp):
              * page/Settings.h:
              (WebCore::Settings::javaScriptCanOpenWindowsAutomatically):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42454 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      17db6edc
    • ggaren@apple.com's avatar
      2009-04-13 Geoffrey Garen <ggaren@apple.com> · 7520cd50
      ggaren@apple.com authored
              Mac build fix: Made another header private.
      
              * WebCore.xcodeproj/project.pbxproj:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42453 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7520cd50
    • dimich@chromium.org's avatar
      2009-04-13 Jian Li <jianli@chromium.org> · 7669881b
      dimich@chromium.org authored
              Reviewed by Darin Fisher.
      
              https://bugs.webkit.org/show_bug.cgi?id=25121
              Upstream changes to handle error messages from V8 when running worker script.
      
              * bindings/v8/WorkerContextExecutionProxy.cpp:
              (WebCore::reportFatalErrorInV8):
              (WebCore::handleConsoleMessage):
              (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
              (WebCore::WorkerContextExecutionProxy::dispose):
              (WebCore::WorkerContextExecutionProxy::initV8IfNeeded):
              (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
              (WebCore::WorkerContextExecutionProxy::evaluate):
              * bindings/v8/WorkerContextExecutionProxy.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42452 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7669881b
    • beidson@apple.com's avatar
      2009-04-13 Brady Eidson <beidson@apple.com> · e4268f65
      beidson@apple.com authored
              Reviewed by Tim Hatcher
      
              Tweak my last check-in, moving the thread violation check up to the API-level calls so the logging is more
              useful to developers/users.
      
              * WebView/WebFrame.mm:
              (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]): If not on the main thread, only
                perform the "call on main thead" workaround, as the log/exception raising is now up at the API level.
              (-[WebFrame loadData:MIMEType:textEncodingName:baseURL:]): Perform a thread violation check here so logging
                is more meaningful.
              (-[WebFrame loadHTMLString:baseURL:]): Ditto.
              (-[WebFrame loadAlternateHTMLString:baseURL:forUnreachableURL:]): Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42451 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e4268f65
    • ggaren@apple.com's avatar
      2009-04-13 Geoffrey Garen <ggaren@apple.com> · 4cdaed07
      ggaren@apple.com authored
              Build fix: Made setInlineEventListenerForType not inline, since Document
              calls it now. Made RegisteredEventListener.h a private header on Mac,
              so WebKit can use it.
      
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::setInlineEventListenerForType):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42450 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4cdaed07
    • mitz@apple.com's avatar
      Reviewed by Sam Weinig. · 03fbdb72
      mitz@apple.com authored
              - fix <rdar://problem/6404439> REGRESSION: Overlapping text and other
                layout issues in View Sample feature of MYOB FIrstEdge v3
      
              * page/Navigator.cpp:
              (WebCore::shouldHideFourDot): Added "tdqm_loader.js" to the list of
              JavaScript files this quirk applies to.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42449 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      03fbdb72
    • beidson@apple.com's avatar
      2009-04-13 Brady Eidson <beidson@apple.com> · 3ed06b77
      beidson@apple.com authored
              Reviewed by Kevin Decker
      
              <rdar://problem/6712063> Garmin WebUpdater crashes
      
              * WebView/WebFrame.mm:
              (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):  If not called on the main thread,
                add a ThreadViolationCheckRoundTwo() call to either log or raise an exception.  In the case where it's
                only a log, reschedule the _loadData call to occur on the main thread.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42448 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3ed06b77
    • weinig@apple.com's avatar
      WebCore: · c4537540
      weinig@apple.com authored
      2009-04-13  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Oliver Hunt.
      
              Move open and showModalDialog functions out of JSDOMWindowBase
              and into JSDOMWindow by partially generating them.
      
              This slightly changes the behavior of getting window.showModalDialog
              when the embedding app does not support it to return undefined regardless
              of shadowing.  This should not be an issue in a practice, but will be addressed
              when we add a generic way to handle runtime specialization of property
              access.
      
              * DerivedSources.make: Remove JSDOMWindowBase.lut.h
              * WebCore.xcodeproj/project.pbxproj: Ditto.
              * bindings/js/JSDOMWindowBase.cpp:
              (WebCore::):
              (WebCore::JSDOMWindowBase::getOwnPropertySlot): Move canShowModalDialog check from
              here to JSDOMWindow::customGetOwnPropertySlot.
              (WebCore::JSDOMWindowBase::put): Remove dead code.
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::createWindow):
              (WebCore::JSDOMWindow::open):
              (WebCore::JSDOMWindow::showModalDialog):
              * bindings/js/JSDOMWindowCustom.h:
              (WebCore::JSDOMWindow::customGetOwnPropertySlot):
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::parseModalDialogFeatures): Move from JSDOMWindowBase.
              (WebCore::DOMWindow::allowPopUp): Ditto.
              (WebCore::DOMWindow::canShowModalDialog): Ditto.
              (WebCore::DOMWindow::canShowModalDialogNow): Ditto.
              * page/DOMWindow.h:
              * page/DOMWindow.idl:
      
      LayoutTests:
      
      2009-04-13  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Oliver Hunt.
      
              Update tests after moving showModalDialog from JSDOMWindowBase to
              JSDOMWindow and slightly changing the behavior when showModalDialog
              is not available, as is the case for DumpRenderTree.
      
              * fast/dom/Window/window-function-frame-getter-precedence-expected.txt:
              * fast/dom/Window/window-properties-expected.txt:
              * platform/mac-leopard/fast/dom/Window/window-properties-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42447 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c4537540
    • ggaren@apple.com's avatar
      2009-04-13 Geoffrey Garen <ggaren@apple.com> · bc6ef281
      ggaren@apple.com authored
              Reviewed by Sam Weinig.
      
              Moved storage for window event listeners into the window object.
      
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::addEventListener):
              (WebCore::JSDOMWindow::removeEventListener): Add / remove window event
              listeners to / from the window object.
      
              * dom/Document.cpp:
              (WebCore::Document::removeAllEventListeners):
              (WebCore::Document::clear):
              (WebCore::Document::setWindowInlineEventListenerForTypeAndAttribute): Moved
              a bunch of code to the DOMWindow class, and left behind a few calls through
              to DOMWindow, to support legacy clients. (Eventually, these will go away, too.)
      
              * dom/Document.h: ditto.
      
              * dom/Node.cpp:
              (WebCore::Node::dispatchGenericEvent):
              (WebCore::Node::dispatchWindowEvent): Dipatch window events on the window
              object, not the document.
      
              * dom/Node.h:
              * dom/RegisteredEventListener.h: Moved RegisteredEventListenerVector
              declaration, since it's required in more places now.
      
              * history/CachedFrame.cpp:
              (WebCore::CachedFrame::clear): Updated for rename. Also, remove event
              listeners before detaching and clearing the document's window pointer,
              since the the document needs its window pointer in order to tell the window
              to clear its event listeners.
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::stopLoading):
              (WebCore::FrameLoader::canCachePageContainingThisFrame):
              (WebCore::FrameLoader::logCanCacheFrameDecision): Updated for rename, and
              movement of window event listeners into the window.
      
              * loader/ImageDocument.cpp:
              (WebCore::ImageDocument::createDocumentStructure): Updated for movement
              of window event listeners into the window.
      
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::handleEvent):
              (WebCore::DOMWindow::addEventListener):
              (WebCore::DOMWindow::removeEventListener):
              (WebCore::DOMWindow::removeAllEventListeners):
              (WebCore::DOMWindow::hasEventListener):
              (WebCore::DOMWindow::setInlineEventListenerForType):
              (WebCore::DOMWindow::removeInlineEventListenerForType):
              (WebCore::DOMWindow::inlineEventListenerForType):
              (WebCore::DOMWindow::addPendingFrameUnloadEventCount):
              (WebCore::DOMWindow::removePendingFrameUnloadEventCount):
              (WebCore::DOMWindow::addPendingFrameBeforeUnloadEventCount):
              (WebCore::DOMWindow::removePendingFrameBeforeUnloadEventCount):
              * page/DOMWindow.h: Moved a bunch of code to the DOMWindow class, from the Document.
      
              * page/Frame.cpp:
              (WebCore::Frame::shouldClose): Updated for movement of window event listeners into the window.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42446 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      bc6ef281
    • bolsinga@apple.com's avatar
      2009-04-13 Greg Bolsinga <bolsinga@apple.com> · e6ca5d16
      bolsinga@apple.com authored
              Reviewed by Sam Weinig.
      
              https://bugs.webkit.org/show_bug.cgi?id=25149
      
              The Geolocation timer needs to start after the UA has granted permission.
      
              * bindings/js/JSGeolocationCustom.cpp: Use PassRefPtr<PositionOptions>
              (WebCore::JSGeolocation::getCurrentPosition):
              (WebCore::JSGeolocation::watchPosition):
              * page/Geolocation.cpp: Add a RefPtr<PositionOptions> so it can be used
              later when the timer is started. Change PositionOptions* to PassRefPtr<PositionOptions>
              where needed.
              (WebCore::Geolocation::GeoNotifier::GeoNotifier):
              (WebCore::Geolocation::GeoNotifier::startTimer):
              (WebCore::Geolocation::getCurrentPosition):
              (WebCore::Geolocation::watchPosition):
              (WebCore::Geolocation::setIsAllowed): Start the timer is the UA allows
              (WebCore::Geolocation::startTimer):
              (WebCore::Geolocation::startTimersForOneShots):
              (WebCore::Geolocation::startTimersForWatchers):
              (WebCore::Geolocation::startTimers):
              * page/Geolocation.h:
              (WebCore::Geolocation::GeoNotifier::create):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42445 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e6ca5d16
    • pam@chromium.org's avatar
      2009-04-13 Pamela Greene <pam@chromium.org> · c43e9651
      pam@chromium.org authored
              Reviewed by Darin Fisher.
      
              Fix Chromium (V8) build by renaming methods to match changes
              in http://trac.webkit.org/changeset/42377.
      
              https://bugs.webkit.org/show_bug.cgi?id=25141
      
              * bindings/v8/ScheduledAction.cpp:
           (WebCore::ScheduledAction::execute): updateRendering() -> updateStyleIfNeeded()
              * bindings/v8/V8AbstractEventListener.cpp:
              (WebCore::V8AbstractEventListener::handleEvent): updateDocumentsRendering() -> updateStyleForAllDocuments()
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42444 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c43e9651
    • darin@apple.com's avatar
      2009-04-13 Darin Adler <darin@apple.com> · eb1d0148
      darin@apple.com authored
              * Scripts/make-js-test-wrappers: Added another exception.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42443 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      eb1d0148
    • darin@chromium.org's avatar
      2009-04-13 Darin Fisher <darin@chromium.org> · a427ee23
      darin@chromium.org authored
              Reviewed by Darin Adler.
      
              https://bugs.webkit.org/show_bug.cgi?id=25136
              CRASH in DocumentLoader::removeSubresourceLoader due to null m_frame
      
              Test: fast/frames/frame-unload-crash.html
      
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::updateLoading): Added null check of m_frame.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42442 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a427ee23
    • weinig@apple.com's avatar
      WebCore: · 5851e2bb
      weinig@apple.com authored
      2009-04-13  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Tim Hatcher.
      
              Put the MessagePort constructor back in ENABLE_CHANNEL_MESSAGING.
      
              * page/DOMWindow.idl:
      
      LayoutTests:
      
      2009-04-13  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Tim Hatcher.
      
              Update test results after putting the MessagePort constructor
              back in ENABLE_CHANNEL_MESSAGING.
      
              * fast/dom/Window/window-properties-expected.txt:
              * fast/js/global-constructors-expected.txt:
              * platform/mac-leopard/fast/dom/Window/window-properties-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42441 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5851e2bb
    • bolsinga@apple.com's avatar
      2009-04-13 Greg Bolsinga <bolsinga@apple.com> · 80df361c
      bolsinga@apple.com authored
              Fix GTK build break.
      
              * platform/gtk/GeolocationServiceGtk.cpp:
              (WebCore::GeolocationServiceGtk::updatePosition):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42440 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      80df361c
    • hyatt@apple.com's avatar
      2009-04-13 David Hyatt <hyatt@apple.com> · 094f41bd
      hyatt@apple.com authored
              Reviewed by Darin Adler and Dan Bernstein.
      
              Assertion in updateStyleForAllDocuments.  Make sure to unscheduleStyleRecalc when an object goes into
              the page cache.  Disallow scheduling of style recalcs on a document that is already in the page cache.
              Schedule a style recalc if needed when an object comes out of the page cache.
      
              * dom/Document.cpp:
              (WebCore::Document::scheduleStyleRecalc):
              (WebCore::Document::setInPageCache):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42439 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      094f41bd
    • timothy@apple.com's avatar
      Correctly sort (program) scripts in the Scripts panel popup menu. · 95178e5b
      timothy@apple.com authored
              Reviewed by Ada Chan.
      
              * inspector/front-end/ScriptsPanel.js:
              (WebInspector.ScriptsPanel.prototype._addScriptToFilesMenu): Refactor the code
              and sort "(program)" options by the sourceID to maintain some order.
              * inspector/front-end/utilities.js:
              (indexOfObjectInListSortedByFunction): Fix a bug where identical objects would cause
              an incorrect return value that confuses insertionIndexForObjectInListSortedByFunction.
              Just set 'first' and break so the correct result will be returned.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42438 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      95178e5b