Skip to content

Commit

Permalink
Send a null response to signal that a message is not implemented on t…
Browse files Browse the repository at this point in the history
…he web text input channel (flutter#25314)
  • Loading branch information
jason-simmons authored Mar 31, 2021
1 parent 84e2a88 commit 2df3508
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/web_ui/lib/src/engine/text_editing/text_editing.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1373,9 +1373,13 @@ class TextEditingChannel {
// UITextInput.firstRecForRange.
break;

case 'TextInput.setCaretRect':
// No-op: not supported on this platform.
break;

default:
throw StateError(
'Unsupported method call on the flutter/textinput channel: ${call.method}');
EnginePlatformDispatcher.instance._replyToPlatformMessage(callback, null);
return;
}
EnginePlatformDispatcher.instance
._replyToPlatformMessage(callback, codec.encodeSuccessEnvelope(true));
Expand Down

0 comments on commit 2df3508

Please sign in to comment.