<commit_before>// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__
#define WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__

#include "base/compiler_specific.h"

MSVC_PUSH_WARNING_LEVEL(0);
#include "FrameLoaderClient.h"
MSVC_POP_WARNING();

#include "build/build_config.h"
#include "base/scoped_ptr.h"
#include "googleurl/src/gurl.h"
#include "webkit/glue/webview_delegate.h"
#include "webkit/glue/window_open_disposition.h"
namespace WebCore {
class Frame;
class HTMLFormElement;
class Widget;
}

class Alt404PageResourceFetcher;
class WebFrameImpl;
class WebPluginContainer;


class WebFrameLoaderClient : public WebCore::FrameLoaderClient {
 public:
  WebFrameLoaderClient(WebFrameImpl* webframe);
  virtual ~WebFrameLoaderClient();

  WebFrameImpl* webframe() const { return webframe_; }

  // WebCore::FrameLoaderClient ----------------------------------------------

  virtual void frameLoaderDestroyed();

  // Notifies the WebView delegate that the JS window object has been cleared,
  // giving it a chance to bind native objects to the window before script
  // parsing begins.
  virtual void windowObjectCleared();
  virtual void documentElementAvailable();

  virtual bool hasWebView() const; // mainly for assertions
  virtual bool hasFrameView() const; // ditto

  virtual void makeRepresentation(WebCore::DocumentLoader*);
  virtual void forceLayout();
  virtual void forceLayoutForNonHTML();

  virtual void setCopiesOnScroll();

  virtual void detachedFromParent2();
  virtual void detachedFromParent3();

  virtual void assignIdentifierToInitialRequest(unsigned long identifier, WebCore::DocumentLoader*, const WebCore::ResourceRequest&);

  virtual void dispatchWillSendRequest(WebCore::DocumentLoader*, unsigned long identifier, WebCore::ResourceRequest&, const WebCore::ResourceResponse& redirectResponse);
  virtual bool shouldUseCredentialStorage(WebCore::DocumentLoader*, unsigned long identifier);
  virtual void dispatchDidReceiveAuthenticationChallenge(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::AuthenticationChallenge&);
  virtual void dispatchDidCancelAuthenticationChallenge(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::AuthenticationChallenge&);
  virtual void dispatchDidReceiveResponse(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceResponse&);
  virtual void dispatchDidReceiveContentLength(WebCore::DocumentLoader*, unsigned long identifier, int lengthReceived);
  virtual void dispatchDidFinishLoading(WebCore::DocumentLoader*, unsigned long identifier);
  virtual void dispatchDidFailLoading(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceError&);
  virtual bool dispatchDidLoadResourceFromMemoryCache(WebCore::DocumentLoader*, const WebCore::ResourceRequest&, const WebCore::ResourceResponse&, int length);
  virtual void dispatchDidLoadResourceByXMLHttpRequest(unsigned long identifier, const WebCore::ScriptString&);

  virtual void dispatchDidHandleOnloadEvents();<commit_msg>Add stubs to WebFrameLoaderClient for context create/destroy, so webkit bot compiles.<commit_after>// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__
#define WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__

#include "base/compiler_specific.h"

MSVC_PUSH_WARNING_LEVEL(0);
#include "FrameLoaderClient.h"
MSVC_POP_WARNING();

#include "build/build_config.h"
#include "base/scoped_ptr.h"
#include "googleurl/src/gurl.h"
#include "webkit/glue/webview_delegate.h"
#include "webkit/glue/window_open_disposition.h"
namespace WebCore {
class Frame;
class HTMLFormElement;
class Widget;
}

class Alt404PageResourceFetcher;
class WebFrameImpl;
class WebPluginContainer;


class WebFrameLoaderClient : public WebCore::FrameLoaderClient {
 public:
  WebFrameLoaderClient(WebFrameImpl* webframe);
  virtual ~WebFrameLoaderClient();

  WebFrameImpl* webframe() const { return webframe_; }

  // WebCore::FrameLoaderClient ----------------------------------------------

  virtual void frameLoaderDestroyed();

  // Notifies the WebView delegate that the JS window object has been cleared,
  // giving it a chance to bind native objects to the window before script
  // parsing begins.
  virtual void windowObjectCleared();
  virtual void documentElementAvailable();

  // TODO(mpcomplete): roll DEPS
  virtual void didCreateScriptContext() {}
  virtual void didDestroyScriptContext() {}

  virtual bool hasWebView() const; // mainly for assertions
  virtual bool hasFrameView() const; // ditto

  virtual void makeRepresentation(WebCore::DocumentLoader*);
  virtual void forceLayout();
  virtual void forceLayoutForNonHTML();

  virtual void setCopiesOnScroll();

  virtual void detachedFromParent2();
  virtual void detachedFromParent3();

  virtual void assignIdentifierToInitialRequest(unsigned long identifier, WebCore::DocumentLoader*, const WebCore::ResourceRequest&);

  virtual void dispatchWillSendRequest(WebCore::DocumentLoader*, unsigned long identifier, WebCore::ResourceRequest&, const WebCore::ResourceResponse& redirectResponse);
  virtual bool shouldUseCredentialStorage(WebCore::DocumentLoader*, unsigned long identifier);
  virtual void dispatchDidReceiveAuthenticationChallenge(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::AuthenticationChallenge&);
  virtual void dispatchDidCancelAuthenticationChallenge(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::AuthenticationChallenge&);
  virtual void dispatchDidReceiveResponse(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceResponse&);
  virtual void dispatchDidReceiveContentLength(WebCore::DocumentLoader*, unsigned long identifier, int lengthReceived);
  virtual void dispatchDidFinishLoading(WebCore::DocumentLoader*, unsigned long identifier);
  virtual void dispatchDidFailLoading(WebCore::DocumentLoader*, unsigned long identifier, const WebCore::ResourceError&);
  virtual bool dispatchDidLoadResourceFromMemoryCache(WebCore::DocumentLoader*, const WebCore::ResourceRequest&, const WebCore::ResourceResponse&, int length);
  virtual void dispatchDidLoadResourceByXMLHttpRequest(unsigned long identifier, const WebCore::ScriptString&);

  virtual void dispatchDidHandleOnloadEvents();
{'fraction_non_alphanumeric': 0.09471600426374295, 'fraction_numerical': 0.004263742957210294, 'mean_word_length': 6.655011655011655, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3856057', 'n_tokens_mistral': 1722, 'n_tokens_neox': 1658, 'n_words': 484}