| 
					
				 | 
			
			
				@@ -76,20 +76,17 @@ MainWindow::MainWindow(QWidget *parent) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     //// START DEBUG //// 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /// [F] I understand how it is annoying to not have the database 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /// working when something has changed. Hopefully this check 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    /// helps to avoid that in the future! 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    const int DATABASE_REVISION_NUMBER = 15; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    QSqlQuery query; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    query.prepare("SELECT COUNT (*) FROM changelog"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    query.exec(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    query.next(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    if (query.value(0).toInt() != DATABASE_REVISION_NUMBER) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("##########################################"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("Your database is out of date."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("Current Revision:  " << DATABASE_REVISION_NUMBER); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("You have revision: " << query.value(0).toInt()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("Use of DebugWidget to udpate recommended."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        DEB("##########################################"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    /// helps to avoid that in the future!  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    #if DATABASE < 15 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("Your database is up to date with the latest revision."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    #else 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("##########################################"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("Your database is out of date."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("Current Revision:  " << DATABASE_REVISION_NUMBER); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("You have revision: " << query.value(0).toInt()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("Use of DebugWidget to udpate recommended."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    DEB("##########################################"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    #endif 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     //// END DEBUG //// 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 } 
			 |