rawTherapee/rtgui/gradient.h
Flössie 0731975ff0 Apply modernize-use-nullptr
Setup:
- `mkdir tidy; cd tidy`
- `cmake .. -DCMAKE_BUILD_TYPE=debug -DPROC_TARGET_NUMBER=1 -DCACHE_NAME_SUFFIX=4 -DBINDIR=. -DDATADIR=. -DBUILD_BUNDLE=ON -DWITH_LTO=OFF -DOPTION_OMP=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON`
- `cd ..`
- `find -name '*.cc' -exec clang-tidy-3.8 -header-filter=.* -p=tidy -fix-errors -checks=modernize-use-nullptr {} \;`
2016-10-12 17:48:40 +02:00

63 lines
1.8 KiB
C++

/*
* This file is part of RawTherapee.
*/
#ifndef _GRADIENT_H_
#define _GRADIENT_H_
#include <gtkmm.h>
#include "adjuster.h"
#include "toolpanel.h"
#include "edit.h"
#include "guiutils.h"
class Gradient : public ToolParamBlock, public AdjusterListener, public FoldableToolPanel, public EditSubscriber
{
private:
int lastObject;
protected:
Gtk::HBox *editHBox;
Gtk::ToggleButton* edit;
Adjuster* degree;
Adjuster* feather;
Adjuster* strength;
Adjuster* centerX;
Adjuster* centerY;
double draggedPointOldAngle;
double draggedPointAdjusterAngle;
double draggedFeatherOffset;
rtengine::Coord draggedCenter;
sigc::connection editConn;
void editToggled ();
public:
Gradient ();
~Gradient ();
void read (const rtengine::procparams::ProcParams* pp, const ParamsEdited* pedited = nullptr);
void write (rtengine::procparams::ProcParams* pp, ParamsEdited* pedited = nullptr);
void setDefaults (const rtengine::procparams::ProcParams* defParams, const ParamsEdited* pedited = nullptr);
void setBatchMode (bool batchMode);
void adjusterChanged (Adjuster* a, double newval);
void enabledChanged ();
void setAdjusterBehavior (bool degreeadd, bool featheradd, bool strengthadd, bool centeradd);
void trimValues (rtengine::procparams::ProcParams* pp);
void updateGeometry (const int centerX, const int centerY, const double feather, const double degree, const int fullWidth=-1, const int fullHeight=-1);
void setEditProvider (EditDataProvider* provider);
// EditSubscriber interface
CursorShape getCursor(const int objectID);
bool mouseOver(const int modifierKey);
bool button1Pressed(const int modifierKey);
bool button1Released();
bool drag1(const int modifierKey);
void switchOffEditMode ();
};
#endif