diff src/services/services.cpp @ 47:d8eb763e6661

information.cpp: add widgets to the list tab, and add an "optional date" widget like taiga has so users can specify whether to set the date or not
author Paper <mrpapersonic@gmail.com>
date Mon, 25 Sep 2023 00:43:38 -0400
parents 619cbd6e69f9
children 0c4138de2ea7
line wrap: on
line diff
--- a/src/services/services.cpp	Sat Sep 23 01:02:15 2023 -0400
+++ b/src/services/services.cpp	Mon Sep 25 00:43:38 2023 -0400
@@ -1,13 +1,27 @@
 #include "services/services.h"
 #include "core/session.h"
 #include "services/anilist.h"
+#include "gui/dialog/settings.h"
+#include <QMessageBox>
 
 namespace Services {
 
 void Synchronize() {
 	switch (session.config.service) {
 		case Anime::Services::ANILIST: AniList::GetAnimeList(); break;
-		default: break;
+		default: {
+			QMessageBox msg;
+			msg.setInformativeText("It seems you haven't yet selected a service to use.");
+			msg.setText("Would you like to select one now?");
+			msg.setStandardButtons(QMessageBox::Yes | QMessageBox::No);
+			msg.setDefaultButton(QMessageBox::Yes);
+			int ret = msg.exec();
+			if (ret == QMessageBox::Yes) {
+				SettingsDialog dialog;
+				dialog.exec();
+			}
+			break;
+		}
 	}
 }