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

Side by Side Diff: ui/base/win/tsf_text_store_unittest.cc

Issue 10942005: Add TS_SS_TRANSITORY flag to the return value of TsfTextStore::GetStatus. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 3 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
« no previous file with comments | « ui/base/win/tsf_text_store.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ui/base/win/tsf_text_store.h" 5 #include "ui/base/win/tsf_text_store.h"
6 6
7 #include "base/win/scoped_com_initializer.h" 7 #include "base/win/scoped_com_initializer.h"
8 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
9 #include "testing/gmock/include/gmock/gmock.h" 9 #include "testing/gmock/include/gmock/gmock.h"
10 #include "ui/base/ime/text_input_client.h" 10 #include "ui/base/ime/text_input_client.h"
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 &rect, &clipped)); 278 &rect, &clipped));
279 } 279 }
280 280
281 TsfTextStore* text_store_; 281 TsfTextStore* text_store_;
282 }; 282 };
283 283
284 TEST_F(TsfTextStoreTest, GetStatusTest) { 284 TEST_F(TsfTextStoreTest, GetStatusTest) {
285 TS_STATUS status; 285 TS_STATUS status;
286 EXPECT_EQ(S_OK, text_store_->GetStatus(&status)); 286 EXPECT_EQ(S_OK, text_store_->GetStatus(&status));
287 EXPECT_EQ(0, status.dwDynamicFlags); 287 EXPECT_EQ(0, status.dwDynamicFlags);
288 EXPECT_EQ(TS_SS_NOHIDDENTEXT, status.dwStaticFlags); 288 EXPECT_EQ(TS_SS_TRANSITORY | TS_SS_NOHIDDENTEXT, status.dwStaticFlags);
289 } 289 }
290 290
291 291
292 class SyncRequestLockTestCallback : public TsfTextStoreTestCallback { 292 class SyncRequestLockTestCallback : public TsfTextStoreTestCallback {
293 public: 293 public:
294 explicit SyncRequestLockTestCallback(TsfTextStore* text_store) 294 explicit SyncRequestLockTestCallback(TsfTextStore* text_store)
295 : TsfTextStoreTestCallback(text_store) { 295 : TsfTextStoreTestCallback(text_store) {
296 } 296 }
297 297
298 HRESULT LockGranted1(DWORD flags) { 298 HRESULT LockGranted1(DWORD flags) {
(...skipping 837 matching lines...) Expand 10 before | Expand all | Expand 10 after
1136 &GetTextExtTestCallback::GetCompositionCharacterBounds)); 1136 &GetTextExtTestCallback::GetCompositionCharacterBounds));
1137 1137
1138 EXPECT_CALL(*sink_, OnLockGranted(_)) 1138 EXPECT_CALL(*sink_, OnLockGranted(_))
1139 .WillOnce(Invoke(&callback, &GetTextExtTestCallback::LockGranted)); 1139 .WillOnce(Invoke(&callback, &GetTextExtTestCallback::LockGranted));
1140 1140
1141 HRESULT result; 1141 HRESULT result;
1142 EXPECT_EQ(S_OK, text_store_->RequestLock(TS_LF_READ, &result)); 1142 EXPECT_EQ(S_OK, text_store_->RequestLock(TS_LF_READ, &result));
1143 } 1143 }
1144 1144
1145 } // namespace ui 1145 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/win/tsf_text_store.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698