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

Side by Side Diff: chrome/browser/ui/webui/local_omnibox_popup/local_omnibox_popup_ui.cc

Issue 11555033: Adding local html page used in Instant Extended mode when instant is disabled or unavailable. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix uninitialized variable. Created 8 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
(Empty)
1 // Copyright 2012 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 #include "chrome/browser/ui/webui/local_omnibox_popup/local_omnibox_popup_ui.h"
6
7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/ui/webui/chrome_url_data_manager.h"
9 #include "chrome/browser/ui/webui/chrome_web_ui_data_source.h"
10 #include "chrome/common/url_constants.h"
11 #include "content/public/browser/web_ui.h"
12 #include "content/public/browser/web_ui_controller.h"
13 #include "grit/browser_resources.h"
14
15
16 LocalOmniboxPopupUI::LocalOmniboxPopupUI(content::WebUI* web_ui)
17 : content::WebUIController(web_ui) {
18 ChromeWebUIDataSource* source = new ChromeWebUIDataSource(
19 chrome::kChromeUILocalOmniboxPopupHost);
20 source->add_resource_path("local_omnibox_popup.css",
21 IDR_LOCAL_OMNIBOX_POPUP_CSS);
22 source->add_resource_path("local_omnibox_popup.js",
23 IDR_LOCAL_OMNIBOX_POPUP_JS);
24 source->add_resource_path("local_omnibox_popup.js",
25 IDR_LOCAL_OMNIBOX_POPUP_JS);
26
27 source->add_resource_path("images/history_icon.png",
28 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_HISTORY_ICON_PNG);
29 source->add_resource_path("images/page_icon.png",
30 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_PAGE_ICON_PNG);
31 source->add_resource_path("images/search_icon.png",
32 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_SEARCH_ICON_PNG);
33 source->add_resource_path("images/2x/history_icon.png",
34 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_2X_HISTORY_ICON_PNG);
35 source->add_resource_path("images/2x/page_icon.png",
36 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_2X_PAGE_ICON_PNG);
37 source->add_resource_path("images/2x/search_icon.png",
38 IDR_LOCAL_OMNIBOX_POPUP_IMAGES_2X_SEARCH_ICON_PNG);
39
40 source->set_default_resource(IDR_LOCAL_OMNIBOX_POPUP_HTML);
41
42 Profile* profile = Profile::FromWebUI(web_ui);
43 ChromeURLDataManager::AddDataSource(profile, source);
44 }
45
46 LocalOmniboxPopupUI::~LocalOmniboxPopupUI() {
47 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/local_omnibox_popup/local_omnibox_popup_ui.h ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698