From 63273692c4e638b46a9e84026f62721784ec2cb4 Mon Sep 17 00:00:00 2001 From: "Johan B. C. Engelen" Date: Tue, 15 Jan 2008 14:29:14 +0000 Subject: prepare LPE parameter widgets to be owned by multiple dialogs, as it should be. For each parameter function that has not been re-implemented, a warning is issued. Sorry for the huge number of warnings showing when working with LPE. It is important to fix this asap. (bzr r4495) --- src/ui/dialog/livepatheffect-editor.cpp | 5 ++++- src/ui/dialog/livepatheffect-editor.h | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'src/ui') diff --git a/src/ui/dialog/livepatheffect-editor.cpp b/src/ui/dialog/livepatheffect-editor.cpp index b1dfda573..93e17c324 100644 --- a/src/ui/dialog/livepatheffect-editor.cpp +++ b/src/ui/dialog/livepatheffect-editor.cpp @@ -97,6 +97,7 @@ LivePathEffectEditor::~LivePathEffectEditor() { if (effectwidget) { effectcontrol_vbox.remove(*effectwidget); + delete effectwidget; effectwidget = NULL; } @@ -111,11 +112,12 @@ LivePathEffectEditor::showParams(LivePathEffect::Effect* effect) { if (effectwidget) { effectcontrol_vbox.remove(*effectwidget); + delete effectwidget; effectwidget = NULL; } explain_label.set_markup("" + effect->getName() + ""); - effectwidget = effect->getWidget(); + effectwidget = effect->newWidget(&tooltips); if (effectwidget) { effectcontrol_vbox.pack_start(*effectwidget, true, true); } @@ -130,6 +132,7 @@ LivePathEffectEditor::showText(Glib::ustring const &str) { if (effectwidget) { effectcontrol_vbox.remove(*effectwidget); + delete effectwidget; effectwidget = NULL; } diff --git a/src/ui/dialog/livepatheffect-editor.h b/src/ui/dialog/livepatheffect-editor.h index 2ec1f9d14..aed17434d 100644 --- a/src/ui/dialog/livepatheffect-editor.h +++ b/src/ui/dialog/livepatheffect-editor.h @@ -18,6 +18,7 @@ #include #include #include +#include #include "ui/widget/combo-enums.h" #include "live_effects/effect.h" @@ -60,6 +61,7 @@ private: Gtk::Frame effectcontrol_frame; Gtk::HBox effectapplication_hbox; Gtk::VBox effectcontrol_vbox; + Gtk::Tooltips tooltips; SPDesktop * current_desktop; -- cgit v1.2.3