Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(310)

Side by Side Diff: trunk/src/chrome/browser/ui/search/instant_page.h

Issue 135903002: Revert 244407 "InstantExtended: remove dead code related to the ..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ 5 #ifndef CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_
6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ 6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 // Called upon determination of Instant API support. Either in response to 45 // Called upon determination of Instant API support. Either in response to
46 // the page loading or because we received some other message. 46 // the page loading or because we received some other message.
47 virtual void InstantSupportDetermined(const content::WebContents* contents, 47 virtual void InstantSupportDetermined(const content::WebContents* contents,
48 bool supports_instant) = 0; 48 bool supports_instant) = 0;
49 49
50 // Called when the page is about to navigate to |url|. 50 // Called when the page is about to navigate to |url|.
51 virtual void InstantPageAboutToNavigateMainFrame( 51 virtual void InstantPageAboutToNavigateMainFrame(
52 const content::WebContents* contents, 52 const content::WebContents* contents,
53 const GURL& url) = 0; 53 const GURL& url) = 0;
54 54
55 // Called when the page fails to load for whatever reason.
56 virtual void InstantPageLoadFailed(content::WebContents* contents) = 0;
57
55 protected: 58 protected:
56 virtual ~Delegate(); 59 virtual ~Delegate();
57 }; 60 };
58 61
59 virtual ~InstantPage(); 62 virtual ~InstantPage();
60 63
61 // The WebContents corresponding to the page we're talking to. May be NULL. 64 // The WebContents corresponding to the page we're talking to. May be NULL.
62 content::WebContents* contents() const { return web_contents(); } 65 content::WebContents* contents() const { return web_contents(); }
63 66
64 // Used to send IPC messages to the page. 67 // Used to send IPC messages to the page.
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 AppropriateMessagesSentToIncognitoPages); 112 AppropriateMessagesSentToIncognitoPages);
110 113
111 // Overridden from content::WebContentsObserver: 114 // Overridden from content::WebContentsObserver:
112 virtual void DidCommitProvisionalLoadForFrame( 115 virtual void DidCommitProvisionalLoadForFrame(
113 int64 frame_id, 116 int64 frame_id,
114 const base::string16& frame_unique_name, 117 const base::string16& frame_unique_name,
115 bool is_main_frame, 118 bool is_main_frame,
116 const GURL& url, 119 const GURL& url,
117 content::PageTransition transition_type, 120 content::PageTransition transition_type,
118 content::RenderViewHost* render_view_host) OVERRIDE; 121 content::RenderViewHost* render_view_host) OVERRIDE;
122 virtual void DidNavigateMainFrame(
123 const content::LoadCommittedDetails& details,
124 const content::FrameNavigateParams& params) OVERRIDE;
125 virtual void DidFailProvisionalLoad(
126 int64 frame_id,
127 const base::string16& frame_unique_name,
128 bool is_main_frame,
129 const GURL& validated_url,
130 int error_code,
131 const base::string16& error_description,
132 content::RenderViewHost* render_view_host) OVERRIDE;
119 133
120 // Overridden from SearchModelObserver: 134 // Overridden from SearchModelObserver:
121 virtual void ModelChanged(const SearchModel::State& old_state, 135 virtual void ModelChanged(const SearchModel::State& old_state,
122 const SearchModel::State& new_state) OVERRIDE; 136 const SearchModel::State& new_state) OVERRIDE;
123 137
124 // Update the status of Instant support. 138 // Update the status of Instant support.
125 void InstantSupportDetermined(bool supports_instant); 139 void InstantSupportDetermined(bool supports_instant);
126 140
127 void ClearContents(); 141 void ClearContents();
128 142
129 // TODO(kmadhusu): Remove |profile_| from here and update InstantNTP to get 143 // TODO(kmadhusu): Remove |profile_| from here and update InstantNTP to get
130 // |profile| from InstantNTPPrerenderer. 144 // |profile| from InstantNTPPrerenderer.
131 Profile* profile_; 145 Profile* profile_;
132 146
133 Delegate* const delegate_; 147 Delegate* const delegate_;
134 scoped_ptr<InstantIPCSender> ipc_sender_; 148 scoped_ptr<InstantIPCSender> ipc_sender_;
135 const std::string instant_url_; 149 const std::string instant_url_;
136 const bool is_incognito_; 150 const bool is_incognito_;
137 151
138 DISALLOW_COPY_AND_ASSIGN(InstantPage); 152 DISALLOW_COPY_AND_ASSIGN(InstantPage);
139 }; 153 };
140 154
141 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ 155 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698