Skip to content

TextField property autofocus: true ,Don't show ‘cut paste’ view #33293

@dansunhappy

Description

@dansunhappy

Steps to Reproduce

  1. input string is null
  2. autofocus: true
  3. long click not show ‘paste cut’ view

Code

TextField(
                    autofocus: true,
                    onSubmitted: _invitationCommit,
                    enabled: true,
                    controller: _textController,
                    maxLength: 8,
                    maxLines: 1,
                    style: TextStyle(
                      fontSize: flexible(context, 18.0),
                      height: 1.0,
                      color: Colors.black,
                      fontWeight: FontWeight.bold,
                    ),
                    decoration: InputDecoration.collapsed(
                      hintText: '',
                      filled: true,
                      fillColor: Colors.white,
                      border: InputBorder.none,
                    ).copyWith(counterText: ''),
                    keyboardType: TextInputType.numberWithOptions(),
                  ),

flutter --version

Flutter 1.5.4-hotfix.2 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 7a4c33425d (3 weeks ago) • 2019-04-29 11:05:24 -0700
Engine • revision 52c7a1e849
Tools • Dart 2.3.0 (build 2.3.0-dev.0.5 a1668566e5)

Metadata

Metadata

Assignees

No one assigned

    Labels

    a: text inputEntering text in a text field or keyboard related problemsf: material designflutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions