* \author Angus Leeming <a.leeming@ic.ac.uk>
*/
+#include <config.h>
+
#ifdef __GNUG__
#pragma implementation
#endif
-#include <config.h>
+#include "ViewBase.h"
+#include "ButtonControllerBase.h"
#include "ControlLog.h"
#include "LyXView.h"
#include "Dialogs.h"
#include "lyxrc.h"
+#include "BufferView.h"
-using std::make_pair;
using SigC::slot;
ControlLog::ControlLog(LyXView & lv, Dialogs & d)
- : ControlConnectBD(lv, d)
+ : ControlDialog<ControlConnectBD>(lv, d)
{
d_.showLogFile.connect(slot(this, &ControlLog::show));
}
-void ControlLog::show()
+void ControlLog::setParams()
{
- if (!lv_.view()->available())
- return;
-
- logfile_ = lv_.view()->buffer()->getLogName();
-
- bc().readOnly(isReadonly());
- view().show();
-}
-
-
-void ControlLog::update()
-{
- if (!lv_.view()->available())
- return;
-
logfile_ = lv_.view()->buffer()->getLogName();
-
- bc().readOnly(isReadonly());
- view().update();
}
-void ControlLog::hide()
+void ControlLog::clearParams()
{
logfile_.second.erase();
- disconnect();
- view().hide();
}