1. 26 Jan, 2009 16 commits
    • hyatt@apple.com's avatar
      2009-01-26 David Hyatt <hyatt@apple.com> · d0301a5e
      hyatt@apple.com authored
              Drop support for display:compact.
      
              (1) display:compact is no longer part of CSS2.1.
              (2) Shipping Safari has completely broken compact support with severely broken rendering
              (all of the compact text just piles on top of the text in the inserted block and on top of itself as well).
              (3) This has been broken in WebKit for years (ever since blocks converted to painting lines directly) without
              anyone even noticing.
      
              Reviewed by Eric Seidel
      
              * rendering/InlineFlowBox.cpp:
              (WebCore::InlineFlowBox::placeBoxesHorizontally):
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::handleSpecialChild):
              (WebCore::RenderBlock::handleRunInChild):
              (WebCore::RenderBlock::layoutBlockChildren):
              (WebCore::RenderBlock::paint):
              (WebCore::RenderBlock::paintObject):
              (WebCore::RenderBlock::nodeAtPoint):
              (WebCore::RenderBlock::positionForCoordinates):
              (WebCore::shouldCheckLines):
              (WebCore::getHeightForLineCount):
              (WebCore::RenderBlock::renderName):
              * rendering/RenderBlock.h:
              * rendering/RenderBox.cpp:
              (WebCore::RenderBox::sizesToIntrinsicWidth):
              * rendering/RenderBox.h:
              (WebCore::RenderBox::width):
              (WebCore::RenderBox::height):
              (WebCore::RenderBox::size):
              (WebCore::RenderBox::frameRect):
              * rendering/RenderFlow.cpp:
              (WebCore::RenderFlow::paintLines):
              (WebCore::RenderFlow::hitTestLines):
              (WebCore::RenderFlow::absoluteClippedOverflowRect):
              (WebCore::RenderFlow::linesBoundingBox):
              * rendering/RenderObject.h:
              (WebCore::RenderObject::isInline):
              * rendering/bidi.cpp:
              (WebCore::RenderBlock::computeHorizontalPositionsForLine):
              (WebCore::RenderBlock::layoutInlineChildren):
              * rendering/bidi.h:
              (WebCore::BidiRun::BidiRun):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40258 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d0301a5e
    • mrowe@apple.com's avatar
      Fix the build. · 66fc1a42
      mrowe@apple.com authored
      Remove -Wformat=2 from the warning flags as newer versions of GCC emit
      warnings about non-literal format strings for uses of our UI_STRING macro.
      
      * Configurations/Base.xcconfig:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40257 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      66fc1a42
    • pol@apple.com's avatar
      2009-01-26 Pierre-Olivier Latour <pol@apple.com> · 1bff8421
      pol@apple.com authored
              Tweaked again earlier fix, this time just to print a warning and not abort if
              attempting to generate pixel results and Perian is installed.
      
              https://bugs.webkit.org/show_bug.cgi?id=22615
      
              * Scripts/run-webkit-tests:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40256 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      1bff8421
    • darin@chromium.org's avatar
      2009-01-26 Adam Langley <agl@google.com> · d9112996
      darin@chromium.org authored
              Reviewed by Nikolas Zimmermann.
      
              gtk2drawing: fix compiler warnings
      
              g_object_set_data expects a gpointer as the last argument. Cast the
                TRUE/FALSE values to avoid a warning.
              gtk_tree_view_column_new doesn't return a GtkWidget.
      
              * platform/gtk/gtk2drawing.c:
              (setup_widget_prototype):
              (moz_gtk_get_combo_box_inner_button):
              (moz_gtk_get_combo_box_button_inner_widgets):
              (ensure_combo_box_widgets):
              (moz_gtk_get_combo_box_entry_inner_widgets):
              (moz_gtk_get_combo_box_entry_arrow):
              (ensure_combo_box_entry_widgets):
              (ensure_toolbar_widget):
              (ensure_menu_bar_item_widget):
              (ensure_menu_popup_widget):
              (ensure_menu_item_widget):
              (ensure_image_menu_item_widget):
              (ensure_menu_separator_widget):
              (ensure_check_menu_item_widget):
              (ensure_tree_header_cell_widget):
              (moz_gtk_entry_paint):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40255 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d9112996
    • hyatt@apple.com's avatar
      2009-01-26 David Hyatt <hyatt@apple.com> · 831beecd
      hyatt@apple.com authored
              Change display:run-in handling so that we no longer reuse RenderBlock as though it is an inline flow.
              Instead we create a new RenderInline, move the RenderBlock's children underneath it, and then set the
              inline as the new element's renderer.
      
              Reviewed by Dan Bernstein
      
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::handleRunInChild):
              * rendering/RenderInline.cpp:
              (WebCore::RenderInline::renderName):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40254 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      831beecd
    • mrowe@apple.com's avatar
      Clean up after r40240. · 88bc8bec
      mrowe@apple.com authored
      Rubber-stamped by Sam Weinig.
      
      * WebKit.xcodeproj/project.pbxproj: Reinstate WebKitPluginHost.defs.
      
      * Configurations/Base.xcconfig: Don't dead code strip in debug builds for now as it leads to link errors.
      * Plugins/Hosted/HostedNetscapePluginStream.mm: Revert change that is no longer needed now that WebKitPluginHost.defs
      is back in the build.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40253 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      88bc8bec
    • aroben@apple.com's avatar
      Fix an assertion failure when Safari loads an error page · f05da8ee
      aroben@apple.com authored
              Reviewed by Alexey Proskuryakov.
      
              * WebFrame.cpp:
              (WebFrame::loadData): Use the two-argument version of KURL and
              MarshallingHelpers::BSTRToKURL, for reasons mentioned in r40248.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40252 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f05da8ee
    • christian@webkit.org's avatar
      2009-01-26 Christian Dywan <christian@twotoasts.de> · 56b2d488
      christian@webkit.org authored
              Rubber stamped by Holger Freyther.
      
              * GtkLauncher/main.c:
              (main): Initialize threads, which is required for libSoup.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40251 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      56b2d488
    • hausmann@webkit.org's avatar
      2009-01-26 David Boddie <dboddie@trolltech.com> · 90fdc29d
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Doc: qdoc fix for a link to a property and added a basic description of the offline caching and storage features from HTML 5.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40250 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      90fdc29d
    • dglazkov@chromium.org's avatar
      2009-01-26 Dimitri Glazkov <dglazkov@chromium.org> · bda75dc2
      dglazkov@chromium.org authored
              Reviewed by Darin Adler.
      
              https://bugs.webkit.org/show_bug.cgi?id=23480
              Add missing method stubs to BackForwardListChromium.
      
              * history/BackForwardListChromium.cpp:
              (WebCore::BackForwardList::backItem):
              (WebCore::BackForwardList::forwardItem):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40249 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      bda75dc2
    • aroben@apple.com's avatar
      Fix an assertion on launch in KURL::KURL · b5f26d5d
      aroben@apple.com authored
              All URL strings passed in to the WebKit API need to be passed to
              MarshallingHelpers::BSTRToKURL so that they may be properly parsed.
      
              Reviewed by Alexey Proskuryakov.
      
              * MarshallingHelpers.cpp:
              (MarshallingHelpers::BSTRToKURL): Changed to use the two-argument
              constructor for KURL so that the strings will be parsed rather than
              assumed to be in the correct encoding/form.
      
              * WebResource.cpp:
              (WebResource::initWithData):
              * WebURLResponse.cpp:
              (WebURLResponse::initWithURL):
              * WebView.cpp:
              (WebView::userAgentForURL):
              (WebView::copyURL):
              Changed to use MarshallingHelpers::BSTRToKURL instead of trying to do
              the work manually.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40248 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b5f26d5d
    • darin@apple.com's avatar
      2009-01-26 Darin Adler <darin@apple.com> · 238ba7cd
      darin@apple.com authored
              Requested by David Hyatt.
      
              * platform/mac/fast/table/form-with-table-style-expected.checksum: Updated to reflect
              the progression; we now render things we used to fail to render.
              * platform/mac/fast/table/form-with-table-style-expected.png: Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40247 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      238ba7cd
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 463f6c45
      darin@apple.com authored
              Try to fix GTK build.
      
              * webkit/webkitwebview.cpp: Added include of FloatQuad.h.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40246 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      463f6c45
    • darin@apple.com's avatar
      WebKit: · f5e605e0
      darin@apple.com authored
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Try to fix full build on Mac Leopard.
      
              * WebKit.xcodeproj/project.pbxproj: Removed WebKitPluginClient.defs from the WebKit target.
              Maybe this is temporary, but I had to do it to get the full build to succeed.
      
      WebKit/mac:
      
      2009-01-25  Darin Adler  <darin@apple.com>
      
              * Plugins/Hosted/HostedNetscapePluginStream.mm: Added a missing extern "C".
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40245 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f5e605e0
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 94f49cef
      darin@apple.com authored
              Try to fix Windows build.
      
              * WebView.cpp: Added FloatQuad.h.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40244 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      94f49cef
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 9b977f45
      darin@apple.com authored
              Try to fix Tiger buildbot.
      
              * WebCore.xcodeproj/project.pbxproj: Turn off cast-qual for WebDashboardRegion.m.
              * page/mac/WebDashboardRegion.m:
              (typeName): Added.
              (-[WebDashboardRegion description]): Use typeName.
              (-[WebDashboardRegion isEqual:]): Added comment.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40243 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9b977f45
  2. 25 Jan, 2009 22 commits
    • ap@webkit.org's avatar
      Reviewed by Darin Adler. · 3db1ca14
      ap@webkit.org authored
              https://bugs.webkit.org/show_bug.cgi?id=23535
              Strengthen debug checks in KURL
      
              Covered (and prompted) by existing tests.
      
              * platform/KURL.cpp:
              (WebCore::checkEncodedString): Check that the first character of the URL is an allowed
              first scheme character, not just that it isn't a slash.
              (WebCore::KURL::KURL): Assert that parsing didn't affect the string (which must be the case
              because of parsing being idempotent).
      
              * page/SecurityOrigin.cpp:
              (WebCore::SecurityOrigin::create): Added a check for the URL being valid - if it is not, an
              empty security origin is created.
              (WebCore::SecurityOrigin::createFromString): Parse the string as URL, do not just convert
              it - it is not guaranteed to be properly encoded.
      
              * dom/Document.cpp: (WebCore::Document::updateBaseURL): As documentURI is an arbitrary
              string, it needs to be parsed into an URL, not just converted into one.
      
              * html/CanvasRenderingContext2D.cpp: (WebCore::CanvasRenderingContext2D::createPattern):
              Create the security origin with createFromString() instead of create(). I do not know where
              the string comes from and whether it might not be properly encoded, but this change can't
              hurt, and makes the code slightly more clear.
      
              * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::accessControlCheck): Create the security
              origin with createFromString() instead of create(). The string comes from an HTTP response
              header, so it may not be a properly encoded URL.
      
              * loader/DocLoader.cpp: (WebCore::DocLoader::requestResource): Do not try to request using
              invalid URLs.
      
              * page/DOMWindow.cpp: (WebCore::DOMWindow::postMessage): Updated to call
              SecurityOrigin::createFromString() (no change in behavior).
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40242 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3db1ca14
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · ff3ec5a6
      darin@apple.com authored
              Discussed with Mark Rowe; not sure he reviewed it.
      
              * Configurations/Base.xcconfig: Add all the same warnings as in WebCore except for
              -Wcast-qual and -Wunused-parameter, which both need to be off at least for now.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40241 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ff3ec5a6
    • mrowe@apple.com's avatar
      Improve the consistency of settings in our .xcconfig files. · 08809b99
      mrowe@apple.com authored
      Rubber-stamped by Dan Bernstein.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40240 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      08809b99
    • hyatt@apple.com's avatar
      Land table/forms layout test progression. · 506f1b91
      hyatt@apple.com authored
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40239 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      506f1b91
    • hyatt@apple.com's avatar
      WebCore: · 8b2cd1fe
      hyatt@apple.com authored
      2009-01-25  David Hyatt  <hyatt@apple.com>
      
              Fix for https://bugs.webkit.org/show_bug.cgi?id=23524, lots of missing content in table sections.
      
              The new table code created a bug involving  markAllDescendantsWithFloatsForLayout, namely that it could
              end up marking ancestors of a block as needing layout when that block was still in the process of
              doing a layout.
      
              The fix is to add a parameter to markAllDescendantsWithFloatsForLayout that says whether or not
              we are "mid-layout."  If this flag is set, then the method will make sure to do only local dirtying
              of objects to avoid accidentally marking a clean ancestor as needing layout again.
      
              Ultimately the second parameter to setNeedsLayout and setChildNeedsLayout should just be removed,
              with a check of whether or not we are mid-layout being done by those methods instead.
      
              Reviewed by Oliver Hunt
      
              Added fast/repaint/dynamic-table-vertical-alignment-change.html
      
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::collapseMargins):
              (WebCore::RenderBlock::clearFloatsIfNeeded):
              (WebCore::RenderBlock::layoutBlockChildren):
              (WebCore::RenderBlock::markAllDescendantsWithFloatsForLayout):
              * rendering/RenderBlock.h:
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::removeFromObjectLists):
              * rendering/RenderObject.h:
              * rendering/RenderTableSection.cpp:
              (WebCore::RenderTableSection::layoutRows):
      
      LayoutTests:
      
      2009-01-25  David Hyatt  <hyatt@apple.com>
      
              Add layout test for https://bugs.webkit.org/show_bug.cgi?id=23524.
      
              Reviewed by Oliver Hunt
      
              * fast/repaint/dynamic-table-vertical-alignment-change.html: Added.
              * platform/mac/fast/repaint/dynamic-table-vertical-alignment-change-expected.checksum: Added.
              * platform/mac/fast/repaint/dynamic-table-vertical-alignment-change-expected.png: Added.
              * platform/mac/fast/repaint/dynamic-table-vertical-alignment-change-expected.txt: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40238 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8b2cd1fe
    • darin@apple.com's avatar
      JavaScriptCore: · 9f6b66c7
      darin@apple.com authored
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Mark Rowe.
      
              Bug 23352: Turn on more compiler warnings in the Mac build
              https://bugs.webkit.org/show_bug.cgi?id=23352
      
              Turn on the following warnings:
      
                  -Wcast-qual
                  -Wextra-tokens
                  -Wformat=2
                  -Winit-self
                  -Wmissing-noreturn
                  -Wpacked
                  -Wrendundant-decls
      
              * Configurations/Base.xcconfig: Added the new warnings. Switched to -Wextra instead of
              -W for clarity since we don't have to support the older versions of gcc that require the
              old -W syntax. Since we now use -Wformat=2, removed -Wformat-security. Also removed
              -Wno-format-y2k since we can have that one on now.
      
      WebCore:
      
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Mark Rowe.
      
              Bug 23352: Turn on more compiler warnings in the Mac build
              https://bugs.webkit.org/show_bug.cgi?id=23352
      
              Turn on the following warnings:
      
                  -Wcast-qual
                  -Wextra-tokens
                  -Wformat=2
                  -Winit-self
                  -Wmissing-noreturn
                  -Wpacked
                  -Wrendundant-decls
      
              * Configurations/Base.xcconfig: Added the new warnings. Switched to -Wextra instead of
              -W for clarity since we don't have to support the older versions of gcc that require the
              old -W syntax. Since we now use -Wformat=2, removed -Wformat-security. Also removed
              -Wno-format-y2k since we can have that one on now.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40237 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9f6b66c7
    • mitz@apple.com's avatar
      WebCore: · 2f1fee03
      mitz@apple.com authored
              Reviewed by Oliver Hunt.
      
              - fix <rdar://problem/6525618> REGRESSION (r39566): NewsFire crashes in
                string hashing code when opening a Digg RSS article
      
              Test: fast/loader/null-request-after-willSendRequest.html
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::loadItem): Null-check the request returned from
              the client's willSendRequest method.
      
      LayoutTests:
      
              Reviewed by Oliver Hunt.
      
              - test for <rdar://problem/6525618> REGRESSION (r39566): NewsFire crashes in
                string hashing code when opening a Digg RSS article
      
              * fast/loader/null-request-after-willSendRequest-expected.txt: Added.
              * fast/loader/null-request-after-willSendRequest.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40236 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2f1fee03
    • hyatt@apple.com's avatar
      2009-01-25 David Hyatt <hyatt@apple.com> · e007fb25
      hyatt@apple.com authored
              Fix for <rdar://problem/6525392> REGRESSION (r40180): Scroll wheel events over text scroll the page
              instead of the ancestor overflow (23525)
              
              Make sure that we always call scroll() on the nearest enclosing RenderBox.  No test case is possible
              here, since wheel scrolling is currently untestable (the offset varies from machine to machine).
      
              Reviewed by Dan Bernstein
      
              * page/EventHandler.cpp:
              (WebCore::scrollAndAcceptEvent):
              (WebCore::EventHandler::scrollOverflow):
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::enclosingBox):
              * rendering/RenderObject.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40235 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e007fb25
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 38d96eff
      darin@apple.com authored
              Reviewed by Dan Bernstein.
      
              Bug 23538: REGRESSION (r39969): Garbage text instead of blank content rendered when plug-ins are disabled
              https://bugs.webkit.org/show_bug.cgi?id=23538
              rdar://problem/6523719
      
              I'm not sure how to make a regression test for this, since it depends on plug-ins being disabled.
      
              The main problem here is that when plug-ins were disabled, the code ignored the classId attribute and
              the <embed> element entirely. That resulted in a page treating a Flash document as plain HTML rather
              than doing fallback.
      
              * rendering/RenderPartObject.cpp:
              (WebCore::createClassIdToTypeMap): Added. Broke this out into a separate function so we could get rid of an
              inelegant if statement.
              (WebCore::activeXType): Added. To avoid repeating the MIME type for ActiveX and possibly having a typo.
              (WebCore::havePlugin): Added. Helper function to make sure we don't forget the null check.
              (WebCore::serviceTypeForClassId): Give this function a return value since that's a more natural way to
              return a string than an "out" parameter.  Fixed the logic to only prefer the ActiveX type over the
              type guessed from the classId when there actually is an ActiveX plug-in to use. The old function assumed
              there was one, which I presume right for Chrome on Windows when plug-ins are enabled, but wrong in many
              other cases, and wrong all the time for all clients on Mac. We don't want to assume either way. Use the
              new havePlugin function so we handle the case where pluginData is 0.
              (WebCore::shouldUseEmbedDescendant): Renamed. Simplified the comment. Changed to use serviceTypeForClassId
              instead of the old version that used an out parameter. Always use the <embed> if there isn't a plug-in
              that knows how to handle <object> elements.
              (WebCore::RenderPartObject::updateWidget): Removed null checks of pluginData. The two functions that
              use this data still need to be called; they still do something even if no plug-ins are present. And
              they have now been corrected to handle 0 properly.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40234 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      38d96eff
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 4ce38c5a
      darin@apple.com authored
              * rendering/RenderMenuList.cpp: Fix build by adding back needed include.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40233 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4ce38c5a
    • darin@apple.com's avatar
      2009-01-25 Judit Jasz <jasy@inf.u-szeged.hu> · be5fbde7
      darin@apple.com authored
              Reviewed by Darin Adler.
              
              Compilation problem fixing 
              http://bugs.webkit.org/show_bug.cgi?id=23497
      
              * jit/JITCall.cpp:
              (JSC::JIT::compileOpCall): Use JSValuePtr::encode.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40232 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      be5fbde7
    • darin@apple.com's avatar
      JavaScriptCore: · ba165bd3
      darin@apple.com authored
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam Weinig.
      
              Bug 23352: Turn on more compiler warnings in the Mac build
              https://bugs.webkit.org/show_bug.cgi?id=23352
      
              Fourth patch: Deal with the last few stray warnings.
      
              * parser/Parser.cpp: Only declare jscyyparse if it's not already declared.
              This makes both separate compilation and all-in-one compilation work with the
              -Wredundant-decls warning.
      
      WebCore:
      
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam Weinig.
      
              Bug 23352: Turn on more compiler warnings in the Mac build
              https://bugs.webkit.org/show_bug.cgi?id=23352
      
              Fourth patch: Deal with the last few stray warnings.
      
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::firstLineBlock): Handle the const_cast a little better.
              Also make the local variable be a RenderBlock so the cast is closer to the code
              that guarantees it's correct.
      
              * rendering/SVGRenderTreeAsText.cpp:
              (WebCore::writeStyle): Put the enum into a local variable that's a built-in
              type before using it with TextStream, so we don't get a warning due to -Wsign-promo.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40231 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ba165bd3
    • darin@apple.com's avatar
      2009-01-25 Darin Adler <darin@apple.com> · 2daec731
      darin@apple.com authored
              Reviewed by Sam Weinig.
      
              Bug 23352: Turn on more compiler warnings in the Mac build
              https://bugs.webkit.org/show_bug.cgi?id=23352
      
              Third patch: Use the noreturn attribute on functions that don't
              return to prepare for the use of the -Wmissing-noreturn warning.
      
              * jit/JITCall.cpp:
              (JSC::unreachable): Added NO_RETURN.
              * jsc.cpp:
              (functionQuit): Ditto.
              (printUsageStatement): Ditto.
              * wtf/AlwaysInline.h: Added definition of NO_RETURN.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40230 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2daec731
    • darin@apple.com's avatar
      WebCore: · 36744d67
      darin@apple.com authored
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam Weinig.
      
              Bug 23522: use checked casts for render tree
              https://bugs.webkit.org/show_bug.cgi?id=23522
      
              Step one: RenderText.
      
              Also change set of RenderFlow* to be a ListHashSet as the comment in the
              header indicated.
      
              * dom/CharacterData.cpp:
              (WebCore::CharacterData::setData): Use toRenderText.
              (WebCore::CharacterData::appendData): Ditto.
              (WebCore::CharacterData::insertData): Ditto.
              (WebCore::CharacterData::deleteData): Ditto.
              (WebCore::CharacterData::replaceData): Ditto.
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::getUpperLeftCorner): Ditto.
              (WebCore::ContainerNode::getLowerRightCorner): Ditto.
              * dom/Position.cpp:
              (WebCore::nextRenderedEditable): Ditto.
              (WebCore::previousRenderedEditable): Ditto.
              (WebCore::Position::renderedOffset): Ditto. Also use function members
              instead of data members of InlineTextBox.
              (WebCore::Position::upstream): Ditto.
              (WebCore::Position::downstream): Ditto.
              (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight): Ditto.
              (WebCore::Position::inRenderedText): Ditto.
              (WebCore::Position::isRenderedCharacter): Ditto.
              (WebCore::searchAheadForBetterMatch): Ditto.
              (WebCore::Position::getInlineBoxAndOffset): Ditto.
      
              * dom/Range.cpp: Added include of VisiblePosition.h now that it's no longer
              included in RenderObject.h.
      
              * dom/Text.cpp:
              (WebCore::Text::splitText): Use toRenderText.
              (WebCore::Text::recalcStyle): Ditto.
              * editing/CompositeEditCommand.cpp:
              (WebCore::CompositeEditCommand::deleteInsignificantText): Ditto.
              * editing/SelectionController.cpp:
              (WebCore::SelectionController::debugRenderer): Ditto.
              * editing/TextIterator.cpp:
              (WebCore::TextIterator::handleTextNode): Ditto.
              (WebCore::TextIterator::handleTextBox): Ditto.
              (WebCore::TextIterator::emitText): Ditto.
              (WebCore::SimplifiedBackwardsTextIterator::handleTextNode): Ditto.
      
              * editing/VisiblePosition.cpp: Added include of FloatQuad.h now that it's
              no longer included in RenderObject.h.
              * inspector/InspectorController.cpp: Ditto.
              * page/Frame.cpp: Ditto.
              * rendering/RenderBox.cpp: Ditto.
              * rendering/RenderInline.cpp: Ditto.
              * rendering/RenderPath.cpp: Ditto.
              * rendering/RenderSVGContainer.cpp: Ditto.
              * rendering/RenderSVGImage.cpp: Ditto.
              * rendering/RenderSVGInlineText.cpp: Ditto.
              * rendering/RenderSVGTSpan.cpp: Ditto.
              * rendering/RenderSVGText.cpp: Ditto.
              * rendering/RenderSVGTextPath.cpp: Ditto.
              * rendering/RenderTableCell.cpp: Ditto.
              * rendering/RenderView.cpp: Ditto.
      
              * editing/visible_units.cpp:
              (WebCore::startPositionForLine): Use function members instead of data
              members of InlineTextBox.
              (WebCore::endPositionForLine): Ditto.
              (WebCore::startOfParagraph): Use toRenderText.
              (WebCore::endOfParagraph): Ditto.
      
              * page/AccessibilityRenderObject.cpp:
              (WebCore::AccessibilityRenderObject::accessibilityIsIgnored): Use toRenderText.
              * rendering/InlineFlowBox.cpp:
              (WebCore::InlineFlowBox::placeBoxesHorizontally): Ditto.
              * rendering/InlineTextBox.cpp:
              (WebCore::InlineTextBox::deleteLine): Ditto.
              (WebCore::InlineTextBox::extractLine): Ditto.
              (WebCore::InlineTextBox::attachLine): Ditto.
              (WebCore::InlineTextBox::placeEllipsisBox): Ditto.
              (WebCore::InlineTextBox::paintDecoration): Ditto.
              (WebCore::InlineTextBox::paintCompositionUnderline): Ditto.
              (WebCore::InlineTextBox::offsetForPosition): Ditto.
              (WebCore::InlineTextBox::positionForOffset): Ditto.
      
              * rendering/InlineTextBox.h: Made most members private. Use toRenderText.
      
              * rendering/RenderArena.cpp:
              (WebCore::RenderArena::allocate): Use static_cast instead of C-style cast.
              (WebCore::RenderArena::free): Ditto.
      
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::addContinuationWithOutline): Use ListHashSet<RenderFlow*>
              instead of RenderFlowSequencedSet.
              (WebCore::RenderBlock::paintContinuationOutlines): Ditto.
              (WebCore::stripTrailingSpace): Ditto.
              (WebCore::RenderBlock::calcInlinePrefWidths): Ditto.
              (WebCore::RenderBlock::updateFirstLetter): Ditto.
      
              * rendering/RenderContainer.cpp:
              (WebCore::RenderContainer::addChild): Use toRenderText.
      
              * rendering/RenderFlow.cpp:
              (WebCore::RenderFlow::dirtyLinesFromChangedChild): Use ListHashSet<RenderFlow*>
              instead of RenderFlowSequencedSet.
              (WebCore::RenderFlow::paintLines): Ditto.
      
              * rendering/RenderMenuList.cpp: Removed some unneeded includes.
      
              * rendering/RenderMenuList.h: Added now-needed forward declaration of RenderText.
              Made more members private.
      
              * rendering/RenderObject.cpp: Updated includes.
              (WebCore::RenderObject::isEditable): Use toRenderText.
              (WebCore::RenderObject::positionForPoint): Made non-inline so we wouldn't have to
              include VisiblePosition.h in the header just for this.
      
              * rendering/RenderObject.h: Removed unneeded includes and forward declarations.
              Changed special vertical position values to be constants rather than an enum.
              Eliminated RenderFlowSequencedSet, and changed clients to use ListHashSet<RenderFlow*>.
      
              * rendering/RenderText.cpp:
              (WebCore::RenderText::findNextInlineTextBox): Use function members instead of
              data members of InlineTextBox.
              (WebCore::RenderText::positionForCoordinates): Ditto.
              (WebCore::isInlineFlowOrEmptyText): Use toRenderText.
              (WebCore::RenderText::previousCharacter): Use function members instead of
              data members of InlineTextBox.
              (WebCore::RenderText::position): Ditto.
              (WebCore::RenderText::caretMinOffset): Ditto.
              (WebCore::RenderText::caretMaxOffset): Ditto.
              (WebCore::RenderText::caretMaxRenderedOffset): Ditto.
      
              * rendering/RenderText.h: Added definition of toRenderText.
      
              * rendering/RenderTextControl.cpp:
              (WebCore::RenderTextControl::textWithHardLineBreaks): Use toRenderText.
              * rendering/RenderTreeAsText.cpp:
              (WebCore::operator<<): Use toRenderText and toRenderBox.
              (WebCore::writeTextRun): Ditto.
              (WebCore::write): Ditto.
      
              * rendering/bidi.cpp:
              (WebCore::InlineIterator::increment): Use toRenderText.
              (WebCore::InlineIterator::current): Ditto.
              (WebCore::checkMidpoints): Ditto.
              (WebCore::RenderBlock::computeHorizontalPositionsForLine): Ditto.
              (WebCore::RenderBlock::layoutInlineChildren): Ditto.
              (WebCore::RenderBlock::determineStartPosition): Ditto.
              (WebCore::shouldSkipWhitespaceAfterStartObject): Ditto.
              (WebCore::RenderBlock::findNextLineBreak): Ditto.
      
      WebKit/mac:
      
      2009-01-25  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam Weinig.
      
              Bug 23522: use checked casts for render tree
              https://bugs.webkit.org/show_bug.cgi?id=23522
      
              Step one: RenderText.
      
              * WebView/WebRenderNode.mm:
              (copyRenderNode): Use toRenderText.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40229 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      36744d67
    • hausmann@webkit.org's avatar
      2009-01-25 Urs Wolfer <uwolfer@kde.org> · 5c0d6af8
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Add QWebPage::SelectAll to WebAction enum to select all content.
      
              https://bugs.webkit.org/show_bug.cgi?id=22946
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40228 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5c0d6af8
    • hausmann@webkit.org's avatar
      2009-01-25 Thiago Macieira <thiago.macieira@nokia.com> · 6d1ffbe3
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Fix gcc compiler warning (deprecated conversion from constant string to char*)
      
              "" cannot be stored in a char*
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40227 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6d1ffbe3
    • hausmann@webkit.org's avatar
      2009-01-25 David Boddie <dboddie@trolltech.com> · b26d3b2d
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Doc: Fixed the terminology used.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40226 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b26d3b2d
    • hausmann@webkit.org's avatar
      2009-01-25 Thiago Macieira <thiago.macieira@nokia.com> · f29f1cbe
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Rename links from trolltech.com to qtsoftware.com
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40225 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f29f1cbe
    • hausmann@webkit.org's avatar
      2009-01-25 Tor Arne Vestbø <tavestbo@trolltech.com> · 61d18b59
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Make QWebPage auto-test more robust by cleaning up generated files
      
              Sometimes the auto-test may segfault, leaving behind files because the
              call to cleanupTestCase() never happens, so we also clean up the files
              at initTestCase() just to make sure we're running in a clean environment.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40224 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      61d18b59
    • hausmann@webkit.org's avatar
      2008-12-20 Urs Wolfer <uwolfer@kde.org> · b8854bc6
      hausmann@webkit.org authored
              Reviewed by Simon Hausmann.
      
              Fix: compile qwebhistory.h with pendantic comiler flag.
      
              https://bugs.webkit.org/show_bug.cgi?id=22947
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40223 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b8854bc6
    • ap@webkit.org's avatar
      Remove a slightly misleading comment from ChangeLog - the issue is related to... · eaa1c244
      ap@webkit.org authored
      Remove a slightly misleading comment from ChangeLog - the issue is related to bug 23500, but not the same.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40222 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      eaa1c244
    • ap@webkit.org's avatar
      Reviewed by Darin Adler. · e7e20111
      ap@webkit.org authored
              <rdar://problem/5954398> REGRESSION: 1.1% PLT regression from 33577 and 33578 (encoding fixes)
      
      WebCore:
              Changed single argument KURL constructors back to always expect an already encoded string,
              eliminating extra conversions.
      
              This is a rather unstable situation, as it is often unclear whether a given string is safe
              to convert to KURL without resolving. I think that going forward, the solution is to try to
              keep encoded URLs as KURL instances, and not as strings.
      
              * platform/KURL.h: Updated comments.
      
              * platform/KURL.cpp:
              (WebCore::KURL::KURL): In debug builds, verify that the passed string is ASCII-only. The
              intention is to verify that it is already parsed and encoded by KURL or equivalent code, but
              since encoding is scheme-dependent, such a verification would be quite complicated.
              Don't encode the string as UTF-8, as it supposed to be ASCII-only.
              Removed a hack that made strings beginning with "/" turn into "file:" URLs. I didn't find
              any reason for it to exist, but I saw several cases where this code path was taken
              inadvertently (see examples in LayoutTests/ChangeLog).
              (WebCore::KURL::setProtocol): Using a user-provided string without validation or encoding
              is clearly wrong here (e.g., the "protocol" can be set to a full URL, effectively replacing
              the old one), and an already encoded string is expected by parse().
              In debug builds, non-ASCII input will make an assertion in parse() fail. Added a FIXME.
              (WebCore::KURL::setHost): Ditto.
              (WebCore::KURL::setPort): Ditto.
              (WebCore::KURL::setHostAndPort): Ditto.
              (WebCore::KURL::setUser): Ditto.
              (WebCore::KURL::setPass): Ditto.
              (WebCore::KURL::setRef): Ditto.
              (WebCore::KURL::setQuery): Ditto.
              (WebCore::KURL::setPath): Ditto.  Note that problems described in bug 23500 mask some of
              the problems in release builds currently, as the incorrectly parsed URL is ignored. 
              (WebCore::KURL::parse): Verify that the passed string is already encoded.
      
              * html/HTMLLinkElement.cpp:
              (WebCore::HTMLLinkElement::parseMappedAttribute):
              (WebCore::HTMLLinkElement::process):
              * html/HTMLLinkElement.h:
              Changed to avoid using invalid URLs (this was causing problems on DNS prefetch tests, see
              LayoutTests/ChangeLog).
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::init): Create an empty KURL without indirection for a small speedup.
              (WebCore::FrameLoader::requestFrame): Resolve and encode javascript URLs properly, now that
              String to KURL conversion requires the string to be already encoded.
      
              * page/DOMWindow.cpp: (WebCore::DOMWindow::postMessage): Resolve and encode the origin.
              HTML5 seems a little unclear on how this should work (it talks about "either parsing it as
              a URL, or resolving it", and then somehow compares unaltered targetOrigin string to a
              security origin object), so I just made the code as close to what we already had as possible.
      
      LayoutTests:
              * http/tests/misc/dns-prefetch-control-expected.txt:
              * http/tests/misc/dns-prefetch-control.html:
              Google documentation for DNS Prefetch makes use of net-path relative URLs (//server-name),
              explaining that scheme is not necessary. This is of course true, but this test uses data:
              subframes, and data: is a non-hierachical scheme, so resolving such URLs fails, resulting
              in a KURL object that is not valid. WebKit used to ignore this, and tried to create a URL
              from this string again, now with a single argument KURL constructor, which resulted in a
              valid file: URL, which was successfully used! Both issues have been corrected in WebCore,
              so I had to change the test to no longer use relative net-path URLs.
      
              * http/tests/security/postMessage/invalid-origin-throws-exception-expected.txt:
              * http/tests/security/postMessage/invalid-origin-throws-exception.html:
              URLs that start with "/" are no longer converted to "file:" ones, so the results now
              match Firefox.
      
              * http/tests/uri/resolve-encoding-relative-expected.txt: Added.
              * http/tests/uri/resolve-encoding-relative.html: Added.
              Added a test to cover some cases of relative URL resolving that were not covered before.
              Expected results are taken from Firefox 3, and WebKit doesn't match in how fragments are
              encoded (we use document encoding, while Firefox uses UTF-8). Since fragments are not
              sent in HTTP requests, this is not too dangerous, but the Firefox behavior looks more
              consistent.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@40221 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e7e20111
  3. 24 Jan, 2009 2 commits