Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
2011-01-27 Nate Chapin <japhet@chromium.org>
        Reviewed by Adam Barth.

        Remove FrameLoader::url() and update callers to use
        Document::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        Refactor, no new tests.

        * WebCore.exp.in:
        * dom/Document.cpp:
        (WebCore::Document::processHttpEquiv):
        (WebCore::Document::removePendingSheet):
        * history/CachedFrame.cpp:
        (WebCore::CachedFrameBase::CachedFrameBase):
        * history/PageCache.cpp:
        (WebCore::logCanCacheFrameDecision):
        (WebCore::PageCache::canCachePageContainingThisFrame):
        * html/HTMLFrameElementBase.cpp:
        (WebCore::HTMLFrameElementBase::isURLAllowed):
        * html/HTMLPlugInImageElement.cpp:
        (WebCore::HTMLPlugInImageElement::allowedToLoadFrameURL):
        * inspector/InspectorAgent.cpp:
        (WebCore::InspectorAgent::inspectedURL):
        * inspector/InspectorResourceAgent.cpp:
        (WebCore::buildObjectForFrame):
        * loader/DocumentWriter.cpp:
        (WebCore::DocumentWriter::replaceDocument):
        (WebCore::DocumentWriter::deprecatedFrameEncoding):
        * loader/FrameLoader.cpp:
        * loader/FrameLoader.h:
        * loader/HistoryController.cpp:
        (WebCore::HistoryController::updateForStandardLoad):
        (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
        (WebCore::HistoryController::updateForSameDocumentNavigation):
        * loader/NavigationScheduler.cpp:
        (WebCore::ScheduledHistoryNavigation::fire):
        (WebCore::NavigationScheduler::scheduleLocationChange):
        (WebCore::NavigationScheduler::scheduleRefresh):
        * page/FrameView.cpp:
        (WebCore::FrameView::updateControlTints):
        * page/Location.cpp:
        (WebCore::Location::url):
        (WebCore::Location::setProtocol):
        (WebCore::Location::setHost):
        (WebCore::Location::setHostname):
        (WebCore::Location::setPort):
        (WebCore::Location::setPathname):
        (WebCore::Location::setSearch):
        (WebCore::Location::setHash):
        (WebCore::Location::reload):
        * page/Page.cpp:
        (WebCore::Page::goToItem):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * ewk/ewk_frame.cpp:
        (ewk_frame_uri_changed):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * webkit/webkitwebview.cpp:
        (webkit_web_view_get_icon_uri):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * WebCoreSupport/FrameLoaderClientHaiku.cpp:
        (WebCore::FrameLoaderClientHaiku::dispatchDidFinishDocumentLoad):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * WebView/WebView.mm:
        (-[WebView _dispatchDidReceiveIconFromWebFrame:]):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * Api/qwebframe.cpp:
        (QWebFrame::url):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * WebFrame.cpp:
        (WebFrame::url):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * WebKitSupport/FrameLoaderClientWx.cpp:
        (WebCore::FrameLoaderClientWx::dispatchDidFinishDocumentLoad):
2011-01-27  Nate Chapin  <japhet@chromium.org>

        Reviewed by Adam Barth.

        Use Document::url() instead of FrameLoader::url().
        https://bugs.webkit.org/show_bug.cgi?id=41165

        * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
        (WebKit::WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
        (WebKit::WebFrameLoaderClient::dispatchDidPushStateWithinPage):
        (WebKit::WebFrameLoaderClient::dispatchDidReplaceStateWithinPage):
        (WebKit::WebFrameLoaderClient::dispatchDidPopStateWithinPage):
        * WebProcess/WebPage/WebFrame.cpp:
        (WebKit::WebFrame::url):

Canonical link: https://commits.webkit.org/67077@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@76872 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
natechapin committed Jan 28, 2011
1 parent 8aa4cac commit 3dacf8f
Show file tree
Hide file tree
Showing 35 changed files with 185 additions and 54 deletions.
55 changes: 55 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,3 +1,58 @@
2011-01-27 Nate Chapin <japhet@chromium.org>

Reviewed by Adam Barth.

Remove FrameLoader::url() and update callers to use
Document::url().
https://bugs.webkit.org/show_bug.cgi?id=41165

Refactor, no new tests.

* WebCore.exp.in:
* dom/Document.cpp:
(WebCore::Document::processHttpEquiv):
(WebCore::Document::removePendingSheet):
* history/CachedFrame.cpp:
(WebCore::CachedFrameBase::CachedFrameBase):
* history/PageCache.cpp:
(WebCore::logCanCacheFrameDecision):
(WebCore::PageCache::canCachePageContainingThisFrame):
* html/HTMLFrameElementBase.cpp:
(WebCore::HTMLFrameElementBase::isURLAllowed):
* html/HTMLPlugInImageElement.cpp:
(WebCore::HTMLPlugInImageElement::allowedToLoadFrameURL):
* inspector/InspectorAgent.cpp:
(WebCore::InspectorAgent::inspectedURL):
* inspector/InspectorResourceAgent.cpp:
(WebCore::buildObjectForFrame):
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::replaceDocument):
(WebCore::DocumentWriter::deprecatedFrameEncoding):
* loader/FrameLoader.cpp:
* loader/FrameLoader.h:
* loader/HistoryController.cpp:
(WebCore::HistoryController::updateForStandardLoad):
(WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
(WebCore::HistoryController::updateForSameDocumentNavigation):
* loader/NavigationScheduler.cpp:
(WebCore::ScheduledHistoryNavigation::fire):
(WebCore::NavigationScheduler::scheduleLocationChange):
(WebCore::NavigationScheduler::scheduleRefresh):
* page/FrameView.cpp:
(WebCore::FrameView::updateControlTints):
* page/Location.cpp:
(WebCore::Location::url):
(WebCore::Location::setProtocol):
(WebCore::Location::setHost):
(WebCore::Location::setHostname):
(WebCore::Location::setPort):
(WebCore::Location::setPathname):
(WebCore::Location::setSearch):
(WebCore::Location::setHash):
(WebCore::Location::reload):
* page/Page.cpp:
(WebCore::Page::goToItem):

2011-01-27 Stephen White <senorblanco@chromium.org>

Reviewed by Darin Adler.
Expand Down
1 change: 0 additions & 1 deletion Source/WebCore/WebCore.exp.in
Expand Up @@ -971,7 +971,6 @@ __ZNK7WebCore11FrameLoader16outgoingReferrerEv
__ZNK7WebCore11FrameLoader17networkingContextEv
__ZNK7WebCore11FrameLoader20activeDocumentLoaderEv
__ZNK7WebCore11FrameLoader27numPendingOrLoadingRequestsEb
__ZNK7WebCore11FrameLoader3urlEv
__ZNK7WebCore11FrameLoader8loadTypeEv
__ZNK7WebCore11HistoryItem10visitCountEv
__ZNK7WebCore11HistoryItem11hasChildrenEv
Expand Down
4 changes: 2 additions & 2 deletions Source/WebCore/dom/Document.cpp
Expand Up @@ -2646,7 +2646,7 @@ void Document::processHttpEquiv(const String& equiv, const String& content)
String url;
if (frame && parseHTTPRefresh(content, true, delay, url)) {
if (url.isEmpty())
url = frame->loader()->url().string();
url = m_url.string();
else
url = completeURL(url).string();
frame->navigationScheduler()->scheduleRedirect(delay, url);
Expand Down Expand Up @@ -2927,7 +2927,7 @@ void Document::removePendingSheet()
parser->executeScriptsWaitingForStylesheets();

if (m_gotoAnchorNeededAfterStylesheetsLoad && view())
view()->scrollToFragment(m_frame->loader()->url());
view()->scrollToFragment(m_url);
}

void Document::styleSelectorChanged(StyleSelectorUpdateFlag updateFlag)
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/history/CachedFrame.cpp
Expand Up @@ -65,7 +65,7 @@ CachedFrameBase::CachedFrameBase(Frame* frame)
, m_documentLoader(frame->loader()->documentLoader())
, m_view(frame->view())
, m_mousePressNode(frame->eventHandler()->mousePressNode())
, m_url(frame->loader()->url())
, m_url(frame->document()->url())
, m_isMainFrame(!frame->tree()->parent())
{
}
Expand Down
4 changes: 2 additions & 2 deletions Source/WebCore/history/PageCache.cpp
Expand Up @@ -111,7 +111,7 @@ static bool logCanCacheFrameDecision(Frame* frame, int indentLevel)
PCLOG(" -Frame contains plugins");
cannotCache = true;
}
if (frame->loader()->url().protocolIs("https")) {
if (frame->document()->url().protocolIs("https")) {
PCLOG(" -Frame is HTTPS");
cannotCache = true;
}
Expand Down Expand Up @@ -260,7 +260,7 @@ bool PageCache::canCachePageContainingThisFrame(Frame* frame)
// they would need to be destroyed and then recreated, and there is no way that we can recreate
// the right NPObjects. See <rdar://problem/5197041> for more information.
&& !frame->loader()->subframeLoader()->containsPlugins()
&& !frame->loader()->url().protocolIs("https")
&& !frame->document()->url().protocolIs("https")
&& (!frame->domWindow() || !frame->domWindow()->hasEventListeners(eventNames().unloadEvent))
#if ENABLE(DATABASE)
&& !frame->document()->hasOpenDatabases()
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/html/HTMLFrameElementBase.cpp
Expand Up @@ -80,7 +80,7 @@ bool HTMLFrameElementBase::isURLAllowed() const
// But we don't allow more than one.
bool foundSelfReference = false;
for (Frame* frame = document()->frame(); frame; frame = frame->tree()->parent()) {
if (equalIgnoringFragmentIdentifier(frame->loader()->url(), completeURL)) {
if (equalIgnoringFragmentIdentifier(frame->document()->url(), completeURL)) {
if (foundSelfReference)
return false;
foundSelfReference = true;
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/html/HTMLPlugInImageElement.cpp
Expand Up @@ -78,7 +78,7 @@ bool HTMLPlugInImageElement::allowedToLoadFrameURL(const String& url)
KURL completeURL = document()->completeURL(url);
bool foundSelfReference = false;
for (Frame* frame = document()->frame(); frame; frame = frame->tree()->parent()) {
if (equalIgnoringFragmentIdentifier(frame->loader()->url(), completeURL)) {
if (equalIgnoringFragmentIdentifier(frame->document()->url(), completeURL)) {
if (foundSelfReference)
return false;
foundSelfReference = true;
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/inspector/InspectorAgent.cpp
Expand Up @@ -1347,7 +1347,7 @@ void InspectorAgent::setInspectorExtensionAPI(const String& source)

KURL InspectorAgent::inspectedURL() const
{
return m_inspectedPage->mainFrame()->loader()->url();
return m_inspectedPage->mainFrame()->document()->url();
}

KURL InspectorAgent::inspectedURLWithoutFragment() const
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/inspector/InspectorResourceAgent.cpp
Expand Up @@ -378,7 +378,7 @@ static PassRefPtr<InspectorObject> buildObjectForFrame(Frame* frame)
name = frame->ownerElement()->getAttribute(HTMLNames::idAttr);
frameObject->setString("name", name);
}
frameObject->setString("url", frame->loader()->url().string());
frameObject->setString("url", frame->document()->url().string());
return frameObject;
}

Expand Down
4 changes: 2 additions & 2 deletions Source/WebCore/loader/DocumentWriter.cpp
Expand Up @@ -67,7 +67,7 @@ DocumentWriter::DocumentWriter(Frame* frame)
void DocumentWriter::replaceDocument(const String& source)
{
m_frame->loader()->stopAllLoaders();
begin(m_frame->loader()->url(), true, m_frame->document()->securityOrigin());
begin(m_frame->document()->url(), true, m_frame->document()->securityOrigin());

if (!source.isNull()) {
if (!m_receivedData) {
Expand Down Expand Up @@ -245,7 +245,7 @@ void DocumentWriter::setDecoder(TextResourceDecoder* decoder)

String DocumentWriter::deprecatedFrameEncoding() const
{
return m_frame->loader()->url().isEmpty() ? m_encoding : encoding();
return m_frame->document()->url().isEmpty() ? m_encoding : encoding();
}

void DocumentWriter::setDocumentWasLoadedAsPartOfNavigation()
Expand Down
6 changes: 0 additions & 6 deletions Source/WebCore/loader/FrameLoader.cpp
Expand Up @@ -635,12 +635,6 @@ void FrameLoader::receivedFirstData()
m_frame->navigationScheduler()->scheduleRedirect(delay, url);
}

const KURL& FrameLoader::url() const
{
ASSERT(m_frame->document());
return m_frame->document()->url();
}

void FrameLoader::setOutgoingReferrer(const KURL& url)
{
KURL outgoingReferrer(url);
Expand Down
1 change: 0 additions & 1 deletion Source/WebCore/loader/FrameLoader.h
Expand Up @@ -267,7 +267,6 @@ class FrameLoader {

void frameDetached();

const KURL& url() const;
void setOutgoingReferrer(const KURL&);

void loadDone();
Expand Down
8 changes: 4 additions & 4 deletions Source/WebCore/loader/HistoryController.cpp
Expand Up @@ -323,7 +323,7 @@ void HistoryController::updateForStandardLoad(HistoryUpdateType updateType)
if (Page* page = m_frame->page())
addVisitedLink(page, historyURL);

if (!frameLoader->documentLoader()->didCreateGlobalHistoryEntry() && frameLoader->documentLoader()->unreachableURL().isEmpty() && !frameLoader->url().isEmpty())
if (!frameLoader->documentLoader()->didCreateGlobalHistoryEntry() && frameLoader->documentLoader()->unreachableURL().isEmpty() && !m_frame->document()->url().isEmpty())
frameLoader->client()->updateGlobalHistoryRedirectLinks();
}
}
Expand Down Expand Up @@ -365,7 +365,7 @@ void HistoryController::updateForRedirectWithLockedBackForwardList()
if (Page* page = m_frame->page())
addVisitedLink(page, historyURL);

if (!m_frame->loader()->documentLoader()->didCreateGlobalHistoryEntry() && m_frame->loader()->documentLoader()->unreachableURL().isEmpty() && !m_frame->loader()->url().isEmpty())
if (!m_frame->loader()->documentLoader()->didCreateGlobalHistoryEntry() && m_frame->loader()->documentLoader()->unreachableURL().isEmpty() && !m_frame->document()->url().isEmpty())
m_frame->loader()->client()->updateGlobalHistoryRedirectLinks();
}
}
Expand Down Expand Up @@ -459,7 +459,7 @@ void HistoryController::recursiveUpdateForCommit()

void HistoryController::updateForSameDocumentNavigation()
{
if (m_frame->loader()->url().isEmpty())
if (m_frame->document()->url().isEmpty())
return;

Settings* settings = m_frame->settings();
Expand All @@ -470,7 +470,7 @@ void HistoryController::updateForSameDocumentNavigation()
if (!page)
return;

addVisitedLink(page, m_frame->loader()->url());
addVisitedLink(page, m_frame->document()->url());
}

void HistoryController::updateForFrameLoadCompleted()
Expand Down
7 changes: 3 additions & 4 deletions Source/WebCore/loader/NavigationScheduler.cpp
Expand Up @@ -178,11 +178,10 @@ class ScheduledHistoryNavigation : public ScheduledNavigation {
{
UserGestureIndicator gestureIndicator(wasUserGesture() ? DefinitelyProcessingUserGesture : DefinitelyNotProcessingUserGesture);

FrameLoader* loader = frame->loader();
if (!m_historySteps) {
// Special case for go(0) from a frame -> reload only the frame
// To follow Firefox and IE's behavior, history reload can only navigate the self frame.
loader->urlSelected(loader->url(), "_self", 0, lockHistory(), lockBackForwardList(), SendReferrer);
frame->loader()->urlSelected(frame->document()->url(), "_self", 0, lockHistory(), lockBackForwardList(), SendReferrer);
return;
}
// go(i!=0) from a frame navigates into the history of the frame only,
Expand Down Expand Up @@ -322,7 +321,7 @@ void NavigationScheduler::scheduleLocationChange(PassRefPtr<SecurityOrigin> secu
// If the URL we're going to navigate to is the same as the current one, except for the
// fragment part, we don't need to schedule the location change.
KURL parsedURL(ParsedURLString, url);
if (parsedURL.hasFragmentIdentifier() && equalIgnoringFragmentIdentifier(loader->url(), parsedURL)) {
if (parsedURL.hasFragmentIdentifier() && equalIgnoringFragmentIdentifier(m_frame->document()->url(), parsedURL)) {
loader->changeLocation(securityOrigin, loader->completeURL(url), referrer, lockHistory, lockBackForwardList);
return;
}
Expand Down Expand Up @@ -359,7 +358,7 @@ void NavigationScheduler::scheduleRefresh()
{
if (!shouldScheduleNavigation())
return;
const KURL& url = m_frame->loader()->url();
const KURL& url = m_frame->document()->url();
if (url.isEmpty())
return;

Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/page/FrameView.cpp
Expand Up @@ -2093,7 +2093,7 @@ void FrameView::updateControlTints()
// to define when controls get the tint and to call this function when that changes.

// Optimize the common case where we bring a window to the front while it's still empty.
if (!m_frame || m_frame->loader()->url().isEmpty())
if (!m_frame || m_frame->document()->url().isEmpty())
return;

if ((m_frame->contentRenderer() && m_frame->contentRenderer()->theme()->supportsControlTints()) || hasCustomScrollbars()) {
Expand Down
18 changes: 9 additions & 9 deletions Source/WebCore/page/Location.cpp
Expand Up @@ -51,7 +51,7 @@ inline const KURL& Location::url() const
{
ASSERT(m_frame);

const KURL& url = m_frame->loader()->url();
const KURL& url = m_frame->document()->url();
if (!url.isValid())
return blankURL(); // Use "about:blank" while the page is still loading (before we have a frame).

Expand Down Expand Up @@ -167,7 +167,7 @@ void Location::setProtocol(const String& protocol, DOMWindow* activeWindow, DOMW
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
if (!url.setProtocol(protocol)) {
ec = SYNTAX_ERR;
return;
Expand All @@ -179,7 +179,7 @@ void Location::setHost(const String& host, DOMWindow* activeWindow, DOMWindow* f
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
url.setHostAndPort(host);
m_frame->domWindow()->setLocation(url.string(), activeWindow, firstWindow);
}
Expand All @@ -188,7 +188,7 @@ void Location::setHostname(const String& hostname, DOMWindow* activeWindow, DOMW
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
url.setHost(hostname);
m_frame->domWindow()->setLocation(url.string(), activeWindow, firstWindow);
}
Expand All @@ -197,7 +197,7 @@ void Location::setPort(const String& portString, DOMWindow* activeWindow, DOMWin
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
int port = portString.toInt();
if (port < 0 || port > 0xFFFF)
url.removePort();
Expand All @@ -210,7 +210,7 @@ void Location::setPathname(const String& pathname, DOMWindow* activeWindow, DOMW
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
url.setPath(pathname);
m_frame->domWindow()->setLocation(url.string(), activeWindow, firstWindow);
}
Expand All @@ -219,7 +219,7 @@ void Location::setSearch(const String& search, DOMWindow* activeWindow, DOMWindo
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
url.setQuery(search);
m_frame->domWindow()->setLocation(url.string(), activeWindow, firstWindow);
}
Expand All @@ -228,7 +228,7 @@ void Location::setHash(const String& hash, DOMWindow* activeWindow, DOMWindow* f
{
if (!m_frame)
return;
KURL url = m_frame->loader()->url();
KURL url = m_frame->document()->url();
String oldFragmentIdentifier = url.fragmentIdentifier();
String newFragmentIdentifier = hash;
if (hash[0] == '#')
Expand Down Expand Up @@ -268,7 +268,7 @@ void Location::reload(DOMWindow* activeWindow)
targetWindow->printErrorMessage(targetWindow->crossDomainAccessErrorMessage(activeWindow));
return;
}
if (protocolIsJavaScript(m_frame->loader()->url()))
if (protocolIsJavaScript(m_frame->document()->url()))
return;
m_frame->navigationScheduler()->scheduleRefresh();
}
Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/page/Page.cpp
Expand Up @@ -339,7 +339,7 @@ void Page::goToItem(HistoryItem* item, FrameLoadType type)

#if ENABLE(DATABASE)
// If we're navigating the history via a fragment on the same document, then we do not want to stop databases.
const KURL& currentURL = m_mainFrame->loader()->url();
const KURL& currentURL = m_mainFrame->document()->url();
const KURL& newURL = item->url();

if (newURL.hasFragmentIdentifier() && equalIgnoringFragmentIdentifier(currentURL, newURL))
Expand Down
10 changes: 10 additions & 0 deletions Source/WebKit/efl/ChangeLog
@@ -1,3 +1,13 @@
2011-01-27 Nate Chapin <japhet@chromium.org>

Reviewed by Adam Barth.

Use Document::url() instead of FrameLoader::url().
https://bugs.webkit.org/show_bug.cgi?id=41165

* ewk/ewk_frame.cpp:
(ewk_frame_uri_changed):

2011-01-14 Patrick Gansterer <paroga@webkit.org>

Unreviewed. Try to fix EFL build.
Expand Down
2 changes: 1 addition & 1 deletion Source/WebKit/efl/ewk/ewk_frame.cpp
Expand Up @@ -2008,7 +2008,7 @@ Eina_Bool ewk_frame_uri_changed(Evas_Object* o)
{
EWK_FRAME_SD_GET_OR_RETURN(o, sd, EINA_FALSE);
EINA_SAFETY_ON_NULL_RETURN_VAL(sd->frame, EINA_FALSE);
WTF::CString uri(sd->frame->loader()->url().prettyURL().utf8());
WTF::CString uri(sd->frame->document()->url().prettyURL().utf8());

INF("uri=%s", uri.data());
if (!uri.data()) {
Expand Down
10 changes: 10 additions & 0 deletions Source/WebKit/gtk/ChangeLog
@@ -1,3 +1,13 @@
2011-01-27 Nate Chapin <japhet@chromium.org>

Reviewed by Adam Barth.

Use Document::url() instead of FrameLoader::url().
https://bugs.webkit.org/show_bug.cgi?id=41165

* webkit/webkitwebview.cpp:
(webkit_web_view_get_icon_uri):

2011-01-27 Mario Sanchez Prada <msanchez@igalia.com>

Reviewed by Martin Robinson.
Expand Down
2 changes: 1 addition & 1 deletion Source/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp
Expand Up @@ -834,7 +834,7 @@ void FrameLoaderClient::dispatchDidChangeLocationWithinPage()
{
WebKitWebFramePrivate* priv = m_frame->priv;
g_free(priv->uri);
priv->uri = g_strdup(core(m_frame)->loader()->url().prettyURL().utf8().data());
priv->uri = g_strdup(core(m_frame)->document()->url().prettyURL().utf8().data());
g_object_notify(G_OBJECT(m_frame), "uri");
WebKitWebView* webView = getViewFromFrame(m_frame);
if (m_frame == webkit_web_view_get_main_frame(webView))
Expand Down

0 comments on commit 3dacf8f

Please sign in to comment.