[webkit-help] Why does isLocationChange() return false for redirection?

Eric Zhou englefly at gmail.com
Mon Aug 16 22:58:10 PDT 2010


Hi all,

following is the related code. My question is why it returns false
when ScheduledRedirection.type is redirection.
>From the name of the function, I think if the url changes, it should return
true. Thus, for most of redirection, it should return true.

//FrameLoader.cpp
bool FrameLoader::isLocationChange(const ScheduledRedirection& redirection)
{
    switch (redirection.type) {
        case ScheduledRedirection::redirection:
            return false;
        case ScheduledRedirection::historyNavigation:
        case ScheduledRedirection::locationChange:
        case ScheduledRedirection::formSubmission:
            return true;
    }
    ASSERT_NOT_REACHED();
    return false;
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-help/attachments/20100817/0f1d1482/attachment.html>


More information about the webkit-help mailing list