Demana confirmació per a canviar el idioma amb les tecles ràpides
Demana confirmació per reiniciar
This commit is contained in:
@@ -153,7 +153,7 @@ void Notifier::clearFinishedNotifications()
|
||||
}
|
||||
}
|
||||
|
||||
void Notifier::showText(std::vector<std::string> texts, int icon, const std::string &code)
|
||||
void Notifier::show(std::vector<std::string> texts, int icon, const std::string &code)
|
||||
{
|
||||
// Si no hay texto, acaba
|
||||
if (texts.empty())
|
||||
@@ -164,7 +164,7 @@ void Notifier::showText(std::vector<std::string> texts, int icon, const std::str
|
||||
// Si las notificaciones no se apilan, elimina las anteriores
|
||||
if (!stack_)
|
||||
{
|
||||
clearNotifications();
|
||||
clearAllNotifications();
|
||||
}
|
||||
|
||||
// Elimina las cadenas vacías
|
||||
@@ -298,7 +298,7 @@ void Notifier::showText(std::vector<std::string> texts, int icon, const std::str
|
||||
bool Notifier::isActive() { return !notifications_.empty(); }
|
||||
|
||||
// Finaliza y elimnina todas las notificaciones activas
|
||||
void Notifier::clearNotifications()
|
||||
void Notifier::clearAllNotifications()
|
||||
{
|
||||
for (auto ¬ification : notifications_)
|
||||
{
|
||||
@@ -317,4 +317,10 @@ std::vector<std::string> Notifier::getCodes()
|
||||
codes.emplace_back(notification.code);
|
||||
}
|
||||
return codes;
|
||||
}
|
||||
|
||||
// Comprueba si hay alguna notificacion con un código
|
||||
bool Notifier::checkCode(std::string code)
|
||||
{
|
||||
return stringInVector(getCodes(), code);
|
||||
}
|
||||
Reference in New Issue
Block a user