WebCore:
authordarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Nov 2008 19:39:03 +0000 (19:39 +0000)
committerdarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Nov 2008 19:39:03 +0000 (19:39 +0000)
commit4011a9dab9efaaaf69a8d172d6420d0cc823777c
treee8450dd2f6e56a8942eb6969313f236984e11c77
parent4d672da9193afd4c405de74807e332df3f40d26a
WebCore:

2008-11-16  Darin Adler  <darin@apple.com>

        Reviewed by Dan Bernstein.

        - https://bugs.webkit.org/show_bug.cgi?id=22295
          track which history items are from page load failures

        * history/HistoryItem.cpp: Sort includes, add newly needed ones, and remove
        no-longer-needed ones.
        (WebCore::HistoryItem::HistoryItem): Initialize m_lastVisitWasFailure to false.
        (WebCore::HistoryItem::showTreeWithIndent): Rewrote to avoid appending to a
        String, since that's not efficient.

        * history/HistoryItem.h: Removed unneeded includes. Added lastVisitWasFailure,
        setLastVisitWasFailure, and m_lastVisitWasFailure.

        * history/mac/HistoryItemMac.mm: Add newly-needed include
        (WebCore::HistoryItem::setTransientProperty): Rewrote to avoid keeping a
        m_transientProperties map around when it is empty.

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::createHistoryItem): Call setLastVisitWasFailure when
        the page was unreachable or an HTTP page with a status code that indicates
        failure.

WebKit/mac:

2008-11-16  Darin Adler  <darin@apple.com>

        Reviewed by Dan Bernstein.

        - https://bugs.webkit.org/show_bug.cgi?id=22295
          track which history items are from page load failures

        * History/WebHistoryItem.mm: Added lastVisitWasFailureKey.
        (-[WebHistoryItem initFromDictionaryRepresentation:]): Set the lastVisitWasFailure
        flag in the history item if the dictionary had lastVisitWasFailureKey true.
        (-[WebHistoryItem dictionaryRepresentation]): Set the lastVisitWasFailureKey boolean
        in the dictionary if the history item had the lastVisitWasFailure flag.
        (-[WebHistoryItem lastVisitWasFailure]): Added.

        * History/WebHistoryItemInternal.h: Moved include of WebBackForwardList here from
        WebHistoryItemPrivate.h; removed other unneeded includes.

        * History/WebHistoryItemPrivate.h: Added lastVisitWasFailure method.
        Removed unneeded includes.

        * Misc/WebNSDictionaryExtras.h: Added _webkit_boolForKey.
        * Misc/WebNSDictionaryExtras.m:
        (-[NSDictionary _webkit_boolForKey:]): Added.

WebKit/win:

2008-11-16  Darin Adler  <darin@apple.com>

        Reviewed by Dan Bernstein.

        - https://bugs.webkit.org/show_bug.cgi?id=22295
          track which history items are from page load failures

        * Interfaces/IWebHistoryItemPrivate.idl: Added lastVisitWasFailure function.

        * WebHistoryItem.cpp:
        (WebHistoryItem::initFromDictionaryRepresentation): Set the lastVisitWasFailure
        flag in the history item if the dictionary had an entry for lastVisitWasFailureKey.
        (WebHistoryItem::dictionaryRepresentation): Set the lastVisitWasFailureKey key
        in the dictionary if the history item had the lastVisitWasFailure flag.
        (WebHistoryItem::lastVisitWasFailure): Added.

        * WebHistoryItem.h: Added lastVisitWasFailure function.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@38449 268f45cc-cd09-0410-ab3c-d52691b4dbfc
15 files changed:
WebCore/ChangeLog
WebCore/history/HistoryItem.cpp
WebCore/history/HistoryItem.h
WebCore/history/mac/HistoryItemMac.mm
WebCore/loader/FrameLoader.cpp
WebKit/mac/ChangeLog
WebKit/mac/History/WebHistoryItem.mm
WebKit/mac/History/WebHistoryItemInternal.h
WebKit/mac/History/WebHistoryItemPrivate.h
WebKit/mac/Misc/WebNSDictionaryExtras.h
WebKit/mac/Misc/WebNSDictionaryExtras.m
WebKit/win/ChangeLog
WebKit/win/Interfaces/IWebHistoryItemPrivate.idl
WebKit/win/WebHistoryItem.cpp
WebKit/win/WebHistoryItem.h