Commit b78cfd45ce5c979ab646cb280ef96bceec9a7419

Authored by Steven de Ridder
1 parent cb1cc3f7

Qt6 / c++17 changes.

CMakeLists.txt
... ... @@ -24,6 +24,8 @@ endif()
24 24  
25 25 # ==============================================================================
26 26  
  27 +set(CMAKE_CXX_STANDARD 17)
  28 +
27 29 include(projectheader)
28 30 project_header(osdev_dbconnector)
29 31  
... ...
src/CMakeLists.txt
... ... @@ -25,12 +25,12 @@ endif()
25 25 include(projectheader)
26 26 project_header(dbconnector)
27 27  
28   -find_package( Qt5Core REQUIRED )
29   -find_package( Qt5Sql REQUIRED )
  28 +find_package( Qt6Core REQUIRED )
  29 +find_package( Qt6Sql REQUIRED )
30 30  
31 31 include_directories( SYSTEM
32   - ${Qt5Core_INCLUDE_DIRS}
33   - ${Qt5Sql_INCLUDE_DIRS}
  32 + ${Qt6Core_INCLUDE_DIRS}
  33 + ${Qt6Sql_INCLUDE_DIRS}
34 34 )
35 35  
36 36 include(compiler)
... ...
src/dbconnector.cpp
... ... @@ -509,7 +509,7 @@ bool DbConnector::recordsExist( const QString& sTable, const QString& sField, co
509 509 {
510 510 valueList.append(this->toSqlValueString(v));
511 511 }
512   - QStringList uniqueValueList = valueList.toSet().toList();
  512 + QStringList uniqueValueList = valueList.toList();
513 513 auto queryResult = this->executeQuery(countQuery
514 514 .arg(this->quoteTableName(sTable))
515 515 .arg(this->quoteFieldName(sField))
... ...
src/dbconnector.h
... ... @@ -38,7 +38,7 @@
38 38  
39 39 class QSqlQuery;
40 40 class QString;
41   -class QStringList;
  41 +//class QStringList;
42 42 template<class K, class V> class QHash;
43 43 class QSqlDatabase;
44 44  
... ...