navigator.h revision a3f6a49ab37290eeeb8db0f41ec0f1cb74a68be7
1// Copyright 2013 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_ 6#define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_ 7 8#include "base/memory/ref_counted.h" 9#include "content/common/content_export.h" 10 11class GURL; 12 13namespace content { 14 15class NavigationControllerImpl; 16class NavigatorDelegate; 17class RenderFrameHostImpl; 18 19// Implementations of this interface are responsible for performing navigations 20// in a node of the FrameTree. Its lifetime is bound to all FrameTreeNode 21// objects that are using it and will be released once all nodes that use it are 22// freed. The Navigator is bound to a single frame tree and cannot be used by 23// multiple instances of FrameTree. 24// TODO(nasko): Move all navigation methods, such as didStartProvisionalLoad 25// from WebContentsImpl to this interface. 26class CONTENT_EXPORT Navigator : public base::RefCounted<Navigator> { 27 public: 28 // The RenderFrameHostImpl started a provisional load. 29 virtual void DidStartProvisionalLoad(RenderFrameHostImpl* render_frame_host, 30 int64 frame_id, 31 int64 parent_frame_id, 32 bool main_frame, 33 const GURL& url) {}; 34 35 protected: 36 friend class base::RefCounted<Navigator>; 37 virtual ~Navigator() {} 38}; 39 40} // namespace content 41 42#endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_ 43