diff options
author | nils <nils@34ebc366-c3a9-4b3c-9f84-69acf7962910> | 2011-01-17 23:27:07 +0000 |
---|---|---|
committer | nils <nils@34ebc366-c3a9-4b3c-9f84-69acf7962910> | 2011-01-17 23:27:07 +0000 |
commit | 8f3b9765f438834b386fbbc6ba016492e51db2f5 (patch) | |
tree | f4a9ffe9798ce5171040d0fbc2f33817bb738270 /quitdialog.cpp | |
parent | added quitdialog with checklist for documents to save, but there has to be so... (diff) | |
download | gpg4usb-8f3b9765f438834b386fbbc6ba016492e51db2f5.tar.gz gpg4usb-8f3b9765f438834b386fbbc6ba016492e51db2f5.zip |
saving is nearly done, but only the first document is handled
git-svn-id: http://cpunk.de/svn/src/gpg4usb/trunk@440 34ebc366-c3a9-4b3c-9f84-69acf7962910
Diffstat (limited to 'quitdialog.cpp')
-rwxr-xr-x | quitdialog.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/quitdialog.cpp b/quitdialog.cpp index e599f6b..38cf14e 100755 --- a/quitdialog.cpp +++ b/quitdialog.cpp @@ -47,10 +47,10 @@ QuitDialog::QuitDialog(QWidget *parent, QHash<int, QString> unsavedDocs, QString mFileList->setEditTriggers(QAbstractItemView::NoEditTriggers); mFileList->setFocusPolicy(Qt::NoFocus); mFileList->horizontalHeader()->setStretchLastSection( true ); - // fill the table - while (i.hasNext()) { - i.next(); + i.toBack(); //jump to the end of list to fill the table backwards + while (i.hasPrevious()) { + i.previous(); mFileList->setRowCount(mFileList->rowCount()+1); // checkbox in front of filename @@ -119,7 +119,7 @@ QList <int> QuitDialog::getTabIdsToSave() QList <int> tabIdsToSave; for (int i = 0; i < mFileList->rowCount(); i++) { if (mFileList->item(i, 0)->checkState() == Qt::Checked) { - qDebug() << mFileList->item(i, 2)->text(); + qDebug() << "tabidtosave: " << mFileList->item(i, 2)->text(); tabIdsToSave << mFileList->item(i, 2)->text().toInt(); } } |