| 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 #include "chrome/browser/chromeos/dom_ui/menu_ui.h" | 5 #include "chrome/browser/chromeos/dom_ui/menu_ui.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/callback.h" | 9 #include "base/callback.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 623 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 634 return new MenuUIHTMLSource(delegate, | 634 return new MenuUIHTMLSource(delegate, |
| 635 source_name, | 635 source_name, |
| 636 menu_class, | 636 menu_class, |
| 637 menu_source_id, | 637 menu_source_id, |
| 638 menu_css_id); | 638 menu_css_id); |
| 639 } | 639 } |
| 640 | 640 |
| 641 // static | 641 // static |
| 642 bool MenuUI::IsEnabled() { | 642 bool MenuUI::IsEnabled() { |
| 643 return CommandLine::ForCurrentProcess()->HasSwitch( | 643 return CommandLine::ForCurrentProcess()->HasSwitch( |
| 644 switches::kEnableDOMUIMenu); | 644 switches::kEnableWebUIMenu); |
| 645 } | 645 } |
| 646 | 646 |
| 647 ChromeURLDataManager::DataSource* MenuUI::CreateDataSource() { | 647 ChromeURLDataManager::DataSource* MenuUI::CreateDataSource() { |
| 648 return CreateMenuUIHTMLSource(NULL, | 648 return CreateMenuUIHTMLSource(NULL, |
| 649 chrome::kChromeUIMenu, | 649 chrome::kChromeUIMenu, |
| 650 "Menu" /* class name */, | 650 "Menu" /* class name */, |
| 651 kNoExtraResource, | 651 kNoExtraResource, |
| 652 kNoExtraResource); | 652 kNoExtraResource); |
| 653 } | 653 } |
| 654 | 654 |
| 655 } // namespace chromeos | 655 } // namespace chromeos |
| OLD | NEW |