Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [SOLVED] currentIndex() in QTreeView
Forum Updated to NodeBB v4.3 + New Features

[SOLVED] currentIndex() in QTreeView

Scheduled Pinned Locked Moved General and Desktop
2 Posts 1 Posters 2.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Anticross
    wrote on last edited by
    #1

    I have some dialog-based class which holds two members: QTreeView and model class based on QStandardItemModel. When i call function currentIndex() from tree-veiw I've got a crash, It happens whatever I have some items in my tree or have not. In model I realize now only data function. So, what can it be and what should I do first to solve this problem ?

    1 Reply Last reply
    0
    • A Offline
      A Offline
      Anticross
      wrote on last edited by
      #2

      Damn, my mistake I wrote this: @QTreeView * m_tbl = new QTreeView(this);@ but need to just initialize member.
      @m_tbl = new QTreeView(this);@

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved