Skip to content
Snippets Groups Projects
Unverified Commit 37123f04 authored by YU LIU's avatar YU LIU Committed by GitHub
Browse files

Disable the generation of empty images

parent 58b4d7aa
No related branches found
No related tags found
No related merge requests found
......@@ -112,6 +112,18 @@ void RandomImgOp::operator()(const imagein::Image*, const std::map<const imagein
if(code!=QDialog::Accepted) {
return;
}
if(dialog->getWidth()==0 || dialog->getHeight()==0){
QMessageBox *msgBox;
msgBox = new QMessageBox(QObject::tr("Warning"),
QObject::tr(" Empty image creation is not allowed "),
QMessageBox::Warning,
QMessageBox::Ok | QMessageBox::Default,
QMessageBox::NoRole | QMessageBox::Escape,
0);
msgBox->show();
return;
}
if(intButton->isChecked()) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment