mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-25 07:29:33 -05:00
Better message when there is no stickers
Fix infinite waiting cursor
This commit is contained in:
parent
8ff71150c5
commit
5e0dcdc080
@ -309,17 +309,19 @@ void Emoticons::refreshStickerTabs(QVector<QString>& stickerTabs, QString folder
|
||||
|
||||
void Emoticons::showStickerWidget(QWidget *parent, QWidget *button, const char *slotAddMethod, bool above)
|
||||
{
|
||||
QApplication::setOverrideCursor(Qt::WaitCursor);
|
||||
QVector<QString> stickerTabs;
|
||||
refreshStickerTabs(stickerTabs);
|
||||
if(stickerTabs.count() == 0) {
|
||||
QString message = "No stickers installed.\nYou can install them by putting images into one of these folders:\n" + stickerFolders.join('\n');
|
||||
QMessageBox::warning(parent, "Stickers", message);
|
||||
return;
|
||||
}
|
||||
|
||||
QApplication::setOverrideCursor(Qt::WaitCursor);
|
||||
QWidget *smWidget = new QWidget(parent, Qt::Popup) ;
|
||||
smWidget->setAttribute(Qt::WA_DeleteOnClose) ;
|
||||
smWidget->setWindowTitle("Stickers") ;
|
||||
|
||||
if(stickerTabs.count() == 0) {
|
||||
QMessageBox::warning(parent, "Stickers", "No stickers installed");
|
||||
return;
|
||||
}
|
||||
bool bOnlyOneGroup = (stickerTabs.count() == 1);
|
||||
|
||||
QTabWidget *smTab = nullptr;
|
||||
|
Loading…
Reference in New Issue
Block a user