Merge n.6

Includes some memory leaks fixes, dcraw update
This commit is contained in:
ffsup2
2011-06-10 20:23:50 +02:00
13 changed files with 1027 additions and 1441 deletions

View File

@@ -53,7 +53,7 @@ FileCatalog::FileCatalog (CoarsePanel* cp, ToolBar* tb, FilePanel* filepanel) :
inTabMode=false;
// construct and initialize thumbnail browsers
fileBrowser = new FileBrowser();
fileBrowser = Gtk::manage( new FileBrowser() );
fileBrowser->setFileBrowserListener (this);
fileBrowser->setArrangement (ThumbBrowserBase::TB_Vertical);
fileBrowser->show ();

View File

@@ -36,9 +36,9 @@ FilePanel::FilePanel () : parent(NULL) {
dirpaned = Gtk::manage ( new Gtk::HPaned () );
dirpaned->set_position (options.dirBrowserWidth);
dirBrowser = new DirBrowser ();
placesBrowser = new PlacesBrowser ();
recentBrowser = new RecentBrowser ();
dirBrowser = Gtk::manage ( new DirBrowser () );
placesBrowser = Gtk::manage ( new PlacesBrowser () );
recentBrowser = Gtk::manage ( new RecentBrowser () );
placespaned = Gtk::manage ( new Gtk::VPaned () );
placespaned->set_size_request(50,100);
@@ -54,7 +54,7 @@ FilePanel::FilePanel () : parent(NULL) {
dirpaned->pack1 (*placespaned, false, true);
tpc = new BatchToolPanelCoordinator (this);
fileCatalog = new FileCatalog (tpc->coarse, tpc->getToolBar(), this);
fileCatalog = Gtk::manage ( new FileCatalog (tpc->coarse, tpc->getToolBar(),this) );
ribbonPane = Gtk::manage ( new Gtk::Paned() );
ribbonPane->add(*fileCatalog);
ribbonPane->set_size_request(50,150);
@@ -73,7 +73,7 @@ FilePanel::FilePanel () : parent(NULL) {
rightNotebook = Gtk::manage ( new Gtk::Notebook () );
//Gtk::VBox* taggingBox = Gtk::manage ( new Gtk::VBox () );
history = new History (false);
history = Gtk::manage ( new History (false) );
tpc->addPParamsChangeListener (history);
history->setProfileChangeListener (tpc);

View File

@@ -61,6 +61,7 @@ PopUpCommon::~PopUpCommon () {
}
if (menu) delete menu;
if (buttonImage) delete buttonImage;
delete buttonGroup;
}
PopUpCommon::type_signal_changed PopUpCommon::signal_changed() {

View File

@@ -34,7 +34,7 @@ public:
Gtk::HBox* buttonGroup; // this is the widget to be packed
PopUpCommon (Gtk::Button* button, const Glib::ustring& label = "");
~PopUpCommon ();
virtual ~PopUpCommon ();
bool addEntry (Glib::ustring imagePath, Glib::ustring label);
bool setSelected (int entryNum);
int getSelected () { return selected; }

View File

@@ -28,7 +28,7 @@ SaveFormatPanel::SaveFormatPanel () : listener (NULL) {
pngcompr = new Adjuster (M("SAVEDLG_PNGCOMPR"), 0, 6, 1, 6);
pngcompr->setAdjusterListener (this);
pngcompr->show ();
tiffuncompressed = Gtk::manage (new Gtk::CheckButton (M("SAVEDLG_TIFFUNCOMPRESSED")));
tiffuncompressed = new Gtk::CheckButton (M("SAVEDLG_TIFFUNCOMPRESSED"));
tiffuncompressed->signal_toggled().connect( sigc::mem_fun(*this,&SaveFormatPanel::formatChanged));
tiffuncompressed->show();
@@ -64,6 +64,12 @@ SaveFormatPanel::SaveFormatPanel () : listener (NULL) {
fstr[3] = "png";
fstr[4] = "png";
}
SaveFormatPanel::~SaveFormatPanel ()
{
delete jpegqual;
delete pngcompr;
delete tiffuncompressed;
}
void SaveFormatPanel::init (SaveFormat &sf) {

View File

@@ -47,6 +47,7 @@ class SaveFormatPanel : public Gtk::VBox, public AdjusterListener {
public:
SaveFormatPanel ();
~SaveFormatPanel ();
void setListener (FormatChangeListener* l) { listener = l; }
void init (SaveFormat& sf);