Fix some coverity issues
This commit is contained in:
parent
2fcb7d9665
commit
18076077c0
@ -255,29 +255,6 @@ Splash::Splash (Gtk::Window& parent) : Gtk::Dialog(M("GENERAL_ABOUT"), parent, t
|
||||
set_keep_above (true);
|
||||
}
|
||||
|
||||
Splash::Splash (Gtk::Window& parent, int maxtime) : Gtk::Dialog(M("GENERAL_ABOUT"), parent, true)
|
||||
{
|
||||
|
||||
splashImage = Gtk::manage(new SplashImage ());
|
||||
get_content_area()->pack_start (*splashImage);
|
||||
splashImage->show ();
|
||||
|
||||
if (maxtime > 0) {
|
||||
Glib::signal_timeout().connect (sigc::mem_fun(*this, &Splash::on_timer), maxtime);
|
||||
}
|
||||
|
||||
set_position (Gtk::WIN_POS_CENTER);
|
||||
|
||||
if (maxtime > 0) {
|
||||
set_decorated (false);
|
||||
}
|
||||
|
||||
add_events(Gdk::BUTTON_RELEASE_MASK);
|
||||
set_resizable (false);
|
||||
|
||||
set_keep_above (true);
|
||||
}
|
||||
|
||||
bool Splash::on_timer ()
|
||||
{
|
||||
|
||||
|
@ -48,7 +48,6 @@ private:
|
||||
Gtk::ScrolledWindow* releaseNotesSW;
|
||||
|
||||
public:
|
||||
Splash (Gtk::Window& parent, int maxtime);
|
||||
explicit Splash (Gtk::Window& parent);
|
||||
|
||||
bool hasReleaseNotes()
|
||||
|
@ -25,7 +25,7 @@
|
||||
using namespace std;
|
||||
|
||||
ThumbBrowserBase::ThumbBrowserBase ()
|
||||
: location(THLOC_FILEBROWSER), inspector(nullptr), isInspectorActive(false), lastClicked(nullptr), previewHeight(options.thumbSize), numOfCols(1)
|
||||
: location(THLOC_FILEBROWSER), inspector(nullptr), isInspectorActive(false), eventTime(0), lastClicked(nullptr), previewHeight(options.thumbSize), numOfCols(1)
|
||||
{
|
||||
inW = -1;
|
||||
inH = -1;
|
||||
|
@ -21,7 +21,7 @@
|
||||
#include "multilangmgr.h"
|
||||
#include "guiutils.h"
|
||||
|
||||
ToolBar::ToolBar () : showColPickers(true), listener (nullptr)
|
||||
ToolBar::ToolBar () : showColPickers(true), listener (nullptr), pickerListener(nullptr)
|
||||
{
|
||||
|
||||
editingMode = false;
|
||||
|
@ -28,7 +28,7 @@
|
||||
|
||||
using namespace rtengine::procparams;
|
||||
|
||||
ToolPanelCoordinator::ToolPanelCoordinator () : ipc(nullptr), editDataProvider(nullptr)
|
||||
ToolPanelCoordinator::ToolPanelCoordinator () : ipc(nullptr), hasChanged(false), editDataProvider(nullptr)
|
||||
{
|
||||
|
||||
exposurePanel = Gtk::manage (new ToolVBox ());
|
||||
@ -509,11 +509,11 @@ void ToolPanelCoordinator::initImage (rtengine::StagedImageProcessor* ipc_, bool
|
||||
toneCurve->enableAll ();
|
||||
toneCurve->enableListener ();
|
||||
|
||||
const rtengine::ImageMetaData* pMetaData = ipc->getInitialImage()->getMetaData();
|
||||
exifpanel->setImageData (pMetaData);
|
||||
iptcpanel->setImageData (pMetaData);
|
||||
|
||||
if (ipc) {
|
||||
const rtengine::ImageMetaData* pMetaData = ipc->getInitialImage()->getMetaData();
|
||||
exifpanel->setImageData (pMetaData);
|
||||
iptcpanel->setImageData (pMetaData);
|
||||
|
||||
ipc->setAutoExpListener (toneCurve);
|
||||
ipc->setAutoCamListener (colorappearance);
|
||||
ipc->setAutoBWListener (blackwhite);
|
||||
@ -526,12 +526,12 @@ void ToolPanelCoordinator::initImage (rtengine::StagedImageProcessor* ipc_, bool
|
||||
ipc->setSizeListener (crop);
|
||||
ipc->setSizeListener (resize);
|
||||
ipc->setImageTypeListener (this);
|
||||
flatfield->setShortcutPath(Glib::path_get_dirname(ipc->getInitialImage()->getFileName()));
|
||||
|
||||
icm->setRawMeta (raw, (const rtengine::ImageData*)pMetaData);
|
||||
lensProf->setRawMeta (raw, pMetaData);
|
||||
}
|
||||
|
||||
flatfield->setShortcutPath(Glib::path_get_dirname(ipc->getInitialImage()->getFileName()));
|
||||
|
||||
icm->setRawMeta (raw, (const rtengine::ImageData*)pMetaData);
|
||||
lensProf->setRawMeta (raw, pMetaData);
|
||||
|
||||
toneCurve->setRaw (raw);
|
||||
hasChanged = true;
|
||||
|
@ -170,19 +170,6 @@ protected:
|
||||
TextOrIcon* toiM;
|
||||
TextOrIcon* toiW;
|
||||
|
||||
Gtk::Label* labelE;
|
||||
Gtk::Label* labelD;
|
||||
Gtk::Label* labelC;
|
||||
Gtk::Label* labelT;
|
||||
Gtk::Label* labelR;
|
||||
Gtk::Label* labelM;
|
||||
|
||||
Gtk::Image* imgIconE;
|
||||
Gtk::Image* imgIconD;
|
||||
Gtk::Image* imgIconC;
|
||||
Gtk::Image* imgIconT;
|
||||
Gtk::Image* imgIconR;
|
||||
Gtk::Image* imgIconM;
|
||||
Gtk::Image* imgPanelEnd[6];
|
||||
Gtk::VBox* vbPanelEnd[6];
|
||||
|
||||
|
@ -428,7 +428,7 @@ void WhiteBalance::optChanged ()
|
||||
equal->setEditedState (UnEdited);
|
||||
tempBias->setEditedState (UnEdited);
|
||||
} else {
|
||||
int methodId = findWBEntryId (row[methodColumns.colLabel], WBLT_GUI);
|
||||
unsigned int methodId = findWBEntryId (row[methodColumns.colLabel], WBLT_GUI);
|
||||
WBEntry* currMethod = WBParams::wbEntries[methodId];
|
||||
|
||||
tempBias->set_sensitive(currMethod->type == WBT_AUTO);
|
||||
@ -792,7 +792,7 @@ void WhiteBalance::cache_customWB(int temp, double green)
|
||||
cache_customGreen (green);
|
||||
}
|
||||
|
||||
int WhiteBalance::findWBEntryId (Glib::ustring label, enum WB_LabelType lblType)
|
||||
unsigned int WhiteBalance::findWBEntryId (const Glib::ustring &label, enum WB_LabelType lblType)
|
||||
{
|
||||
for (unsigned int i = 0; i < WBParams::wbEntries.size(); i++) {
|
||||
if (label == (lblType == WBLT_GUI ? WBParams::wbEntries[i]->GUILabel : WBParams::wbEntries[i]->ppLabel)) {
|
||||
@ -800,7 +800,7 @@ int WhiteBalance::findWBEntryId (Glib::ustring label, enum WB_LabelType lblType)
|
||||
}
|
||||
}
|
||||
|
||||
return -1;
|
||||
return 0; // default to camera wb
|
||||
}
|
||||
|
||||
WBEntry* WhiteBalance::findWBEntry (Glib::ustring label, enum WB_LabelType lblType)
|
||||
|
@ -86,7 +86,7 @@ protected:
|
||||
int _setActiveMethod (Glib::ustring &label, Gtk::TreeModel::Children &children);
|
||||
|
||||
Gtk::TreeModel::Row getActiveMethod ();
|
||||
int findWBEntryId (Glib::ustring label, enum WB_LabelType lblType = WBLT_GUI);
|
||||
unsigned int findWBEntryId (const Glib::ustring &label, enum WB_LabelType lblType = WBLT_GUI);
|
||||
rtengine::procparams::WBEntry* findWBEntry (Glib::ustring label, enum WB_LabelType lblType = WBLT_GUI);
|
||||
|
||||
public:
|
||||
|
Loading…
x
Reference in New Issue
Block a user