Source/WebKit/chromium/src/ContextMenuClientImpl.cpp
static WebURL urlFromFrame(Frame* frame)
{
    if (frame) {
        DocumentLoader* dl = frame->loader()->documentLoader();
        if (dl) {
            WebDataSource* ds = WebDataSourceImpl::fromDocumentLoader(dl);
            if (ds)
                return ds->hasUnreachableURL() ? ds->unreachableURL() : ds->request().url();
        }
    }
    return WebURL();
}
// Figure out the URL of a page or subframe. Returns |page_type| as the type,
// which indicates page or subframe, or ContextNodeType::NONE if the URL could not
// be determined for some reason.
Figure out the URL of a page or subframe. Returns |page_type| as the type,
which indicates page or subframe, or ContextNodeType::NONE if the URL could not
be determined for some reason.
Figure out the URL of a page or subframe . Returns |page_type| as the type which indicates page or subframe or ContextNodeType :: NONE if the URL could not be determined for some reason .
static WebURL urlFromFrame(Frame* frame)
{
    if (frame) {
        DocumentLoader* dl = frame->loader()->documentLoader();
        if (dl) {
            WebDataSource* ds = WebDataSourceImpl::fromDocumentLoader(dl);
            if (ds)
                return ds->hasUnreachableURL() ? ds->unreachableURL() : ds->request().url();
        }
    }
    return WebURL();
}
static WebURL urlFromFrame ( Frame * frame ) { if ( frame ) { DocumentLoader * dl = frame -> loader ( ) -> documentLoader ( ) ; if ( dl ) { WebDataSource * ds = WebDataSourceImpl :: fromDocumentLoader ( dl ) ; if ( ds ) return ds -> hasUnreachableURL ( ) ? ds -> unreachableURL ( ) : ds -> request ( ) . url ( ) ; } } return WebURL ( ) ; }
Figure out the URL of a page or subframe.
Figure out the URL of a page or subframe .