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

Side by Side Diff: components/omnibox/browser/omnibox_edit_controller.h

Issue 1485333006: Abstract callout to OmniboxEditController on updating input in progress (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 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 COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_ 5 #ifndef COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_
6 #define COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_ 6 #define COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_
7 7
8 #include "base/strings/string16.h" 8 #include "base/strings/string16.h"
9 #include "ui/base/page_transition_types.h" 9 #include "ui/base/page_transition_types.h"
10 #include "ui/base/window_open_disposition.h" 10 #include "ui/base/window_open_disposition.h"
11 #include "url/gurl.h" 11 #include "url/gurl.h"
12 12
13 class ToolbarModel; 13 class ToolbarModel;
14 14
15 namespace gfx { 15 namespace gfx {
16 class Image; 16 class Image;
17 } 17 }
18 18
19 class OmniboxEditController { 19 class OmniboxEditController {
20 public: 20 public:
21 virtual void OnAutocompleteAccept(const GURL& destination_url, 21 virtual void OnAutocompleteAccept(const GURL& destination_url,
22 WindowOpenDisposition disposition, 22 WindowOpenDisposition disposition,
23 ui::PageTransition transition); 23 ui::PageTransition transition);
24 24
25 // Called when the the controller should update itself without restoring any 25 virtual void SetInputInProgress(bool in_progress) = 0;
Peter Kasting 2015/12/08 20:42:28 You might want to name this OnInputInProgress() si
blundell 2015/12/09 10:42:32 Done.
26 // tab state.
27 virtual void UpdateWithoutTabRestore() = 0;
28 26
29 // Called when anything has changed that might affect the layout or contents 27 // Called when anything has changed that might affect the layout or contents
30 // of the views around the edit, including the text of the edit and the 28 // of the views around the edit, including the text of the edit and the
31 // status of any keyword- or hint-related state. 29 // status of any keyword- or hint-related state.
32 virtual void OnChanged() = 0; 30 virtual void OnChanged() = 0;
33 31
34 // Called whenever the autocomplete edit gets focused. 32 // Called whenever the autocomplete edit gets focused.
35 virtual void OnSetFocus() = 0; 33 virtual void OnSetFocus() = 0;
36 34
37 // Shows the URL. 35 // Shows the URL.
(...skipping 13 matching lines...) Expand all
51 private: 49 private:
52 // The details necessary to open the user's desired omnibox match. 50 // The details necessary to open the user's desired omnibox match.
53 GURL destination_url_; 51 GURL destination_url_;
54 WindowOpenDisposition disposition_; 52 WindowOpenDisposition disposition_;
55 ui::PageTransition transition_; 53 ui::PageTransition transition_;
56 54
57 DISALLOW_COPY_AND_ASSIGN(OmniboxEditController); 55 DISALLOW_COPY_AND_ASSIGN(OmniboxEditController);
58 }; 56 };
59 57
60 #endif // COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_ 58 #endif // COMPONENTS_OMNIBOX_BROWSER_OMNIBOX_EDIT_CONTROLLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/omnibox/chrome_omnibox_edit_controller.cc ('k') | components/omnibox/browser/omnibox_edit_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698