Gui: remove pop-up dialog in case the macro directory is empty
This commit is contained in:
@@ -59,7 +59,6 @@ using namespace Gui::Dialog;
|
||||
DlgCustomActionsImp::DlgCustomActionsImp( QWidget* parent )
|
||||
: CustomizeActionPage(parent)
|
||||
, ui(new Ui_DlgCustomActions)
|
||||
, bShown(false)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
// search for all macros
|
||||
@@ -93,20 +92,6 @@ DlgCustomActionsImp::~DlgCustomActionsImp()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* Displays this page. If no macros were found a message box
|
||||
* appears.
|
||||
*/
|
||||
void DlgCustomActionsImp::showEvent(QShowEvent* e)
|
||||
{
|
||||
QWidget::showEvent(e);
|
||||
if (ui->actionMacros->count() == 0 && bShown == false)
|
||||
{
|
||||
bShown = true;
|
||||
QMessageBox::warning(this, tr("No macro"),tr("No macros found."));
|
||||
}
|
||||
}
|
||||
|
||||
bool DlgCustomActionsImp::event(QEvent* e)
|
||||
{
|
||||
bool ok = QWidget::event(e);
|
||||
|
||||
@@ -64,7 +64,6 @@ Q_SIGNALS:
|
||||
protected:
|
||||
/** Trigger for reparent event. */
|
||||
bool event(QEvent* e);
|
||||
void showEvent(QShowEvent* e);
|
||||
void changeEvent(QEvent *e);
|
||||
|
||||
protected Q_SLOTS:
|
||||
@@ -90,7 +89,6 @@ private:
|
||||
|
||||
private:
|
||||
std::unique_ptr<Ui_DlgCustomActions> ui;
|
||||
bool bShown; /**< For internal use only*/
|
||||
QString m_sPixmap; /**< Name of the specified pixmap */
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user