OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_DATA_SOURCE_H_ | |
6 #define CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_DATA_SOURCE_H_ | |
7 #pragma once | |
8 | |
9 #include <string> | |
10 | |
11 #include "base/compiler_specific.h" | |
12 #include "chrome/browser/ui/webui/chrome_url_data_manager.h" | |
13 | |
14 // PrintPreviewDataSource serves data for chrome://print requests. | |
15 // | |
16 // The format for requesting data is as follows: | |
17 // chrome://print/<PrintPreviewUIAddrStr>/print.pdf | |
18 // | |
19 // Parameters (< > required): | |
20 // <PrintPreviewUIAddrStr> = Print preview UI identifier. | |
21 // | |
22 // Example: | |
23 // chrome://print/0xab0123ef/print.pdf | |
24 | |
25 class PrintPreviewDataSource : public ChromeURLDataManager::DataSource { | |
26 public: | |
27 PrintPreviewDataSource(); | |
Lei Zhang
2011/05/29 10:12:02
Have you thought about changing this to:
PrintPrev
kmadhusu
2011/05/29 16:38:04
Yeah I thought about it. But it will boils down to
| |
28 | |
29 // ChromeURLDataManager::DataSource implementation. | |
30 virtual void StartDataRequest(const std::string& path, | |
31 bool is_incognito, | |
32 int request_id) OVERRIDE; | |
33 virtual std::string GetMimeType(const std::string& path) const OVERRIDE; | |
34 | |
35 private: | |
36 virtual ~PrintPreviewDataSource(); | |
37 | |
38 DISALLOW_COPY_AND_ASSIGN(PrintPreviewDataSource); | |
39 }; | |
40 | |
41 #endif // CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_DATA_SOURCE_H_ | |
OLD | NEW |