OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ | 5 #ifndef CHROME_BROWSER_UI_SEARCH_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ |
6 #define CHROME_BROWSER_UI_SEARCH_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ | 6 #define CHROME_BROWSER_UI_SEARCH_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "chrome/browser/ui/find_bar/find_bar_controller.h" | 10 #include "chrome/browser/ui/find_bar/find_bar_controller.h" |
(...skipping 27 matching lines...) Expand all Loading... |
38 private: | 38 private: |
39 explicit SearchEngineTabHelper(content::WebContents* web_contents); | 39 explicit SearchEngineTabHelper(content::WebContents* web_contents); |
40 friend class content::WebContentsUserData<SearchEngineTabHelper>; | 40 friend class content::WebContentsUserData<SearchEngineTabHelper>; |
41 | 41 |
42 // Handles when a page specifies an OSDD (OpenSearch Description Document). | 42 // Handles when a page specifies an OSDD (OpenSearch Description Document). |
43 void OnPageHasOSDD(const GURL& page_url, | 43 void OnPageHasOSDD(const GURL& page_url, |
44 const GURL& osdd_url, | 44 const GURL& osdd_url, |
45 const search_provider::OSDDType& msg_provider_type); | 45 const search_provider::OSDDType& msg_provider_type); |
46 | 46 |
47 // Handles when an OSDD is downloaded. | 47 // Handles when an OSDD is downloaded. |
48 void OnDownloadedOSDD(scoped_ptr<TemplateURL> template_url); | 48 void OnDownloadedOSDD(std::unique_ptr<TemplateURL> template_url); |
49 | 49 |
50 // If params has a searchable form, this tries to create a new keyword. | 50 // If params has a searchable form, this tries to create a new keyword. |
51 void GenerateKeywordIfNecessary( | 51 void GenerateKeywordIfNecessary( |
52 const content::FrameNavigateParams& params); | 52 const content::FrameNavigateParams& params); |
53 | 53 |
54 // Delegate for notifying our owner about stuff. Not owned by us. | 54 // Delegate for notifying our owner about stuff. Not owned by us. |
55 SearchEngineTabHelperDelegate* delegate_; | 55 SearchEngineTabHelperDelegate* delegate_; |
56 | 56 |
57 base::WeakPtrFactory<SearchEngineTabHelper> weak_ptr_factory_; | 57 base::WeakPtrFactory<SearchEngineTabHelper> weak_ptr_factory_; |
58 | 58 |
59 DISALLOW_COPY_AND_ASSIGN(SearchEngineTabHelper); | 59 DISALLOW_COPY_AND_ASSIGN(SearchEngineTabHelper); |
60 }; | 60 }; |
61 | 61 |
62 #endif // CHROME_BROWSER_UI_SEARCH_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ | 62 #endif // CHROME_BROWSER_UI_SEARCH_ENGINES_SEARCH_ENGINE_TAB_HELPER_H_ |
OLD | NEW |