当前位置: 首页>>代码示例>>C++>>正文


C++ WebLocalFrameImpl类代码示例

本文整理汇总了C++中WebLocalFrameImpl的典型用法代码示例。如果您正苦于以下问题:C++ WebLocalFrameImpl类的具体用法?C++ WebLocalFrameImpl怎么用?C++ WebLocalFrameImpl使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了WebLocalFrameImpl类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: flushCurrentScopingEffort

void TextFinder::flushCurrentScopingEffort(int identifier)
{
    if (!m_ownerFrame.frame() || !m_ownerFrame.frame()->page())
        return;

    WebLocalFrameImpl* mainFrameImpl = m_ownerFrame.viewImpl()->mainFrameImpl();
    mainFrameImpl->ensureTextFinder().decrementFramesScopingCount(identifier);
}
开发者ID:venkatarajasekhar,项目名称:Qt,代码行数:8,代码来源:TextFinder.cpp

示例2: findMatchRects

void TextFinder::findMatchRects(WebVector<WebFloatRect>& outputRects)
{
    Vector<WebFloatRect> matchRects;
    for (WebLocalFrameImpl* frame = &ownerFrame(); frame; frame = toWebLocalFrameImpl(frame->traverseNext(false)))
        frame->ensureTextFinder().appendFindMatchRects(matchRects);

    outputRects = matchRects;
}
开发者ID:RobinWuDev,项目名称:Qt,代码行数:8,代码来源:TextFinder.cpp

示例3: createWebMediaPlayer

static PassOwnPtr<WebMediaPlayer> createWebMediaPlayer(WebMediaPlayerClient* client, const WebURL& url, LocalFrame* frame, WebContentDecryptionModule* initialCdm)
{
    WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(frame);

    if (!webFrame || !webFrame->client())
        return nullptr;
    return adoptPtr(webFrame->client()->createMediaPlayer(webFrame, url, client, initialCdm));
}
开发者ID:alexanderbill,项目名称:blink-crosswalk,代码行数:8,代码来源:WebMediaPlayerClientImpl.cpp

示例4: frame

void WebRemoteFrameImpl::didStopLoading()
{
    frame()->setIsLoading(false);
    if (parent() && parent()->isWebLocalFrame()) {
        WebLocalFrameImpl* parentFrame =
            toWebLocalFrameImpl(parent()->toWebLocalFrame());
        parentFrame->frame()->loader().checkCompleted();
    }
}
开发者ID:howardroark2018,项目名称:chromium,代码行数:9,代码来源:WebRemoteFrameImpl.cpp

示例5: runJavaScriptAlert

// Although a LocalFrame is passed in, we don't actually use it, since we
// already know our own m_webView.
void ChromeClientImpl::runJavaScriptAlert(LocalFrame* frame, const String& message)
{
    WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(frame);
    if (webframe->client()) {
        if (WebUserGestureIndicator::isProcessingUserGesture())
            WebUserGestureIndicator::currentUserGestureToken().setJavascriptPrompt();
        webframe->client()->runModalAlertDialog(message);
    }
}
开发者ID:shawngao5,项目名称:blink-crosswalk,代码行数:11,代码来源:ChromeClientImpl.cpp

示例6: contentsSizeChanged

void ChromeClientImpl::contentsSizeChanged(LocalFrame* frame, const IntSize& size) const
{
    m_webView->didChangeContentsSize();

    WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(frame);
    webframe->didChangeContentsSize(size);

    frame->loader().restoreScrollPositionAndViewState();
}
开发者ID:shawngao5,项目名称:blink-crosswalk,代码行数:9,代码来源:ChromeClientImpl.cpp

示例7: ASSERT

void WebRemoteFrameImpl::initializeFromFrame(WebLocalFrame* source) const
{
    ASSERT(source);
    WebLocalFrameImpl* localFrameImpl = toWebLocalFrameImpl(source);

    client()->initializeChildFrame(
        localFrameImpl->frame()->view()->frameRect(),
        localFrameImpl->frame()->page()->deviceScaleFactor());
}
开发者ID:howardroark2018,项目名称:chromium,代码行数:9,代码来源:WebRemoteFrameImpl.cpp

示例8: handleKeyboardEventOnTextField

void ChromeClientImpl::handleKeyboardEventOnTextField(
    HTMLInputElement& inputElement,
    KeyboardEvent& event) {
  WebLocalFrameImpl* webframe =
      WebLocalFrameImpl::fromFrame(inputElement.document().frame());
  if (webframe->autofillClient())
    webframe->autofillClient()->textFieldDidReceiveKeyDown(
        WebInputElement(&inputElement), WebKeyboardEventBuilder(event));
}
开发者ID:mirror,项目名称:chromium,代码行数:9,代码来源:ChromeClientImpl.cpp

