| OLD | NEW |
| 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_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 public: | 27 public: |
| 28 SlowTraceSource(); | 28 SlowTraceSource(); |
| 29 | 29 |
| 30 // content::URLDataSource implementation. | 30 // content::URLDataSource implementation. |
| 31 std::string GetSource() const override; | 31 std::string GetSource() const override; |
| 32 void StartDataRequest( | 32 void StartDataRequest( |
| 33 const std::string& path, | 33 const std::string& path, |
| 34 const content::ResourceRequestInfo::WebContentsGetter& wc_getter, | 34 const content::ResourceRequestInfo::WebContentsGetter& wc_getter, |
| 35 const content::URLDataSource::GotDataCallback& callback) override; | 35 const content::URLDataSource::GotDataCallback& callback) override; |
| 36 std::string GetMimeType(const std::string& path) const override; | 36 std::string GetMimeType(const std::string& path) const override; |
| 37 bool AllowCaching() const override; |
| 37 | 38 |
| 38 private: | 39 private: |
| 39 ~SlowTraceSource() override; | 40 ~SlowTraceSource() override; |
| 40 | 41 |
| 41 void OnGetTraceData(const content::URLDataSource::GotDataCallback& callback, | 42 void OnGetTraceData(const content::URLDataSource::GotDataCallback& callback, |
| 42 scoped_refptr<base::RefCountedString> trace_data); | 43 scoped_refptr<base::RefCountedString> trace_data); |
| 43 | 44 |
| 44 DISALLOW_COPY_AND_ASSIGN(SlowTraceSource); | 45 DISALLOW_COPY_AND_ASSIGN(SlowTraceSource); |
| 45 }; | 46 }; |
| 46 | 47 |
| 47 class SlowTraceController : public content::WebUIController { | 48 class SlowTraceController : public content::WebUIController { |
| 48 public: | 49 public: |
| 49 explicit SlowTraceController(content::WebUI* web_ui); | 50 explicit SlowTraceController(content::WebUI* web_ui); |
| 50 | 51 |
| 51 private: | 52 private: |
| 52 DISALLOW_COPY_AND_ASSIGN(SlowTraceController); | 53 DISALLOW_COPY_AND_ASSIGN(SlowTraceController); |
| 53 }; | 54 }; |
| 54 | 55 |
| 55 } // namespace chromeos | 56 } // namespace chromeos |
| 56 | 57 |
| 57 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ | 58 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_SLOW_TRACE_UI_H_ |
| OLD | NEW |