Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-95711

QML Treeview row selection is not following the click operation

    XMLWordPrintable

    Details

    • Platform/s:
      Linux/X11, Windows

      Description

      The name and version number of your compiler :  VS2017 / GCC9

      Qt version : 5.12.9

      The name and version number of your operating system: Windows 10  and Ubuntu 16.04 LTS

      Please refer the attached test app & screenshot TreeViewModel.zipwhich contains TreeView and QStandardItemModel.

      QStandardItemModel  , sets two roles ,

      m_roles[Qt::UserRole] = "index";

      m_roles[Qt::UserRole + 1] = "one";

      TreeView has two columns with above role names

      If we click on any row in Treeview , previous row looks to be selected as row highlighter appear for previous row.

       

      Expected behavior: Clicked row should be selected 

      Actual behavior :  Clicked row and row selection is off by one

       

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            qt.team.quick.subscriptions Qt Quick and Widgets Team
            Reporter:
            shriram.kulkarni Shriram Kulkarni
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:

                Gerrit Reviews

                There are no open Gerrit changes