cppcheck: further fixes

This commit is contained in:
Ingo Weyrich
2019-07-31 20:02:35 +02:00
parent 0ed517d972
commit 4101102ddf
18 changed files with 62 additions and 189 deletions

View File

@@ -83,7 +83,6 @@ InspectorBuffer::~InspectorBuffer() {
Inspector::Inspector () : currImage(nullptr), zoom(0.0), active(false)
{
Glib::RefPtr<Gtk::StyleContext> style = get_style_context();
set_name("Inspector");
}
@@ -115,7 +114,6 @@ bool Inspector::on_draw(const ::Cairo::RefPtr< Cairo::Context> &cr)
// compute the displayed area
rtengine::Coord availableSize;
rtengine::Coord topLeft;
rtengine::Coord displayedSize;
rtengine::Coord dest(0, 0);
availableSize.x = win->get_width();
availableSize.y = win->get_height();
@@ -125,7 +123,6 @@ bool Inspector::on_draw(const ::Cairo::RefPtr< Cairo::Context> &cr)
if (imW < availableSize.x) {
// center the image in the available space along X
topLeft.x = 0;
displayedSize.x = availableSize.x;
dest.x = (availableSize.x - imW) / 2;
} else {
// partial image display
@@ -139,7 +136,6 @@ bool Inspector::on_draw(const ::Cairo::RefPtr< Cairo::Context> &cr)
if (imH < availableSize.y) {
// center the image in the available space along Y
topLeft.y = 0;
displayedSize.y = availableSize.y;
dest.y = (availableSize.y - imH) / 2;
} else {
// partial image display