-// -*- C++ -*-
/* This file is part of
* =================================================
*
#include <gnome--/dialog.h>
-GnomeBase::GnomeBase(ControlButton & c,
- string const & glade_file, string const & name)
+GnomeBase::GnomeBase(ControlButtons & c,
+ string const & name)
: ViewBC<gnomeBC>(c)
- , file_(glade_file), widget_name_(name), xml_(0)
+ , file_(name + ".glade"), widget_name_(name), xml_(0)
, dialog_(0)
{}
void GnomeBase::loadXML() const
{
+#ifdef WITH_WARNINGS
#warning Change this before declaring it production code! (be 20010325)
+#endif
string const path("src/frontends/gnome/dialogs/;frontends/gnome/dialogs/;/home/baruch/prog/lyx/graphics/src/frontends/gnome/dialogs/");
string const file = FileOpenSearch(path, file_, "glade");
if (file.empty()) {
lyxerr << "Cannot find glade file. Aborting." << std::endl;
- Assert(true);
+ lyx::Assert(true);
}
lyxerr[Debug::GUI] << "Glade file to open is " << file << '\n';
dialog_->hide();
}
+bool GnomeBase::validate()
+{
+ return true;
+}
+
+void GnomeBase::OKClicked()
+{
+ OKButton();
+}
+
+void GnomeBase::CancelClicked()
+{
+ CancelButton();
+}
+
+void GnomeBase::ApplyClicked()
+{
+ ApplyButton();
+}
+
+void GnomeBase::RestoreClicked()
+{
+ RestoreButton();
+}
+
+void GnomeBase::InputChanged()
+{
+ bc().valid(validate());
+}
Gnome::Dialog * GnomeBase::dialog()
{