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

Side by Side Diff: third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.h

Issue 2530843003: Introduce InsertIncrementalTextCommand to respect existing style for composition (Closed)
Patch Set: A little change Created 4 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
OLDNEW
(Empty)
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef InsertIncrementalTextCommand_h
6 #define InsertIncrementalTextCommand_h
7
8 #include "core/editing/commands/InsertTextCommand.h"
9
10 namespace blink {
11
12 class InsertIncrementalTextCommand final : public InsertTextCommand {
13 public:
14 static InsertIncrementalTextCommand* create(
15 Document& document,
16 const String& text,
17 bool selectInsertedText = false,
18 RebalanceType rebalanceType = RebalanceLeadingAndTrailingWhitespaces) {
19 return new InsertIncrementalTextCommand(document, text, selectInsertedText,
yosin_UTC9 2016/12/07 05:23:34 Let's move to .cpp file: https://www.chromium.org/
yabinh 2016/12/08 07:54:58 Done.
20 rebalanceType);
21 }
22
23 private:
24 InsertIncrementalTextCommand(Document&,
25 const String& text,
26 bool selectInsertedText,
27 RebalanceType);
28 const VisibleSelection computeSelectionForInsertion(
29 const size_t selectionStart,
yosin_UTC9 2016/12/07 05:23:34 Let's use |int| since other functions use |int|.
yabinh 2016/12/08 07:54:58 This function has been removed.
30 const size_t selectionEnd,
31 const size_t commonPrefixLength,
32 const size_t commonSuffixLength);
33 void setSelection(const size_t start, const size_t end, LocalFrame*);
34 void doApply(EditingState*) override;
35 };
36
37 } // namespace blink
38
39 #endif // InsertIncrementalTextCommand_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698