mirror of
				https://gitlab.com/comunic/comunicwatcher
				synced 2025-11-04 12:14:06 +00:00 
			
		
		
		
	Check system compatibility
This commit is contained in:
		
							
								
								
									
										9
									
								
								main.cpp
									
									
									
									
									
								
							
							
						
						
									
										9
									
								
								main.cpp
									
									
									
									
									
								
							@@ -1,4 +1,6 @@
 | 
			
		||||
#include <QApplication>
 | 
			
		||||
#include <QMessageBox>
 | 
			
		||||
#include <QSystemTrayIcon>
 | 
			
		||||
 | 
			
		||||
#include "loginwindow.h"
 | 
			
		||||
#include "refreshservice.h"
 | 
			
		||||
@@ -12,6 +14,13 @@ int main(int argc, char *argv[])
 | 
			
		||||
    QCoreApplication::setOrganizationDomain("communiquons.org");
 | 
			
		||||
    QCoreApplication::setApplicationName("ComunicWatcher");
 | 
			
		||||
 | 
			
		||||
    // Check if the system is compatible
 | 
			
		||||
    if(!QSystemTrayIcon::isSystemTrayAvailable()) {
 | 
			
		||||
        QMessageBox::warning(nullptr, QObject::tr("Unsupported system"), QObject::tr("Unfortunately, your system is not supported by this application..."));
 | 
			
		||||
        return -1;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    if(!AccountHelper::SignedIn()) {
 | 
			
		||||
        (new LoginWindow())->show();
 | 
			
		||||
    }
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user