in your header write a slot like
void treeViewClickProgress();
void treeViewClickProgress();
To copy to clipboard, switch view to plain text mode
after in your source code in mainwindows calling state
QObject::connect(treeview,
SIGNAL(Clicked
),
this,
SLOT(treeViewClickProgress
()));
QObject::connect(treeview,SIGNAL(Clicked),this,SLOT(treeViewClickProgress()));
To copy to clipboard, switch view to plain text mode
and at last write a void function like this;
void MainWindow::treeViewClickProgress()
{
int rowNum = ui->treeView->selectionModel()->currentIndex().row();
int colNum= ui->treeView->selectionModel()->currentIndex().column();
qDebug() << rowNum << colNum;
}
void MainWindow::treeViewClickProgress()
{
int rowNum = ui->treeView->selectionModel()->currentIndex().row();
int colNum= ui->treeView->selectionModel()->currentIndex().column();
qDebug() << rowNum << colNum;
}
To copy to clipboard, switch view to plain text mode
hope this help...
edit...
dont copy paste, thats pseudo code only..
Bookmarks