Fix issue #3532 + a memory leak

This commit is contained in:
Hombre 2016-12-27 14:31:55 +01:00
parent c90b701999
commit 95f0d67dfe
3 changed files with 5 additions and 6 deletions

View File

@ -1639,8 +1639,7 @@ void EditorPanel::saveAsPressed ()
fnameOut = saveAsDialog->getFileName ();
options.lastSaveAsPath = saveAsDialog->getDirectory ();
options.saveAsDialogWidth = saveAsDialog->get_width ();
options.saveAsDialogHeight = saveAsDialog->get_height ();
saveAsDialog->get_size(options.saveAsDialogWidth, options.saveAsDialogHeight);
options.autoSuffix = saveAsDialog->getAutoSuffix ();
options.saveMethodNum = saveAsDialog->getSaveMethodNum ();
lastSaveAsFileName = Glib::path_get_basename (removeExtension (fnameOut));
@ -1709,6 +1708,8 @@ void EditorPanel::saveAsPressed ()
} while (!fnameOK);
saveAsDialog->hide();
delete saveAsDialog;
}
void EditorPanel::queueImgPressed ()

View File

@ -105,8 +105,7 @@ Preferences::~Preferences ()
{
profileStore.removeListener(this);
options.preferencesWidth = get_width();
options.preferencesHeight = get_height();
get_size(options.preferencesWidth, options.preferencesHeight);
}
Gtk::Widget* Preferences::getBatchProcPanel ()

View File

@ -690,8 +690,7 @@ bool RTWindow::on_delete_event(GdkEventAny* event)
ProfilePanel::cleanup();
if (!options.windowMaximized) {
options.windowWidth = get_width();
options.windowHeight = get_height();
get_size(options.windowWidth, options.windowHeight);
get_position (options.windowX, options.windowY);
}