Merge branch 'dev' into spot-removal-tool
This commit is contained in:
@@ -34,7 +34,81 @@ class ProcParams;
|
||||
|
||||
struct ParamsEdited;
|
||||
|
||||
class PartialPasteDlg final : public Gtk::Dialog
|
||||
/* ==== PartialSpotWidgetListener ==== */
|
||||
class PartialSpotWidget;
|
||||
class PartialSpotWidgetListener
|
||||
{
|
||||
public:
|
||||
enum UpdateStatus {
|
||||
AllSelection = 1,
|
||||
NoSelection = 2,
|
||||
PartialSelection = 3
|
||||
};
|
||||
|
||||
public:
|
||||
PartialSpotWidgetListener() {};
|
||||
virtual ~PartialSpotWidgetListener() {};
|
||||
|
||||
virtual void partialSpotUpdated(const UpdateStatus status) = 0;
|
||||
};
|
||||
|
||||
/* ==== PartialSpotWidget ==== */
|
||||
class PartialSpotWidget:
|
||||
public Gtk::VBox
|
||||
{
|
||||
private:
|
||||
// Tree model to manage spot selection widget
|
||||
class SpotRow:
|
||||
public Gtk::TreeModel::ColumnRecord
|
||||
{
|
||||
public:
|
||||
Gtk::TreeModelColumn<bool> keep;
|
||||
Gtk::TreeModelColumn<Glib::ustring> spotname;
|
||||
|
||||
SpotRow()
|
||||
{
|
||||
add(keep);
|
||||
add(spotname);
|
||||
}
|
||||
};
|
||||
|
||||
// Spot selection widgets
|
||||
Gtk::TreeView* const treeview;
|
||||
sigc::connection treeviewconn;
|
||||
SpotRow spotRow;
|
||||
Glib::RefPtr<Gtk::ListStore> treemodel;
|
||||
|
||||
// Spot selection listener
|
||||
PartialSpotWidgetListener* selListener;
|
||||
|
||||
public:
|
||||
PartialSpotWidget();
|
||||
|
||||
// Setter for spot selection listener
|
||||
void setPartialSpotWidgetListener(PartialSpotWidgetListener* pswl)
|
||||
{
|
||||
selListener = pswl;
|
||||
}
|
||||
|
||||
// Spot selection widget management functions
|
||||
void updateSpotWidget(const rtengine::procparams::ProcParams* pp, const bool defValue);
|
||||
void enableAll();
|
||||
void disableAll();
|
||||
std::vector<bool> getSelectionStatus();
|
||||
|
||||
private:
|
||||
// GUI aspect management functions
|
||||
void render_keep(Gtk::CellRenderer* cell, const Gtk::TreeModel::iterator& iter);
|
||||
void render_spotname(Gtk::CellRenderer* cell, const Gtk::TreeModel::iterator& iter);
|
||||
|
||||
// Event management function
|
||||
void keepToggled(const Glib::ustring &path);
|
||||
};
|
||||
|
||||
/* ==== PartialPasteDlg ==== */
|
||||
class PartialPasteDlg final:
|
||||
public Gtk::Dialog,
|
||||
public PartialSpotWidgetListener
|
||||
{
|
||||
|
||||
public:
|
||||
@@ -52,6 +126,7 @@ public:
|
||||
Gtk::CheckButton* meta;
|
||||
Gtk::CheckButton* raw;
|
||||
Gtk::CheckButton* advanced;
|
||||
Gtk::CheckButton* locallab;
|
||||
|
||||
// options in basic:
|
||||
Gtk::CheckButton* wb;
|
||||
@@ -112,6 +187,8 @@ public:
|
||||
Gtk::CheckButton* exifch;
|
||||
Gtk::CheckButton* iptc;
|
||||
|
||||
// options in locallab:
|
||||
PartialSpotWidget* spots;
|
||||
|
||||
// options in raw:
|
||||
Gtk::CheckButton* raw_expos;
|
||||
@@ -146,7 +223,7 @@ public:
|
||||
Gtk::CheckButton* raw_preprocwb;
|
||||
|
||||
sigc::connection everythingConn, basicConn, detailConn, colorConn, lensConn, compositionConn, metaConn, rawConn, advancedConn;
|
||||
|
||||
sigc::connection locallabConn;
|
||||
sigc::connection wbConn, exposureConn, localcontrastConn, shConn, pcvignetteConn, gradientConn, labcurveConn, colorappearanceConn;
|
||||
sigc::connection spotConn, sharpenConn, gradsharpenConn, microcontrastConn, impdenConn, dirpyrdenConn, defringeConn, epdConn, fattalConn, dirpyreqConn, waveletConn, retinexConn, dehazeConn;
|
||||
sigc::connection vibranceConn, chmixerConn, hsveqConn, rgbcurvesConn, chmixerbwConn, colortoningConn, filmSimulationConn, softlightConn;
|
||||
@@ -173,4 +250,8 @@ public:
|
||||
void metaToggled ();
|
||||
void rawToggled ();
|
||||
void advancedToggled ();
|
||||
void locallabToggled ();
|
||||
|
||||
void updateSpotWidget(const rtengine::procparams::ProcParams* pp);
|
||||
void partialSpotUpdated(const UpdateStatus status);
|
||||
};
|
||||
|
Reference in New Issue
Block a user