Skip to content

Commit 31279ea

Browse files
authored
Fix a preedit text bug (flutter-tizen#64)
* The return value of TextInputModel::selection is not a reference Signed-off-by: Boram Bae <[email protected]>
1 parent fe6a40a commit 31279ea

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

shell/platform/tizen/channels/text_input_channel.cc

+2-3
Original file line numberDiff line numberDiff line change
@@ -597,10 +597,9 @@ void TextInputChannel::OnPreedit(std::string str, int cursor_pos) {
597597

598598
have_preedit_ = false;
599599
if (edit_status_ == EditStatus::kPreeditStart) {
600-
TextRange selection = active_model_->selection();
601-
preedit_start_pos_ = selection.base();
600+
preedit_start_pos_ = active_model_->selection().base();
602601
active_model_->AddText(str);
603-
preedit_end_pos_ = selection.base();
602+
preedit_end_pos_ = active_model_->selection().base();
604603
have_preedit_ = true;
605604
SendStateUpdate(*active_model_);
606605
FT_LOGD("preedit start pos[%d], preedit end pos[%d]", preedit_start_pos_,

0 commit comments

Comments
 (0)