| Index: content/browser/devtools/page_navigation_throttle.h
|
| diff --git a/content/browser/devtools/page_navigation_throttle.h b/content/browser/devtools/page_navigation_throttle.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..4cc2641478591ebc4f501d14da2b40e2e584e8b9
|
| --- /dev/null
|
| +++ b/content/browser/devtools/page_navigation_throttle.h
|
| @@ -0,0 +1,44 @@
|
| +// Copyright 2016 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 CONTENT_BROWSER_DEVTOOLS_PAGE_NAVIGATION_THROTTLE_H_
|
| +#define CONTENT_BROWSER_DEVTOOLS_PAGE_NAVIGATION_THROTTLE_H_
|
| +
|
| +#include "base/macros.h"
|
| +#include "base/memory/weak_ptr.h"
|
| +#include "content/public/browser/navigation_throttle.h"
|
| +
|
| +namespace content {
|
| +namespace devtools {
|
| +namespace page {
|
| +class PageHandler;
|
| +} // namespace page
|
| +
|
| +class PageNavigationThrottle : public content::NavigationThrottle {
|
| + public:
|
| + PageNavigationThrottle(base::WeakPtr<page::PageHandler> page_handler,
|
| + int navigation_id,
|
| + content::NavigationHandle* navigation_handle);
|
| + ~PageNavigationThrottle() override;
|
| +
|
| + // content::NavigationThrottle implementation:
|
| + NavigationThrottle::ThrottleCheckResult WillStartRequest() override;
|
| + NavigationThrottle::ThrottleCheckResult WillRedirectRequest() override;
|
| + NavigationThrottle::ThrottleCheckResult WillProcessResponse() override;
|
| +
|
| + int navigation_id() const { return navigation_id_; }
|
| +
|
| + std::string GetFrameId() const;
|
| +
|
| + private:
|
| + int navigation_id_;
|
| + base::WeakPtr<page::PageHandler> page_handler_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(PageNavigationThrottle);
|
| +};
|
| +
|
| +} // namespace devtools
|
| +} // namespace content
|
| +
|
| +#endif // CONTENT_BROWSER_DEVTOOLS_PAGE_NAVIGATION_THROTTLE_H_
|
|
|