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

Side by Side Diff: third_party/WebKit/Source/core/frame/LocalFrame.cpp

Issue 2931443003: Add support for Android spellcheck menu in Chrome/WebViews (Closed)
Patch Set: Simplify Mojo binding based on rockot@'s advice Created 3 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Simon Hausmann <hausmann@kde.org> 5 * 2000 Simon Hausmann <hausmann@kde.org>
6 * 2000 Stefan Schimanski <1Stein@gmx.de> 6 * 2000 Stefan Schimanski <1Stein@gmx.de>
7 * 2001 George Staikos <staikos@kde.org> 7 * 2001 George Staikos <staikos@kde.org>
8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
9 * rights reserved. 9 * rights reserved.
10 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> 10 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com>
(...skipping 26 matching lines...) Expand all
37 #include "core/CoreProbeSink.h" 37 #include "core/CoreProbeSink.h"
38 #include "core/dom/ChildFrameDisconnector.h" 38 #include "core/dom/ChildFrameDisconnector.h"
39 #include "core/dom/DocumentType.h" 39 #include "core/dom/DocumentType.h"
40 #include "core/dom/StyleChangeReason.h" 40 #include "core/dom/StyleChangeReason.h"
41 #include "core/editing/EditingUtilities.h" 41 #include "core/editing/EditingUtilities.h"
42 #include "core/editing/Editor.h" 42 #include "core/editing/Editor.h"
43 #include "core/editing/FrameSelection.h" 43 #include "core/editing/FrameSelection.h"
44 #include "core/editing/InputMethodController.h" 44 #include "core/editing/InputMethodController.h"
45 #include "core/editing/serializers/Serialization.h" 45 #include "core/editing/serializers/Serialization.h"
46 #include "core/editing/spellcheck/SpellChecker.h" 46 #include "core/editing/spellcheck/SpellChecker.h"
47 #include "core/editing/suggestion/TextSuggestionController.h"
47 #include "core/events/Event.h" 48 #include "core/events/Event.h"
48 #include "core/frame/ContentSettingsClient.h" 49 #include "core/frame/ContentSettingsClient.h"
49 #include "core/frame/EventHandlerRegistry.h" 50 #include "core/frame/EventHandlerRegistry.h"
50 #include "core/frame/FrameConsole.h" 51 #include "core/frame/FrameConsole.h"
51 #include "core/frame/LocalDOMWindow.h" 52 #include "core/frame/LocalDOMWindow.h"
52 #include "core/frame/LocalFrameClient.h" 53 #include "core/frame/LocalFrameClient.h"
53 #include "core/frame/LocalFrameView.h" 54 #include "core/frame/LocalFrameView.h"
54 #include "core/frame/PerformanceMonitor.h" 55 #include "core/frame/PerformanceMonitor.h"
55 #include "core/frame/Settings.h" 56 #include "core/frame/Settings.h"
56 #include "core/html/HTMLFrameElementBase.h" 57 #include "core/html/HTMLFrameElementBase.h"
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 visitor->Trace(dom_window_); 216 visitor->Trace(dom_window_);
216 visitor->Trace(page_popup_owner_); 217 visitor->Trace(page_popup_owner_);
217 visitor->Trace(script_controller_); 218 visitor->Trace(script_controller_);
218 visitor->Trace(editor_); 219 visitor->Trace(editor_);
219 visitor->Trace(spell_checker_); 220 visitor->Trace(spell_checker_);
220 visitor->Trace(selection_); 221 visitor->Trace(selection_);
221 visitor->Trace(event_handler_); 222 visitor->Trace(event_handler_);
222 visitor->Trace(console_); 223 visitor->Trace(console_);
223 visitor->Trace(input_method_controller_); 224 visitor->Trace(input_method_controller_);
224 visitor->Trace(frame_resource_coordinator_); 225 visitor->Trace(frame_resource_coordinator_);
226 visitor->Trace(text_suggestion_controller_);
225 Frame::Trace(visitor); 227 Frame::Trace(visitor);
226 Supplementable<LocalFrame>::Trace(visitor); 228 Supplementable<LocalFrame>::Trace(visitor);
227 } 229 }
228 230
229 void LocalFrame::Navigate(Document& origin_document, 231 void LocalFrame::Navigate(Document& origin_document,
230 const KURL& url, 232 const KURL& url,
231 bool replace_current_item, 233 bool replace_current_item,
232 UserGestureStatus user_gesture_status) { 234 UserGestureStatus user_gesture_status) {
233 navigation_scheduler_->ScheduleFrameNavigation(&origin_document, url, 235 navigation_scheduler_->ScheduleFrameNavigation(&origin_document, url,
234 replace_current_item); 236 replace_current_item);
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 ChildFrameDisconnector(*document).Disconnect(); 379 ChildFrameDisconnector(*document).Disconnect();
378 } 380 }
379 381
380 void LocalFrame::DocumentAttached() { 382 void LocalFrame::DocumentAttached() {
381 DCHECK(GetDocument()); 383 DCHECK(GetDocument());
382 GetEditor().Clear(); 384 GetEditor().Clear();
383 GetEventHandler().Clear(); 385 GetEventHandler().Clear();
384 Selection().DocumentAttached(GetDocument()); 386 Selection().DocumentAttached(GetDocument());
385 GetInputMethodController().DocumentAttached(GetDocument()); 387 GetInputMethodController().DocumentAttached(GetDocument());
386 GetSpellChecker().DocumentAttached(GetDocument()); 388 GetSpellChecker().DocumentAttached(GetDocument());
389 GetTextSuggestionController().DocumentAttached(GetDocument());
387 } 390 }
388 391
389 Frame* LocalFrame::FindFrameForNavigation(const AtomicString& name, 392 Frame* LocalFrame::FindFrameForNavigation(const AtomicString& name,
390 LocalFrame& active_frame) { 393 LocalFrame& active_frame) {
391 Frame* frame = Tree().Find(name); 394 Frame* frame = Tree().Find(name);
392 if (!frame || !active_frame.CanNavigate(*frame)) 395 if (!frame || !active_frame.CanNavigate(*frame))
393 return nullptr; 396 return nullptr;
394 return frame; 397 return frame;
395 } 398 }
396 399
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
737 navigation_scheduler_(NavigationScheduler::Create(this)), 740 navigation_scheduler_(NavigationScheduler::Create(this)),
738 script_controller_(ScriptController::Create( 741 script_controller_(ScriptController::Create(
739 *this, 742 *this,
740 *static_cast<LocalWindowProxyManager*>(GetWindowProxyManager()))), 743 *static_cast<LocalWindowProxyManager*>(GetWindowProxyManager()))),
741 editor_(Editor::Create(*this)), 744 editor_(Editor::Create(*this)),
742 spell_checker_(SpellChecker::Create(*this)), 745 spell_checker_(SpellChecker::Create(*this)),
743 selection_(FrameSelection::Create(*this)), 746 selection_(FrameSelection::Create(*this)),
744 event_handler_(new EventHandler(*this)), 747 event_handler_(new EventHandler(*this)),
745 console_(FrameConsole::Create(*this)), 748 console_(FrameConsole::Create(*this)),
746 input_method_controller_(InputMethodController::Create(*this)), 749 input_method_controller_(InputMethodController::Create(*this)),
750 text_suggestion_controller_(new TextSuggestionController(*this)),
747 navigation_disable_count_(0), 751 navigation_disable_count_(0),
748 page_zoom_factor_(ParentPageZoomFactor(this)), 752 page_zoom_factor_(ParentPageZoomFactor(this)),
749 text_zoom_factor_(ParentTextZoomFactor(this)), 753 text_zoom_factor_(ParentTextZoomFactor(this)),
750 in_view_source_mode_(false), 754 in_view_source_mode_(false),
751 interface_registry_(interface_registry) { 755 interface_registry_(interface_registry) {
752 if (IsLocalRoot()) { 756 if (IsLocalRoot()) {
753 probe_sink_ = new CoreProbeSink(); 757 probe_sink_ = new CoreProbeSink();
754 performance_monitor_ = new PerformanceMonitor(this); 758 performance_monitor_ = new PerformanceMonitor(this);
755 } else { 759 } else {
756 // Inertness only needs to be updated if this frame might inherit the 760 // Inertness only needs to be updated if this frame might inherit the
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after
1095 void LocalFrame::SetViewportIntersectionFromParent( 1099 void LocalFrame::SetViewportIntersectionFromParent(
1096 const IntRect& viewport_intersection) { 1100 const IntRect& viewport_intersection) {
1097 if (remote_viewport_intersection_ != viewport_intersection) { 1101 if (remote_viewport_intersection_ != viewport_intersection) {
1098 remote_viewport_intersection_ = viewport_intersection; 1102 remote_viewport_intersection_ = viewport_intersection;
1099 if (View()) 1103 if (View())
1100 View()->ScheduleAnimation(); 1104 View()->ScheduleAnimation();
1101 } 1105 }
1102 } 1106 }
1103 1107
1104 } // namespace blink 1108 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/LocalFrame.h ('k') | third_party/WebKit/Source/modules/ModulesInitializer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698