Revert "Reland c91b178b07b0d - Delete dead signin code (SigninGlobalError)"
[chromium-blink-merge.git] / components / omnibox / browser / omnibox_navigation_observer.h
blobc9306e522b9fbb2a38f6398dc65c49e9f2325320
1 // Copyright 2015 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.
5 #ifndef COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_NAVIGATION_OBSERVER_H_
6 #define COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_NAVIGATION_OBSERVER_H_
8 // Interface that allows an embedder to monitor omnibox navigations in order to
9 // trigger behaviors that depend on successful navigations.
11 // The memory management of this object is a bit tricky. On opening a match,
12 // the OmniboxEditModel will ask the OmniboxClient to create us if necessary.
13 // Once we are created, OmniboxEditModel will be responsible for us until we
14 // reach the state where we have seen a pending load (it will delete us if this
15 // doesn't happen by the time that processing the match has finished)). Once we
16 // have seen a pending load, we're responsible for deleting ourselves at
17 // whatever time we deem is appropriate.
19 class OmniboxNavigationObserver {
20 public:
21 virtual ~OmniboxNavigationObserver() {}
23 // Returns true iff this observer has seen a pending load since its
24 // creation.
25 virtual bool HasSeenPendingLoad() const = 0;
28 #endif // COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_NAVIGATION_OBSERVER_H_