Add button to autostrech for each file
This commit is contained in:
@@ -37,6 +37,9 @@ StretchToolbar::StretchToolbar(QWidget *parent) : QToolBar(tr("Stretch toolbar")
|
||||
QAction *superPixelButton = addAction(QIcon(":/bayer.png"), tr("Superpixel CFA draw 2x2 pixel as one"));
|
||||
superPixelButton->setCheckable(true);
|
||||
connect(superPixelButton, SIGNAL(toggled(bool)), this, SIGNAL(superPixel(bool)));
|
||||
|
||||
m_autoStretchOnLoad = addAction(QIcon(":/nuke_a.png"), tr("Auto stretch"));
|
||||
m_autoStretchOnLoad->setCheckable(true);
|
||||
}
|
||||
|
||||
void StretchToolbar::stretchImage(Image *img)
|
||||
@@ -63,3 +66,10 @@ void StretchToolbar::resetMTF()
|
||||
emit paramChanged(0, 0.5, 1);
|
||||
}
|
||||
|
||||
void StretchToolbar::imageLoaded(Image *img)
|
||||
{
|
||||
if(m_autoStretchOnLoad->isChecked())
|
||||
stretchImage(img);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user