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

Side by Side Diff: win8/metro_driver/ime/text_service.cc

Issue 103383004: Rename TSFTextStore to TextStore (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 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
« no previous file with comments | « no previous file | win8/metro_driver/ime/text_store.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "win8/metro_driver/ime/text_service.h" 5 #include "win8/metro_driver/ime/text_service.h"
6 6
7 #include <msctf.h> 7 #include <msctf.h>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/win/scoped_variant.h" 10 #include "base/win/scoped_variant.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 // position synchronously. 80 // position synchronously.
81 // The most complicated part is the OnDocumentChanged handler. Since some IMEs 81 // The most complicated part is the OnDocumentChanged handler. Since some IMEs
82 // such as Japanese IMEs drastically change their behavior depending on 82 // such as Japanese IMEs drastically change their behavior depending on
83 // properties exposed from the virtual document, we need to set up a lot 83 // properties exposed from the virtual document, we need to set up a lot
84 // properties carefully and correctly. See DocumentBinding class in this file 84 // properties carefully and correctly. See DocumentBinding class in this file
85 // about what will be involved in this multi-phase construction. See also 85 // about what will be involved in this multi-phase construction. See also
86 // text_store.cc and input_scope.cc for more underlying details. 86 // text_store.cc and input_scope.cc for more underlying details.
87 87
88 namespace metro_driver { 88 namespace metro_driver {
89 namespace { 89 namespace {
90 typedef TSFTextStore TextStore;
91 90
92 // Japanese IME expects the default value of this compartment is 91 // Japanese IME expects the default value of this compartment is
93 // TF_SENTENCEMODE_PHRASEPREDICT to emulate IMM32 behavior. This value is 92 // TF_SENTENCEMODE_PHRASEPREDICT to emulate IMM32 behavior. This value is
94 // managed per thread, thus setting this value at once is sufficient. This 93 // managed per thread, thus setting this value at once is sufficient. This
95 // value never affects non-Japanese IMEs. 94 // value never affects non-Japanese IMEs.
96 bool InitializeSentenceMode(ITfThreadMgr2* thread_manager, 95 bool InitializeSentenceMode(ITfThreadMgr2* thread_manager,
97 TfClientId client_id) { 96 TfClientId client_id) {
98 base::win::ScopedComPtr<ITfCompartmentMgr> thread_compartment_manager; 97 base::win::ScopedComPtr<ITfCompartmentMgr> thread_compartment_manager;
99 HRESULT hr = thread_compartment_manager.QueryFrom(thread_manager); 98 HRESULT hr = thread_compartment_manager.QueryFrom(thread_manager);
100 if (FAILED(hr)) { 99 if (FAILED(hr)) {
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 thread_manager->Deactivate(); 484 thread_manager->Deactivate();
486 return scoped_ptr<TextService>(); 485 return scoped_ptr<TextService>();
487 } 486 }
488 return scoped_ptr<TextService>(new TextServiceImpl(thread_manager, 487 return scoped_ptr<TextService>(new TextServiceImpl(thread_manager,
489 client_id, 488 client_id,
490 window_handle, 489 window_handle,
491 delegate)); 490 delegate));
492 } 491 }
493 492
494 } // namespace metro_driver 493 } // namespace metro_driver
OLDNEW
« no previous file with comments | « no previous file | win8/metro_driver/ime/text_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698