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

Side by Side Diff: chrome/browser/chromeos/text_input/candidate_window.cc

Issue 1142005: Mocks for all libcros elements (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 9 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 // TODO(satorux): 5 // TODO(satorux):
6 // - Implement a scroll bar or an indicator showing where you are in the 6 // - Implement a scroll bar or an indicator showing where you are in the
7 // candidate window. 7 // candidate window.
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 #include "app/app_paths.h" 13 #include "app/app_paths.h"
14 #include "app/resource_bundle.h" 14 #include "app/resource_bundle.h"
15 #include "base/at_exit.h" 15 #include "base/at_exit.h"
16 #include "base/file_path.h" 16 #include "base/file_path.h"
17 #include "base/observer_list.h" 17 #include "base/observer_list.h"
18 #include "base/path_service.h" 18 #include "base/path_service.h"
19 #include "base/process_util.h" 19 #include "base/process_util.h"
20 #include "base/scoped_ptr.h" 20 #include "base/scoped_ptr.h"
21 #include "base/utf_string_conversions.h" 21 #include "base/utf_string_conversions.h"
22 #include "chrome/browser/chromeos/cros/cros_library.h" 22 #include "chrome/browser/chromeos/cros/cros_library_loader.h"
23 #include "chrome/common/chrome_paths.h" 23 #include "chrome/common/chrome_paths.h"
24 #include "gfx/canvas.h" 24 #include "gfx/canvas.h"
25 #include "gfx/font.h" 25 #include "gfx/font.h"
26 #include "third_party/cros/chromeos_cros_api.h" 26 #include "third_party/cros/chromeos_cros_api.h"
27 #include "third_party/cros/chromeos_ime.h" 27 #include "third_party/cros/chromeos_ime.h"
28 #include "views/controls/label.h" 28 #include "views/controls/label.h"
29 #include "views/controls/textfield/textfield.h" 29 #include "views/controls/textfield/textfield.h"
30 #include "views/event.h" 30 #include "views/event.h"
31 #include "views/fill_layout.h" 31 #include "views/fill_layout.h"
32 #include "views/focus/accelerator_handler.h" 32 #include "views/focus/accelerator_handler.h"
(...skipping 908 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 gtk_init(&argc, &argv); 941 gtk_init(&argc, &argv);
942 942
943 // Initialize Chrome stuff. 943 // Initialize Chrome stuff.
944 base::AtExitManager exit_manager; 944 base::AtExitManager exit_manager;
945 base::EnableTerminationOnHeapCorruption(); 945 base::EnableTerminationOnHeapCorruption();
946 app::RegisterPathProvider(); 946 app::RegisterPathProvider();
947 ResourceBundle::InitSharedInstance(L"en-US"); 947 ResourceBundle::InitSharedInstance(L"en-US");
948 948
949 // Load libcros. 949 // Load libcros.
950 chrome::RegisterPathProvider(); // for libcros.so. 950 chrome::RegisterPathProvider(); // for libcros.so.
951 CHECK(chromeos::CrosLibrary::EnsureLoaded()) 951 chromeos::CrosLibraryLoader lib_loader;
952 << "Failed to load libcros"; 952 std::string error_string;
953 CHECK(lib_loader.Load(&error_string))
954 << "Failed to load libcros, " << error_string;
953 955
954 // Create the main message loop. 956 // Create the main message loop.
955 MessageLoop main_message_loop(MessageLoop::TYPE_UI); 957 MessageLoop main_message_loop(MessageLoop::TYPE_UI);
956 958
957 // Create the candidate window controller. 959 // Create the candidate window controller.
958 chromeos::CandidateWindowController controller; 960 chromeos::CandidateWindowController controller;
959 controller.Init(); 961 controller.Init();
960 962
961 // Start the main loop. 963 // Start the main loop.
962 views::AcceleratorHandler accelerator_handler; 964 views::AcceleratorHandler accelerator_handler;
963 MessageLoopForUI::current()->Run(&accelerator_handler); 965 MessageLoopForUI::current()->Run(&accelerator_handler);
964 966
965 return 0; 967 return 0;
966 } 968 }
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/status/power_menu_button.cc ('k') | chrome/browser/chromeos/text_input/text_input.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698