示例9: ASSERT

void NotificationPermissionClientImpl::requestPermission(ExecutionContext* context, NotificationPermissionCallback* callback)
{
    ASSERT(context && context->isDocument());

    Document* document = toDocument(context);
    WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(document->frame());

    webFrame->client()->requestNotificationPermission(WebSecurityOrigin(context->securityOrigin()), new WebNotificationPermissionCallbackImpl(callback));
}
开发者ID:kingysu,项目名称:blink-crosswalk,代码行数:9,代码来源:NotificationPermissionClientImpl.cpp

示例10: runJavaScriptConfirm

// See comments for runJavaScriptAlert().
bool ChromeClientImpl::runJavaScriptConfirm(LocalFrame* frame, const String& message)
{
    WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(frame);
    if (webframe->client()) {
        if (WebUserGestureIndicator::isProcessingUserGesture())
            WebUserGestureIndicator::currentUserGestureToken().setJavascriptPrompt();
        return webframe->client()->runModalConfirmDialog(message);
    }
    return false;
}
开发者ID:shawngao5,项目名称:blink-crosswalk,代码行数:11,代码来源:ChromeClientImpl.cpp

示例11: postAccessibilityNotification

void ChromeClientImpl::postAccessibilityNotification(AXObject* obj, AXObjectCache::AXNotification notification)
{
    // Alert assistive technology about the accessibility object notification.
    if (!obj || !obj->document())
        return;

    WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(obj->document()->axObjectCacheOwner().frame());
    if (webframe && webframe->client())
        webframe->client()->postAccessibilityEvent(WebAXObject(obj), toWebAXEvent(notification));
}
开发者ID:howardroark2018,项目名称:chromium,代码行数:10,代码来源:ChromeClientImpl.cpp

示例12: didChangeValueInTextField

void ChromeClientImpl::didChangeValueInTextField(
    HTMLFormControlElement& element) {
  WebLocalFrameImpl* webframe =
      WebLocalFrameImpl::fromFrame(element.document().frame());
  if (webframe->autofillClient())
    webframe->autofillClient()->textFieldDidChange(
        WebFormControlElement(&element));

  m_webView->pageImportanceSignals()->setHadFormInteraction();
}
开发者ID:mirror,项目名称:chromium,代码行数:10,代码来源:ChromeClientImpl.cpp

示例13: toWebLocalFrameImpl

void WebSharedWorkerImpl::loadShadowPage()
{
    WebLocalFrameImpl* webFrame = toWebLocalFrameImpl(m_webView->mainFrame());

    // Construct substitute data source for the 'shadow page'. We only need it
    // to have same origin as the worker so the loading checks work correctly.
    CString content("");
    RefPtr<SharedBuffer> buffer(SharedBuffer::create(content.data(), content.length()));
    webFrame->frame()->loader().load(FrameLoadRequest(0, ResourceRequest(m_url), SubstituteData(buffer, "text/html", "UTF-8", KURL())));
}
开发者ID:kjthegod,项目名称:WebKit,代码行数:10,代码来源:WebSharedWorkerImpl.cpp

示例14: attachRootLayer

void ChromeClientImpl::attachRootLayer(WebLayer* rootLayer,
                                       LocalFrame* localFrame) {
  WebLocalFrameImpl* webFrame =
      WebLocalFrameImpl::fromFrame(localFrame)->localRoot();

  // This method can be called while the frame is being detached. In that
  // case, the rootLayer is null, and the widget is already destroyed.
  DCHECK(webFrame->frameWidget() || !rootLayer);
  if (webFrame->frameWidget())
    webFrame->frameWidget()->setRootLayer(rootLayer);
}
开发者ID:mirror,项目名称:chromium,代码行数:11,代码来源:ChromeClientImpl.cpp

示例15: startDragging

void ChromeClientImpl::startDragging(LocalFrame* frame,
                                     const WebDragData& dragData,
                                     WebDragOperationsMask mask,
                                     const WebImage& dragImage,
                                     const WebPoint& dragImageOffset) {
  WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(frame);
  WebReferrerPolicy policy = webFrame->document().referrerPolicy();
  m_webView->setDoingDragAndDrop(true);
  webFrame->localRoot()->frameWidget()->client()->startDragging(
      policy, dragData, mask, dragImage, dragImageOffset);
}
开发者ID:mirror,项目名称:chromium,代码行数:11,代码来源:ChromeClientImpl.cpp


注:本文中的WebLocalFrameImpl类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。