diff options
| author | Ben Boeckel <MathStuf@gmail.com> | 2008-05-15 17:03:09 +0000 |
|---|---|---|
| committer | Ben Boeckel <MathStuf@gmail.com> | 2008-05-15 17:03:09 +0000 |
| commit | 77124f3f105ea3837022d20a49028309a211c4b0 (patch) | |
| tree | 1cde0a6cc51bdd1048eb3d68b104a4abe2991377 /pokemodr/MapEffectUI.cpp | |
| parent | 9b537cc98f99f9de4f153dd33f6561d5cd89b2a6 (diff) | |
| download | sigen-77124f3f105ea3837022d20a49028309a211c4b0.tar.gz sigen-77124f3f105ea3837022d20a49028309a211c4b0.tar.xz sigen-77124f3f105ea3837022d20a49028309a211c4b0.zip | |
[FIX] Refactored the apply/discard buttons out of the widgets
git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@137 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'pokemodr/MapEffectUI.cpp')
| -rw-r--r-- | pokemodr/MapEffectUI.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/pokemodr/MapEffectUI.cpp b/pokemodr/MapEffectUI.cpp index 5aefb6fd..2e21f8f1 100644 --- a/pokemodr/MapEffectUI.cpp +++ b/pokemodr/MapEffectUI.cpp @@ -34,7 +34,6 @@ MapEffectUI::MapEffectUI(MapEffect* effect, QWidget* parent) : setupUi(this); QMetaObject::connectSlotsByName(this); setObjects(effect, new MapEffect(*effect)); - connect(this, SIGNAL(changed(bool)), boxButtons, SLOT(setEnabled(bool))); connect(modified(), SIGNAL(error(const QString&)), this, SLOT(setGui())); connect(modified(), SIGNAL(error(const QString&)), this, SLOT(errorMessage(const QString&))); connect(modified(), SIGNAL(warning(const QString&)), this, SLOT(warningMessage(const QString&))); @@ -111,13 +110,13 @@ void MapEffectUI::setGui() varDialog->setCurrentIndex(varDialog->findData(static_cast<MapEffect*>(modified())->dialog())); } -void MapEffectUI::on_buttonApply_clicked() +void MapEffectUI::apply() { *static_cast<MapEffect*>(original()) = *static_cast<MapEffect*>(modified()); emit(changed(false)); } -void MapEffectUI::on_buttonDiscard_clicked() +void MapEffectUI::discard() { *static_cast<MapEffect*>(modified()) = *static_cast<MapEffect*>(original()); setGui(); |
