From c37164306b1cf713e63d607fa1d1e866a5bbaa12 Mon Sep 17 00:00:00 2001 From: Arno Date: Fri, 19 Oct 2012 16:03:17 +0200 Subject: Keep current Pic when adding files to PicViewer2 Try to get the position of the current picture after adding and clearing the file list of PictureViewer2. While thinking of using std::find for this I realized that the operator()-functions in Helper:: weren't used any more, so remove them and the includes. --- mappingtreemodel.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'mappingtreemodel.cpp') diff --git a/mappingtreemodel.cpp b/mappingtreemodel.cpp index 7817c96..07e3a24 100644 --- a/mappingtreemodel.cpp +++ b/mappingtreemodel.cpp @@ -9,8 +9,6 @@ #include #include -#include - #include "mappingtreemodel.h" #include "smtreeitem.h" @@ -38,7 +36,6 @@ MappingTreeModel::MappingTreeModel(QStringList &headers, QObject *parent) : SmTr mAddParentQ = new QSqlQuery(mDb); mAddParentQ->prepare("INSERT INTO mappings_parents2 (imapping_id, iparent_id) VALUES(:id, :parentid)"); mUpdateParentQ = new QSqlQuery(mDb); - //mUpdateParentQ->prepare("UPDATE mappings_parents SET iparent_id = :pid WHERE imapping_id = :id"); mUpdateParentQ->prepare("UPDATE mappings_parents2 SET iparent_id = :id where imappings_parents_id = :sid"); mDeleteMappingParentQ = new QSqlQuery(mDb); mDeleteMappingParentQ->prepare("DELETE FROM mappings_parents2 WHERE imappings_parents_id = :id"); -- cgit v1.2.3-70-g09d2