mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-25 23:49:35 -05:00
made delete button and delete menu item call the same functions, so as to make the actions identical
This commit is contained in:
parent
234a510d6f
commit
f6bcfb549a
@ -738,7 +738,8 @@ void MessageWidget::remove()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool deleteReal = false;
|
#ifdef TO_REMOVE
|
||||||
|
bool deleteReal = false;
|
||||||
if (msgInfo.msgflags & RS_MSG_TRASH) {
|
if (msgInfo.msgflags & RS_MSG_TRASH) {
|
||||||
deleteReal = true;
|
deleteReal = true;
|
||||||
} else {
|
} else {
|
||||||
@ -763,8 +764,8 @@ void MessageWidget::remove()
|
|||||||
deleteLater();
|
deleteLater();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
emit messageRemoved();
|
emit messageRemovalRequested(currMsgId);
|
||||||
}
|
}
|
||||||
|
|
||||||
void MessageWidget::print()
|
void MessageWidget::print()
|
||||||
|
@ -61,6 +61,7 @@ public:
|
|||||||
|
|
||||||
signals:
|
signals:
|
||||||
void messageRemoved();
|
void messageRemoved();
|
||||||
|
void messageRemovalRequested(std::string);
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void reply();
|
void reply();
|
||||||
|
@ -144,7 +144,7 @@ MessagesDialog::MessagesDialog(QWidget *parent)
|
|||||||
|
|
||||||
msgWidget = new MessageWidget(true, this);
|
msgWidget = new MessageWidget(true, this);
|
||||||
ui.msgLayout->addWidget(msgWidget);
|
ui.msgLayout->addWidget(msgWidget);
|
||||||
connect(msgWidget, SIGNAL(messageRemoved()), this, SLOT(messageRemoved()));
|
connect(msgWidget, SIGNAL(messageRemovalRequested(std::string)), this, SLOT(removemessage()));
|
||||||
|
|
||||||
connectActions();
|
connectActions();
|
||||||
|
|
||||||
@ -838,7 +838,7 @@ void MessagesDialog::openAsWindow()
|
|||||||
}
|
}
|
||||||
|
|
||||||
msgWidget->activateWindow();
|
msgWidget->activateWindow();
|
||||||
connect(msgWidget, SIGNAL(messageRemoved()), this, SLOT(messageRemoved()));
|
connect(msgWidget, SIGNAL(messageRemovalRequested(std::string)), this, SLOT(removemessage()));
|
||||||
|
|
||||||
/* window will destroy itself! */
|
/* window will destroy itself! */
|
||||||
}
|
}
|
||||||
@ -858,7 +858,7 @@ void MessagesDialog::openAsTab()
|
|||||||
|
|
||||||
ui.tabWidget->addTab(msgWidget,FilesDefs::getIconFromQtResourcePath(IMAGE_MAIL), msgWidget->subject(true));
|
ui.tabWidget->addTab(msgWidget,FilesDefs::getIconFromQtResourcePath(IMAGE_MAIL), msgWidget->subject(true));
|
||||||
ui.tabWidget->setCurrentWidget(msgWidget);
|
ui.tabWidget->setCurrentWidget(msgWidget);
|
||||||
connect(msgWidget, SIGNAL(messageRemoved()), this, SLOT(messageRemoved()));
|
connect(msgWidget, SIGNAL(messageRemovalRequested(std::string)), this, SLOT(removemessage()));
|
||||||
|
|
||||||
/* window will destroy itself! */
|
/* window will destroy itself! */
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user