Hide raw border adjuster when method pixelshift is selected

This commit is contained in:
heckflosse
2018-06-28 15:18:51 +02:00
parent 00cc9372d8
commit e7010e6a4d
2 changed files with 9 additions and 4 deletions

View File

@@ -46,7 +46,7 @@ BayerProcess::BayerProcess () : FoldableToolPanel(this, "bayerprocess", M("TP_RA
hb1->pack_end (*method, Gtk::PACK_EXPAND_WIDGET, 4);
pack_start( *hb1, Gtk::PACK_SHRINK, 4);
Gtk::HBox* borderbox = Gtk::manage (new Gtk::HBox ());
borderbox = Gtk::manage(new Gtk::HBox());
border = Gtk::manage(new Adjuster(M("TP_RAW_BORDER"), 0, 16, 1, 4));
border->setAdjusterListener (this);
@@ -353,9 +353,11 @@ void BayerProcess::read(const rtengine::procparams::ProcParams* pp, const Params
|| pp->raw.bayersensor.method == procparams::RAWParams::BayerSensor::getMethodString(procparams::RAWParams::BayerSensor::Method::DCBVNG4)
|| pp->raw.bayersensor.method == procparams::RAWParams::BayerSensor::getMethodString(procparams::RAWParams::BayerSensor::Method::RCDVNG4));
if (pp->raw.bayersensor.method == procparams::RAWParams::BayerSensor::getMethodString(procparams::RAWParams::BayerSensor::Method::PIXELSHIFT)) {
borderbox->hide();
pixelShiftOptions->set_visible(pp->raw.bayersensor.pixelShiftMotionCorrectionMethod == RAWParams::BayerSensor::PSMotionCorrectionMethod::CUSTOM);
pixelShiftFrame->show();
} else {
borderbox->show();
pixelShiftFrame->hide();
}
@@ -564,6 +566,7 @@ void BayerProcess::methodChanged ()
}
if (currentMethod == procparams::RAWParams::BayerSensor::Method::PIXELSHIFT) {
borderbox->hide();
if(pixelShiftMotionMethod->get_active_row_number() == 2) {
pixelShiftOptions->show();
} else {
@@ -571,6 +574,7 @@ void BayerProcess::methodChanged ()
}
pixelShiftFrame->show();
} else {
borderbox->show();
pixelShiftFrame->hide();
}
}

View File

@@ -31,6 +31,7 @@ class BayerProcess : public ToolParamBlock, public AdjusterListener, public Chec
protected:
MyComboBoxText* method;
Gtk::HBox* borderbox;
Gtk::HBox *imageNumberBox;
Adjuster* border;
MyComboBoxText* imageNumber;