mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-03 16:31:13 +00:00
2002-07-02 Lars Gullik Bj�nnes <larsbj@birdstep.com>
Dialogs.h: remove static from redrawGUI and toggleTooltips. And changes because of this. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4517 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
46917487e3
commit
5fd921e9e6
@ -1,3 +1,8 @@
|
|||||||
|
2002-07-02 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||||
|
|
||||||
|
* Dialogs.h: remove static from redrawGUI and
|
||||||
|
toggleTooltips.
|
||||||
|
|
||||||
2002-06-28 Angus Leeming <leeming@lyx.org>
|
2002-06-28 Angus Leeming <leeming@lyx.org>
|
||||||
|
|
||||||
* Painter.h:
|
* Painter.h:
|
||||||
|
@ -28,13 +28,13 @@
|
|||||||
|
|
||||||
// Signal enabling all visible dialogs to be redrawn if so desired.
|
// Signal enabling all visible dialogs to be redrawn if so desired.
|
||||||
// E.g., when the GUI colours have been remapped.
|
// E.g., when the GUI colours have been remapped.
|
||||||
boost::signal0<void> Dialogs::redrawGUI;
|
//boost::signal0<void> Dialogs::redrawGUI;
|
||||||
|
|
||||||
extern LyXView * dialogs_lyxview;
|
extern LyXView * dialogs_lyxview;
|
||||||
|
|
||||||
|
|
||||||
// toggle tooltips on/off in all dialogs.
|
// toggle tooltips on/off in all dialogs.
|
||||||
boost::signal0<void> Dialogs::toggleTooltips;
|
//boost::signal0<void> Dialogs::toggleTooltips;
|
||||||
|
|
||||||
void Dialogs::showAboutlyx()
|
void Dialogs::showAboutlyx()
|
||||||
{
|
{
|
||||||
|
@ -66,10 +66,10 @@ public:
|
|||||||
|
|
||||||
/** Redraw all visible dialogs because, for example, the GUI colours
|
/** Redraw all visible dialogs because, for example, the GUI colours
|
||||||
have been re-mapped. */
|
have been re-mapped. */
|
||||||
static boost::signal0<void> redrawGUI;
|
boost::signal0<void> redrawGUI;
|
||||||
|
|
||||||
/// Toggle tooltips on/off in all dialogs.
|
/// Toggle tooltips on/off in all dialogs.
|
||||||
static boost::signal0<void> toggleTooltips;
|
boost::signal0<void> toggleTooltips;
|
||||||
|
|
||||||
/// Are the tooltips on or off?
|
/// Are the tooltips on or off?
|
||||||
static bool tooltipsEnabled();
|
static bool tooltipsEnabled();
|
||||||
|
@ -23,10 +23,11 @@ using std::endl;
|
|||||||
extern LyXAction lyxaction;
|
extern LyXAction lyxaction;
|
||||||
|
|
||||||
|
|
||||||
Toolbar::Toolbar(LyXView * o, int x, int y, ToolbarDefaults const &tbd)
|
Toolbar::Toolbar(LyXView * o, Dialogs & d,
|
||||||
|
int x, int y, ToolbarDefaults const &tbd)
|
||||||
: last_textclass_(-1)
|
: last_textclass_(-1)
|
||||||
{
|
{
|
||||||
pimpl_ = new Pimpl(o, x, y);
|
pimpl_ = new Pimpl(o, d, x, y);
|
||||||
|
|
||||||
pimpl_->reset();
|
pimpl_->reset();
|
||||||
|
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
|
|
||||||
class LyXView;
|
class LyXView;
|
||||||
class ToolbarDefaults;
|
class ToolbarDefaults;
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/** The LyX GUI independent toolbar class
|
/** The LyX GUI independent toolbar class
|
||||||
The GUI interface is implemented in the corresponding Toolbar_pimpl class.
|
The GUI interface is implemented in the corresponding Toolbar_pimpl class.
|
||||||
@ -29,7 +30,8 @@ class ToolbarDefaults;
|
|||||||
class Toolbar {
|
class Toolbar {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
Toolbar(LyXView * o, int x, int y, ToolbarDefaults const &);
|
Toolbar(LyXView * o, Dialogs & d,
|
||||||
|
int x, int y, ToolbarDefaults const &);
|
||||||
|
|
||||||
///
|
///
|
||||||
~Toolbar();
|
~Toolbar();
|
||||||
|
@ -33,7 +33,7 @@ ControlConnectBase::ControlConnectBase(LyXView & lv, Dialogs & d)
|
|||||||
|
|
||||||
void ControlConnectBase::connect()
|
void ControlConnectBase::connect()
|
||||||
{
|
{
|
||||||
r_ = Dialogs::redrawGUI.
|
r_ = d_.redrawGUI.
|
||||||
connect(boost::bind(&ControlConnectBase::redraw, this));
|
connect(boost::bind(&ControlConnectBase::redraw, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -20,7 +20,7 @@ template <class Controller, class GUIview, class Policy, class GUIbc>
|
|||||||
class GUI : public Controller {
|
class GUI : public Controller {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
GUI(LyXView & lv, Dialogs & d) : Controller(lv, d), view_(*this) {}
|
GUI(LyXView & lv, Dialogs & d) : Controller(lv, d), view_(*this, d) {}
|
||||||
///
|
///
|
||||||
virtual ButtonControllerBase & bc() { return bc_; }
|
virtual ButtonControllerBase & bc() { return bc_; }
|
||||||
///
|
///
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
// -*- C++ -*-
|
||||||
/**
|
/**
|
||||||
* \file lyx_gui.h
|
* \file lyx_gui.h
|
||||||
* Copyright 2002 the LyX Team
|
* Copyright 2002 the LyX Team
|
||||||
@ -15,6 +16,8 @@
|
|||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/// GUI interaction
|
/// GUI interaction
|
||||||
namespace lyx_gui {
|
namespace lyx_gui {
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@ using std::endl;
|
|||||||
FileDialog::FileDialog(LyXView *lv, string const &t, kb_action s, Button b1, Button b2)
|
FileDialog::FileDialog(LyXView *lv, string const &t, kb_action s, Button b1, Button b2)
|
||||||
: private_(0), lv_(lv), title_(t), success_(s)
|
: private_(0), lv_(lv), title_(t), success_(s)
|
||||||
{
|
{
|
||||||
private_ = new FileDialog::Private;
|
private_ = new FileDialog::Private(*lv->getDialogs());
|
||||||
|
|
||||||
private_->SetButton(0, b1.first, b1.second);
|
private_->SetButton(0, b1.first, b1.second);
|
||||||
private_->SetButton(1, b2.first, b2.second);
|
private_->SetButton(1, b2.first, b2.second);
|
||||||
@ -43,7 +43,6 @@ FileDialog::FileDialog(LyXView *lv, string const &t, kb_action s, Button b1, But
|
|||||||
FileDialog::~FileDialog()
|
FileDialog::~FileDialog()
|
||||||
{
|
{
|
||||||
delete private_;
|
delete private_;
|
||||||
private_ = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,8 +25,8 @@ using std::getline;
|
|||||||
|
|
||||||
typedef FormCB<ControlAboutlyx, FormDB<FD_aboutlyx> > base_class;
|
typedef FormCB<ControlAboutlyx, FormDB<FD_aboutlyx> > base_class;
|
||||||
|
|
||||||
FormAboutlyx::FormAboutlyx(ControlAboutlyx & c)
|
FormAboutlyx::FormAboutlyx(ControlAboutlyx & c, Dialogs & d)
|
||||||
: base_class(c, _("About LyX"), false)
|
: base_class(c, d, _("About LyX"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,7 +30,7 @@ struct FD_aboutlyx_license;
|
|||||||
class FormAboutlyx : public FormCB<ControlAboutlyx, FormDB<FD_aboutlyx> > {
|
class FormAboutlyx : public FormCB<ControlAboutlyx, FormDB<FD_aboutlyx> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormAboutlyx(ControlAboutlyx &);
|
FormAboutlyx(ControlAboutlyx &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed.
|
/// not needed.
|
||||||
|
@ -32,9 +32,10 @@ static int C_PrehandlerCB(FL_OBJECT *, int, FL_Coord, FL_Coord, int, void *);
|
|||||||
} // extern "C"
|
} // extern "C"
|
||||||
|
|
||||||
|
|
||||||
FormBase::FormBase(ControlButtons & c, string const & t, bool allowResize)
|
FormBase::FormBase(ControlButtons & c, Dialogs & d,
|
||||||
|
string const & t, bool allowResize)
|
||||||
: ViewBC<xformsBC>(c), minw_(0), minh_(0), allow_resize_(allowResize),
|
: ViewBC<xformsBC>(c), minw_(0), minh_(0), allow_resize_(allowResize),
|
||||||
title_(t), tooltips_(new Tooltips)
|
title_(t), tooltips_(new Tooltips(d))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -28,6 +28,7 @@
|
|||||||
|
|
||||||
class xformsBC;
|
class xformsBC;
|
||||||
class Tooltips;
|
class Tooltips;
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/** This class is an XForms GUI base class.
|
/** This class is an XForms GUI base class.
|
||||||
*/
|
*/
|
||||||
@ -35,7 +36,8 @@ class FormBase : public ViewBC<xformsBC>, public FeedbackController
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormBase(ControlButtons &, string const &, bool allowResize);
|
FormBase(ControlButtons &, Dialogs &,
|
||||||
|
string const &, bool allowResize);
|
||||||
///
|
///
|
||||||
virtual ~FormBase();
|
virtual ~FormBase();
|
||||||
|
|
||||||
@ -91,7 +93,8 @@ class FormDB: public FormBase
|
|||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
///
|
///
|
||||||
FormDB(ControlButtons &, string const &, bool allowResize=true);
|
FormDB(ControlButtons &, Dialogs &,
|
||||||
|
string const &, bool allowResize=true);
|
||||||
/// Pointer to the actual instantiation of xform's form
|
/// Pointer to the actual instantiation of xform's form
|
||||||
virtual FL_FORM * form() const;
|
virtual FL_FORM * form() const;
|
||||||
/// Real GUI implementation.
|
/// Real GUI implementation.
|
||||||
@ -100,8 +103,9 @@ protected:
|
|||||||
|
|
||||||
|
|
||||||
template <class Dialog>
|
template <class Dialog>
|
||||||
FormDB<Dialog>::FormDB(ControlButtons & c, string const & t, bool allowResize)
|
FormDB<Dialog>::FormDB(ControlButtons & c, Dialogs & d,
|
||||||
: FormBase(c, t, allowResize)
|
string const & t, bool allowResize)
|
||||||
|
: FormBase(c, d, t, allowResize)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
@ -118,16 +122,17 @@ class FormCB: public Base
|
|||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
///
|
///
|
||||||
FormCB(Controller &, string const &, bool allowResize=true);
|
FormCB(Controller &, Dialogs &,
|
||||||
|
string const &, bool allowResize = true);
|
||||||
/// The parent controller
|
/// The parent controller
|
||||||
Controller & controller() const;
|
Controller & controller() const;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
template <class Controller, class Base>
|
template <class Controller, class Base>
|
||||||
FormCB<Controller, Base>::FormCB(Controller & c, string const & t,
|
FormCB<Controller, Base>::FormCB(Controller & c, Dialogs & d,
|
||||||
bool allowResize)
|
string const & t, bool allowResize)
|
||||||
: Base(c, t, allowResize)
|
: Base(c, d, t, allowResize)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -43,7 +43,7 @@ FormBaseDeprecated::FormBaseDeprecated(LyXView * lv, Dialogs * d,
|
|||||||
string const & t, bool allowResize)
|
string const & t, bool allowResize)
|
||||||
: lv_(lv), d_(d), title_(t),
|
: lv_(lv), d_(d), title_(t),
|
||||||
minw_(0), minh_(0), allow_resize_(allowResize),
|
minw_(0), minh_(0), allow_resize_(allowResize),
|
||||||
tooltips_(new Tooltips)
|
tooltips_(new Tooltips(*d))
|
||||||
{
|
{
|
||||||
lyx::Assert(lv && d);
|
lyx::Assert(lv && d);
|
||||||
}
|
}
|
||||||
@ -71,7 +71,7 @@ void FormBaseDeprecated::redraw()
|
|||||||
void FormBaseDeprecated::connect()
|
void FormBaseDeprecated::connect()
|
||||||
{
|
{
|
||||||
fl_set_form_minsize(form(), minw_, minh_);
|
fl_set_form_minsize(form(), minw_, minh_);
|
||||||
r_ = Dialogs::redrawGUI.connect(boost::bind(&FormBaseDeprecated::redraw, this));
|
r_ = d_->redrawGUI.connect(boost::bind(&FormBaseDeprecated::redraw, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -22,8 +22,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlBibitem, FormDB<FD_bibitem> > base_class;
|
typedef FormCB<ControlBibitem, FormDB<FD_bibitem> > base_class;
|
||||||
|
|
||||||
FormBibitem::FormBibitem(ControlBibitem & c)
|
FormBibitem::FormBibitem(ControlBibitem & c, Dialogs & d)
|
||||||
: base_class(c, _("Bibliography Entry"))
|
: base_class(c, d, _("Bibliography Entry"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,8 +26,7 @@ struct FD_bibitem;
|
|||||||
class FormBibitem : public FormCB<ControlBibitem, FormDB<FD_bibitem> > {
|
class FormBibitem : public FormCB<ControlBibitem, FormDB<FD_bibitem> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormBibitem(ControlBibitem &);
|
FormBibitem(ControlBibitem &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -36,8 +36,8 @@ using std::sort;
|
|||||||
|
|
||||||
typedef FormCB<ControlBibtex, FormDB<FD_bibtex> > base_class;
|
typedef FormCB<ControlBibtex, FormDB<FD_bibtex> > base_class;
|
||||||
|
|
||||||
FormBibtex::FormBibtex(ControlBibtex & c)
|
FormBibtex::FormBibtex(ControlBibtex & c, Dialogs & d)
|
||||||
: base_class(c, _("BibTeX Database"))
|
: base_class(c, d, _("BibTeX Database"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,8 +26,7 @@ struct FD_bibtex;
|
|||||||
class FormBibtex : public FormCB<ControlBibtex, FormDB<FD_bibtex> > {
|
class FormBibtex : public FormCB<ControlBibtex, FormDB<FD_bibtex> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormBibtex(ControlBibtex &);
|
FormBibtex(ControlBibtex &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -16,8 +16,9 @@
|
|||||||
#include "forms/form_browser.h"
|
#include "forms/form_browser.h"
|
||||||
#include "xformsBC.h"
|
#include "xformsBC.h"
|
||||||
|
|
||||||
FormBrowser::FormBrowser(ControlButtons & c, string const & t, bool allowResize)
|
FormBrowser::FormBrowser(ControlButtons & c, Dialogs & d,
|
||||||
: FormDB<FD_browser>(c, t, allowResize)
|
string const & t, bool allowResize)
|
||||||
|
: FormDB<FD_browser>(c, d, t, allowResize)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,8 +26,8 @@ struct FD_browser;
|
|||||||
class FormBrowser : public FormDB<FD_browser> {
|
class FormBrowser : public FormDB<FD_browser> {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormBrowser(ControlButtons &, string const &, bool allowResize=true);
|
FormBrowser(ControlButtons &, Dialogs &,
|
||||||
|
string const &, bool allowResize = true);
|
||||||
private:
|
private:
|
||||||
/// Build the dialog.
|
/// Build the dialog.
|
||||||
virtual void build();
|
virtual void build();
|
||||||
|
@ -36,8 +36,8 @@ using namespace frnt;
|
|||||||
|
|
||||||
typedef FormCB<ControlCharacter, FormDB<FD_character> > base_class;
|
typedef FormCB<ControlCharacter, FormDB<FD_character> > base_class;
|
||||||
|
|
||||||
FormCharacter::FormCharacter(ControlCharacter & c)
|
FormCharacter::FormCharacter(ControlCharacter & c, Dialogs & d)
|
||||||
: base_class(c, _("Character Layout"), false)
|
: base_class(c, d, _("Character Layout"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ class FormCharacter
|
|||||||
: public FormCB<ControlCharacter, FormDB<FD_character> > {
|
: public FormCB<ControlCharacter, FormDB<FD_character> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormCharacter(ControlCharacter &);
|
FormCharacter(ControlCharacter &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
|
|
||||||
/// Apply from dialog
|
/// Apply from dialog
|
||||||
|
@ -115,8 +115,8 @@ void updateStyle(FD_citation * dialog, string command)
|
|||||||
typedef FormCB<ControlCitation, FormDB<FD_citation> > base_class;
|
typedef FormCB<ControlCitation, FormDB<FD_citation> > base_class;
|
||||||
|
|
||||||
|
|
||||||
FormCitation::FormCitation(ControlCitation & c)
|
FormCitation::FormCitation(ControlCitation & c, Dialogs & d)
|
||||||
: base_class(c, _("Citation"), false)
|
: base_class(c, d, _("Citation"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,8 +25,7 @@ struct FD_citation;
|
|||||||
class FormCitation : public FormCB<ControlCitation, FormDB<FD_citation> > {
|
class FormCitation : public FormCB<ControlCitation, FormDB<FD_citation> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormCitation(ControlCitation &);
|
FormCitation(ControlCitation &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
///
|
///
|
||||||
enum State {
|
enum State {
|
||||||
|
@ -23,8 +23,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlERT, FormDB<FD_ert> > base_class;
|
typedef FormCB<ControlERT, FormDB<FD_ert> > base_class;
|
||||||
|
|
||||||
FormERT::FormERT(ControlERT & c)
|
FormERT::FormERT(ControlERT & c, Dialogs & d)
|
||||||
: base_class(c, _("ERT Options"))
|
: base_class(c, d, _("ERT Options"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@ class FormERT
|
|||||||
: public FormCB<ControlERT, FormDB<FD_ert> > {
|
: public FormCB<ControlERT, FormDB<FD_ert> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormERT(ControlERT &);
|
FormERT(ControlERT &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlError, FormDB<FD_error> > base_class;
|
typedef FormCB<ControlError, FormDB<FD_error> > base_class;
|
||||||
|
|
||||||
FormError::FormError(ControlError & c)
|
FormError::FormError(ControlError & c, Dialogs & d)
|
||||||
: base_class(c, _("LaTeX Error"))
|
: base_class(c, d, _("LaTeX Error"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_error;
|
|||||||
class FormError : public FormCB<ControlError, FormDB<FD_error> > {
|
class FormError : public FormCB<ControlError, FormDB<FD_error> > {
|
||||||
public:
|
public:
|
||||||
/// Constructor
|
/// Constructor
|
||||||
FormError(ControlError &);
|
FormError(ControlError &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed.
|
/// not needed.
|
||||||
virtual void apply() {}
|
virtual void apply() {}
|
||||||
|
@ -27,8 +27,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlExternal, FormDB<FD_external> > base_class;
|
typedef FormCB<ControlExternal, FormDB<FD_external> > base_class;
|
||||||
|
|
||||||
FormExternal::FormExternal(ControlExternal & c)
|
FormExternal::FormExternal(ControlExternal & c, Dialogs & d)
|
||||||
: base_class(c, _("Edit external file"))
|
: base_class(c, d, _("Edit external file"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,8 +26,7 @@ struct FD_external;
|
|||||||
class FormExternal : public FormCB<ControlExternal, FormDB<FD_external> > {
|
class FormExternal : public FormCB<ControlExternal, FormDB<FD_external> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormExternal(ControlExternal &);
|
FormExternal(ControlExternal &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// apply changes
|
/// apply changes
|
||||||
void apply();
|
void apply();
|
||||||
|
@ -422,7 +422,7 @@ void FileDialog::Private::SetInfoLine(string const & Line)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
FileDialog::Private::Private()
|
FileDialog::Private::Private(Dialogs & dia)
|
||||||
{
|
{
|
||||||
pszDirectory = MakeAbsPath(string("."));
|
pszDirectory = MakeAbsPath(string("."));
|
||||||
pszMask = '*';
|
pszMask = '*';
|
||||||
@ -459,7 +459,7 @@ FileDialog::Private::Private()
|
|||||||
fl_hide_object(pFileDlgForm->User1);
|
fl_hide_object(pFileDlgForm->User1);
|
||||||
fl_hide_object(pFileDlgForm->User2);
|
fl_hide_object(pFileDlgForm->User2);
|
||||||
|
|
||||||
r_ = Dialogs::redrawGUI.connect(boost::bind(&FileDialog::Private::redraw, this));
|
r_ = dia.redrawGUI.connect(boost::bind(&FileDialog::Private::redraw, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -27,6 +27,8 @@
|
|||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/// DirEntry internal structure definition
|
/// DirEntry internal structure definition
|
||||||
class DirEntry {
|
class DirEntry {
|
||||||
public:
|
public:
|
||||||
@ -51,7 +53,7 @@ class FD_filedialog;
|
|||||||
class FileDialog::Private : public boost::signals::trackable {
|
class FileDialog::Private : public boost::signals::trackable {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
Private();
|
Private(Dialogs &);
|
||||||
///
|
///
|
||||||
~Private();
|
~Private();
|
||||||
|
|
||||||
|
@ -22,8 +22,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlFloat, FormDB<FD_float> > base_class;
|
typedef FormCB<ControlFloat, FormDB<FD_float> > base_class;
|
||||||
|
|
||||||
FormFloat::FormFloat(ControlFloat & c)
|
FormFloat::FormFloat(ControlFloat & c, Dialogs & d)
|
||||||
: base_class(c, _("Float Options"))
|
: base_class(c, d, _("Float Options"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,8 +25,7 @@ struct FD_float;
|
|||||||
class FormFloat : public FormCB<ControlFloat, FormDB<FD_float> > {
|
class FormFloat : public FormCB<ControlFloat, FormDB<FD_float> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormFloat(ControlFloat &);
|
FormFloat(ControlFloat &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -30,8 +30,8 @@ using std::find_if;
|
|||||||
|
|
||||||
typedef FormCB<ControlForks, FormDB<FD_forks> > base_class;
|
typedef FormCB<ControlForks, FormDB<FD_forks> > base_class;
|
||||||
|
|
||||||
FormForks::FormForks(ControlForks & c)
|
FormForks::FormForks(ControlForks & c, Dialogs & d)
|
||||||
: base_class(c, _("Child processes"))
|
: base_class(c, d, _("Child processes"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@ struct FD_forks;
|
|||||||
class FormForks : public FormCB<ControlForks, FormDB<FD_forks> > {
|
class FormForks : public FormCB<ControlForks, FormDB<FD_forks> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormForks(ControlForks &);
|
FormForks(ControlForks &, Dialogs &);
|
||||||
|
|
||||||
/// preemptive handler for feedback messages
|
/// preemptive handler for feedback messages
|
||||||
void feedbackCB(FL_OBJECT *, int);
|
void feedbackCB(FL_OBJECT *, int);
|
||||||
|
@ -53,8 +53,8 @@ LyXLength getLyXLengthFromWidgets(FL_OBJECT * input, FL_OBJECT * choice)
|
|||||||
|
|
||||||
typedef FormCB<ControlGraphics, FormDB<FD_graphics> > base_class;
|
typedef FormCB<ControlGraphics, FormDB<FD_graphics> > base_class;
|
||||||
|
|
||||||
FormGraphics::FormGraphics(ControlGraphics & c)
|
FormGraphics::FormGraphics(ControlGraphics & c, Dialogs & d)
|
||||||
: base_class(c, _("Graphics"), false)
|
: base_class(c, d, _("Graphics"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
@ -513,7 +513,7 @@ ButtonPolicy::SMInput FormGraphics::input(FL_OBJECT * ob, long)
|
|||||||
}
|
}
|
||||||
if (controller().isFilenameValid(out_name) &&
|
if (controller().isFilenameValid(out_name) &&
|
||||||
!controller().bbChanged)
|
!controller().bbChanged)
|
||||||
updateBB(out_name, string());
|
updateBB(out_name, string());
|
||||||
|
|
||||||
} else if (ob == file_->check_subcaption) {
|
} else if (ob == file_->check_subcaption) {
|
||||||
setEnabled(file_->input_subcaption,
|
setEnabled(file_->input_subcaption,
|
||||||
|
@ -35,8 +35,7 @@ struct FD_graphics_special;
|
|||||||
class FormGraphics : public FormCB<ControlGraphics, FormDB<FD_graphics> > {
|
class FormGraphics : public FormCB<ControlGraphics, FormDB<FD_graphics> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormGraphics(ControlGraphics &);
|
FormGraphics(ControlGraphics &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
/** Redraw the form (on receipt of a Signal indicating, for example,
|
/** Redraw the form (on receipt of a Signal indicating, for example,
|
||||||
|
@ -26,8 +26,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlInclude, FormDB<FD_include> > base_class;
|
typedef FormCB<ControlInclude, FormDB<FD_include> > base_class;
|
||||||
|
|
||||||
FormInclude::FormInclude(ControlInclude & c)
|
FormInclude::FormInclude(ControlInclude & c, Dialogs & d)
|
||||||
: base_class(c, _("Include file"))
|
: base_class(c, d, _("Include file"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,8 +25,7 @@ struct FD_include;
|
|||||||
class FormInclude : public FormCB<ControlInclude, FormDB<FD_include> > {
|
class FormInclude : public FormCB<ControlInclude, FormDB<FD_include> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormInclude(ControlInclude &);
|
FormInclude(ControlInclude &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlIndex, FormDB<FD_index> > base_class;
|
typedef FormCB<ControlIndex, FormDB<FD_index> > base_class;
|
||||||
|
|
||||||
FormIndex::FormIndex(ControlIndex & c)
|
FormIndex::FormIndex(ControlIndex & c, Dialogs & d)
|
||||||
: base_class(c, _("Index"))
|
: base_class(c, d, _("Index"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_index;
|
|||||||
class FormIndex : public FormCB<ControlIndex, FormDB<FD_index> > {
|
class FormIndex : public FormCB<ControlIndex, FormDB<FD_index> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormIndex(ControlIndex &);
|
FormIndex(ControlIndex &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -19,8 +19,8 @@
|
|||||||
#include "gettext.h"
|
#include "gettext.h"
|
||||||
#include FORMS_H_LOCATION
|
#include FORMS_H_LOCATION
|
||||||
|
|
||||||
FormLog::FormLog(ControlLog & c)
|
FormLog::FormLog(ControlLog & c, Dialogs & d)
|
||||||
: FormCB<ControlLog, FormBrowser>(c, _("LaTeX Log"))
|
: FormCB<ControlLog, FormBrowser>(c, d, _("LaTeX Log"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class ControlLog;
|
|||||||
class FormLog : public FormCB<ControlLog, FormBrowser> {
|
class FormLog : public FormCB<ControlLog, FormBrowser> {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormLog(ControlLog &);
|
FormLog(ControlLog &, Dialogs &);
|
||||||
|
|
||||||
// Functions accessible to the Controller.
|
// Functions accessible to the Controller.
|
||||||
|
|
||||||
|
@ -24,8 +24,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlMinipage, FormDB<FD_minipage> > base_class;
|
typedef FormCB<ControlMinipage, FormDB<FD_minipage> > base_class;
|
||||||
|
|
||||||
FormMinipage::FormMinipage(ControlMinipage & c)
|
FormMinipage::FormMinipage(ControlMinipage & c, Dialogs & d)
|
||||||
: base_class(c, _("Minipage Options"))
|
: base_class(c, d, _("Minipage Options"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@ class FormMinipage
|
|||||||
: public FormCB<ControlMinipage, FormDB<FD_minipage> > {
|
: public FormCB<ControlMinipage, FormDB<FD_minipage> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormMinipage(ControlMinipage &);
|
FormMinipage(ControlMinipage &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -38,8 +38,8 @@ using std::remove_if;
|
|||||||
|
|
||||||
typedef FormCB<ControlParagraph, FormDB<FD_paragraph> > base_class;
|
typedef FormCB<ControlParagraph, FormDB<FD_paragraph> > base_class;
|
||||||
|
|
||||||
FormParagraph::FormParagraph(ControlParagraph & c)
|
FormParagraph::FormParagraph(ControlParagraph & c, Dialogs & d)
|
||||||
: base_class(c, _("Paragraph Layout"), false)
|
: base_class(c, d, _("Paragraph Layout"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
void FormParagraph::build()
|
void FormParagraph::build()
|
||||||
|
@ -25,7 +25,7 @@ class FormParagraph
|
|||||||
: public FormCB<ControlParagraph, FormDB<FD_paragraph> > {
|
: public FormCB<ControlParagraph, FormDB<FD_paragraph> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormParagraph(ControlParagraph &);
|
FormParagraph(ControlParagraph &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
/// Build the dialog
|
/// Build the dialog
|
||||||
virtual void build();
|
virtual void build();
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlPreamble, FormDB<FD_preamble> > base_class;
|
typedef FormCB<ControlPreamble, FormDB<FD_preamble> > base_class;
|
||||||
|
|
||||||
FormPreamble::FormPreamble(ControlPreamble & c)
|
FormPreamble::FormPreamble(ControlPreamble & c, Dialogs & d)
|
||||||
: base_class(c, _("LaTeX preamble"))
|
: base_class(c, d, _("LaTeX preamble"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@ struct FD_preamble;
|
|||||||
class FormPreamble : public FormCB<ControlPreamble, FormDB<FD_preamble> > {
|
class FormPreamble : public FormCB<ControlPreamble, FormDB<FD_preamble> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormPreamble(ControlPreamble &);
|
FormPreamble(ControlPreamble &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
/// Apply from dialog
|
/// Apply from dialog
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -427,7 +427,7 @@ void FormPreferences::Colors::apply()
|
|||||||
setCursorColor(GUI_COLOR_CURSOR);
|
setCursorColor(GUI_COLOR_CURSOR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Dialogs::redrawGUI();
|
parent_.lv_->getDialogs()->redrawGUI();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Now do the same for the LyX LColors...
|
// Now do the same for the LyX LColors...
|
||||||
|
@ -32,8 +32,8 @@ using std::make_pair;
|
|||||||
|
|
||||||
typedef FormCB<ControlPrint, FormDB<FD_print> > base_class;
|
typedef FormCB<ControlPrint, FormDB<FD_print> > base_class;
|
||||||
|
|
||||||
FormPrint::FormPrint(ControlPrint & c)
|
FormPrint::FormPrint(ControlPrint & c, Dialogs & d)
|
||||||
: base_class(c, _("Print")),
|
: base_class(c, d, _("Print")),
|
||||||
target_(2), order_(2), which_(3)
|
target_(2), order_(2), which_(3)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
@ -29,8 +29,7 @@ struct FD_print;
|
|||||||
class FormPrint : public FormCB<ControlPrint, FormDB<FD_print> > {
|
class FormPrint : public FormCB<ControlPrint, FormDB<FD_print> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormPrint(ControlPrint &);
|
FormPrint(ControlPrint &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Apply from dialog
|
/// Apply from dialog
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -30,8 +30,8 @@ using std::vector;
|
|||||||
|
|
||||||
typedef FormCB<ControlRef, FormDB<FD_ref> > base_class;
|
typedef FormCB<ControlRef, FormDB<FD_ref> > base_class;
|
||||||
|
|
||||||
FormRef::FormRef(ControlRef & c)
|
FormRef::FormRef(ControlRef & c, Dialogs & d)
|
||||||
: base_class(c, _("Reference")),
|
: base_class(c, d, _("Reference")),
|
||||||
at_ref_(false)
|
at_ref_(false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_ref;
|
|||||||
class FormRef : public FormCB<ControlRef, FormDB<FD_ref> > {
|
class FormRef : public FormCB<ControlRef, FormDB<FD_ref> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormRef(ControlRef &);
|
FormRef(ControlRef &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Set the Params variable for the Controller.
|
/// Set the Params variable for the Controller.
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -20,8 +20,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlSearch, FormDB<FD_search> > base_class;
|
typedef FormCB<ControlSearch, FormDB<FD_search> > base_class;
|
||||||
|
|
||||||
FormSearch::FormSearch(ControlSearch & c)
|
FormSearch::FormSearch(ControlSearch & c, Dialogs & d)
|
||||||
: base_class(c, _("LyX: Find and Replace"))
|
: base_class(c, d, _("LyX: Find and Replace"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_search;
|
|||||||
class FormSearch : public FormCB<ControlSearch, FormDB<FD_search> > {
|
class FormSearch : public FormCB<ControlSearch, FormDB<FD_search> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormSearch(ControlSearch &);
|
FormSearch(ControlSearch &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed.
|
/// not needed.
|
||||||
virtual void apply() {}
|
virtual void apply() {}
|
||||||
|
@ -26,8 +26,8 @@ using std::vector;
|
|||||||
|
|
||||||
typedef FormCB<ControlSendto, FormDB<FD_sendto> > base_class;
|
typedef FormCB<ControlSendto, FormDB<FD_sendto> > base_class;
|
||||||
|
|
||||||
FormSendto::FormSendto(ControlSendto & c)
|
FormSendto::FormSendto(ControlSendto & c, Dialogs & d)
|
||||||
: base_class(c, _("Send document to command"))
|
: base_class(c, d, _("Send document to command"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,8 +26,7 @@ struct FD_sendto;
|
|||||||
class FormSendto : public FormCB<ControlSendto, FormDB<FD_sendto> > {
|
class FormSendto : public FormCB<ControlSendto, FormDB<FD_sendto> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormSendto(ControlSendto &);
|
FormSendto(ControlSendto &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Apply from dialog (modify or create inset)
|
/// Apply from dialog (modify or create inset)
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -20,8 +20,8 @@
|
|||||||
#include FORMS_H_LOCATION
|
#include FORMS_H_LOCATION
|
||||||
|
|
||||||
|
|
||||||
FormShowFile::FormShowFile(ControlShowFile & c)
|
FormShowFile::FormShowFile(ControlShowFile & c, Dialogs & d)
|
||||||
: FormCB<ControlShowFile, FormBrowser>(c, string())
|
: FormCB<ControlShowFile, FormBrowser>(c, d, string())
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class ControlShowFile;
|
|||||||
class FormShowFile : public FormCB<ControlShowFile, FormBrowser> {
|
class FormShowFile : public FormCB<ControlShowFile, FormBrowser> {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormShowFile(ControlShowFile &);
|
FormShowFile(ControlShowFile &, Dialogs &);
|
||||||
|
|
||||||
// Functions accessible to the Controller.
|
// Functions accessible to the Controller.
|
||||||
|
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlSpellchecker, FormDB<FD_spellchecker> > base_class;
|
typedef FormCB<ControlSpellchecker, FormDB<FD_spellchecker> > base_class;
|
||||||
|
|
||||||
FormSpellchecker::FormSpellchecker(ControlSpellchecker & c)
|
FormSpellchecker::FormSpellchecker(ControlSpellchecker & c, Dialogs & d)
|
||||||
: base_class(c, _("LyX: Spellchecker"), false)
|
: base_class(c, d, _("LyX: Spellchecker"), false)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_spellchecker;
|
|||||||
class FormSpellchecker : public FormCB<ControlSpellchecker, FormDB<FD_spellchecker> > {
|
class FormSpellchecker : public FormCB<ControlSpellchecker, FormDB<FD_spellchecker> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormSpellchecker(ControlSpellchecker &);
|
FormSpellchecker(ControlSpellchecker &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed.
|
/// not needed.
|
||||||
void apply() {}
|
void apply() {}
|
||||||
|
@ -26,8 +26,8 @@ using std::make_pair;
|
|||||||
|
|
||||||
typedef FormCB<ControlTabularCreate, FormDB<FD_tabular_create> > base_class;
|
typedef FormCB<ControlTabularCreate, FormDB<FD_tabular_create> > base_class;
|
||||||
|
|
||||||
FormTabularCreate::FormTabularCreate(ControlTabularCreate & c)
|
FormTabularCreate::FormTabularCreate(ControlTabularCreate & c, Dialogs & d)
|
||||||
: base_class(c, _("Insert Tabular"))
|
: base_class(c, d, _("Insert Tabular"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -27,8 +27,7 @@ class FormTabularCreate :
|
|||||||
public FormCB<ControlTabularCreate, FormDB<FD_tabular_create> > {
|
public FormCB<ControlTabularCreate, FormDB<FD_tabular_create> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormTabularCreate(ControlTabularCreate &);
|
FormTabularCreate(ControlTabularCreate &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Apply from dialog
|
/// Apply from dialog
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -26,8 +26,8 @@
|
|||||||
|
|
||||||
|
|
||||||
typedef FormCB<ControlTexinfo, FormDB<FD_texinfo> > base_class;
|
typedef FormCB<ControlTexinfo, FormDB<FD_texinfo> > base_class;
|
||||||
FormTexinfo::FormTexinfo(ControlTexinfo & c)
|
FormTexinfo::FormTexinfo(ControlTexinfo & c, Dialogs & d)
|
||||||
: base_class(c, _("LaTeX Information")),
|
: base_class(c, d, _("LaTeX Information")),
|
||||||
activeStyle(ControlTexinfo::cls)
|
activeStyle(ControlTexinfo::cls)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
@ -22,8 +22,7 @@ struct FD_texinfo;
|
|||||||
class FormTexinfo : public FormCB<ControlTexinfo, FormDB<FD_texinfo> > {
|
class FormTexinfo : public FormCB<ControlTexinfo, FormDB<FD_texinfo> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormTexinfo(ControlTexinfo &);
|
FormTexinfo(ControlTexinfo &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed
|
/// not needed
|
||||||
virtual void apply() {}
|
virtual void apply() {}
|
||||||
|
@ -33,8 +33,8 @@ using std::vector;
|
|||||||
typedef FormCB<ControlThesaurus, FormDB<FD_thesaurus> > base_class;
|
typedef FormCB<ControlThesaurus, FormDB<FD_thesaurus> > base_class;
|
||||||
|
|
||||||
|
|
||||||
FormThesaurus::FormThesaurus(ControlThesaurus & c)
|
FormThesaurus::FormThesaurus(ControlThesaurus & c, Dialogs & d)
|
||||||
: base_class(c, _("LyX: Thesaurus"), false),
|
: base_class(c, d, _("LyX: Thesaurus"), false),
|
||||||
clickline_(-1)
|
clickline_(-1)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -24,8 +24,7 @@ struct FD_thesaurus;
|
|||||||
class FormThesaurus : public FormCB<ControlThesaurus, FormDB<FD_thesaurus> > {
|
class FormThesaurus : public FormCB<ControlThesaurus, FormDB<FD_thesaurus> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormThesaurus(ControlThesaurus &);
|
FormThesaurus(ControlThesaurus &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// not needed.
|
/// not needed.
|
||||||
virtual void apply() {}
|
virtual void apply() {}
|
||||||
|
@ -29,8 +29,8 @@ using std::endl;
|
|||||||
|
|
||||||
typedef FormCB<ControlToc, FormDB<FD_toc> > base_class;
|
typedef FormCB<ControlToc, FormDB<FD_toc> > base_class;
|
||||||
|
|
||||||
FormToc::FormToc(ControlToc & c)
|
FormToc::FormToc(ControlToc & c, Dialogs & d)
|
||||||
: base_class(c, _("Table of Contents"))
|
: base_class(c, d, _("Table of Contents"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ struct FD_toc;
|
|||||||
class FormToc : public FormCB<ControlToc, FormDB<FD_toc> > {
|
class FormToc : public FormCB<ControlToc, FormDB<FD_toc> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormToc(ControlToc &);
|
FormToc(ControlToc &, Dialogs &);
|
||||||
private:
|
private:
|
||||||
/// not needed
|
/// not needed
|
||||||
virtual void apply() {}
|
virtual void apply() {}
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
|
|
||||||
typedef FormCB<ControlUrl, FormDB<FD_url> > base_class;
|
typedef FormCB<ControlUrl, FormDB<FD_url> > base_class;
|
||||||
|
|
||||||
FormUrl::FormUrl(ControlUrl & c)
|
FormUrl::FormUrl(ControlUrl & c, Dialogs & d)
|
||||||
: base_class(c, _("Url"))
|
: base_class(c, d, _("Url"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,8 +24,7 @@ struct FD_url;
|
|||||||
class FormUrl : public FormCB<ControlUrl, FormDB<FD_url> > {
|
class FormUrl : public FormCB<ControlUrl, FormDB<FD_url> > {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormUrl(ControlUrl &);
|
FormUrl(ControlUrl &, Dialogs &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Apply from dialog (modify or create inset)
|
/// Apply from dialog (modify or create inset)
|
||||||
virtual void apply();
|
virtual void apply();
|
||||||
|
@ -20,8 +20,8 @@
|
|||||||
#include "gettext.h"
|
#include "gettext.h"
|
||||||
#include FORMS_H_LOCATION
|
#include FORMS_H_LOCATION
|
||||||
|
|
||||||
FormVCLog::FormVCLog(ControlVCLog & c)
|
FormVCLog::FormVCLog(ControlVCLog & c, Dialogs & d)
|
||||||
: FormCB<ControlVCLog, FormBrowser>(c, _("Version Control Log"))
|
: FormCB<ControlVCLog, FormBrowser>(c, d, _("Version Control Log"))
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class ControlVCLog;
|
|||||||
class FormVCLog : public FormCB<ControlVCLog, FormBrowser> {
|
class FormVCLog : public FormCB<ControlVCLog, FormBrowser> {
|
||||||
public:
|
public:
|
||||||
///
|
///
|
||||||
FormVCLog(ControlVCLog &);
|
FormVCLog(ControlVCLog &, Dialogs &);
|
||||||
|
|
||||||
// Functions accessible to the Controller.
|
// Functions accessible to the Controller.
|
||||||
|
|
||||||
|
@ -86,11 +86,11 @@ Toolbar::Pimpl::toolbarItem::operator=(toolbarItem const & ti)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
Toolbar::Pimpl::Pimpl(LyXView * o, int x, int y)
|
Toolbar::Pimpl::Pimpl(LyXView * o, Dialogs & d, int x, int y)
|
||||||
: owner(static_cast<XFormsView *>(o)), sxpos(x), sypos(y)
|
: owner(static_cast<XFormsView *>(o)), sxpos(x), sypos(y)
|
||||||
{
|
{
|
||||||
combox = 0;
|
combox = 0;
|
||||||
tooltip_ = new Tooltips;
|
tooltip_ = new Tooltips(d);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
|
|
||||||
class XFormsView;
|
class XFormsView;
|
||||||
class Tooltips;
|
class Tooltips;
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/** The LyX xforms toolbar class
|
/** The LyX xforms toolbar class
|
||||||
*/
|
*/
|
||||||
@ -34,7 +35,7 @@ public:
|
|||||||
/// called when user selects a layout from combox
|
/// called when user selects a layout from combox
|
||||||
static void layoutSelectedCB(int, void *, Combox *);
|
static void layoutSelectedCB(int, void *, Combox *);
|
||||||
///
|
///
|
||||||
Pimpl(LyXView * o, int x, int y);
|
Pimpl(LyXView * o, Dialogs &, int x, int y);
|
||||||
///
|
///
|
||||||
~Pimpl();
|
~Pimpl();
|
||||||
|
|
||||||
|
@ -35,12 +35,12 @@ boost::signal0<void> Tooltips::toggled;
|
|||||||
|
|
||||||
#if FL_VERSION > 0 || FL_REVISION >= 89
|
#if FL_VERSION > 0 || FL_REVISION >= 89
|
||||||
|
|
||||||
Tooltips::Tooltips()
|
Tooltips::Tooltips(Dialogs & d)
|
||||||
{
|
{
|
||||||
static bool first = true;
|
static bool first = true;
|
||||||
if (first) {
|
if (first) {
|
||||||
first = false;
|
first = false;
|
||||||
Dialogs::toggleTooltips.connect(boost::bind(&Tooltips::toggleEnabled));
|
d.toggleTooltips.connect(boost::bind(&Tooltips::toggleEnabled));
|
||||||
}
|
}
|
||||||
toggled.connect(boost::bind(&Tooltips::set, this));
|
toggled.connect(boost::bind(&Tooltips::set, this));
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,8 @@
|
|||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __GNUG__
|
#ifdef __GNUG__
|
||||||
#pragma interface
|
#pragma interface
|
||||||
@ -33,7 +35,7 @@
|
|||||||
|
|
||||||
class Tooltips : boost::noncopyable, public boost::signals::trackable {
|
class Tooltips : boost::noncopyable, public boost::signals::trackable {
|
||||||
public:
|
public:
|
||||||
Tooltips();
|
Tooltips(Dialogs &);
|
||||||
|
|
||||||
/// Initialise a tooltip for this ob.
|
/// Initialise a tooltip for this ob.
|
||||||
void init(FL_OBJECT * ob, string const & tip);
|
void init(FL_OBJECT * ob, string const & tip);
|
||||||
|
@ -59,7 +59,7 @@ int C_XFormsView_atCloseMainFormCB(FL_FORM * form, void * p)
|
|||||||
XFormsView::XFormsView(int width, int height)
|
XFormsView::XFormsView(int width, int height)
|
||||||
: LyXView()
|
: LyXView()
|
||||||
{
|
{
|
||||||
create_form_form_main(width, height);
|
create_form_form_main(*getDialogs(), width, height);
|
||||||
fl_set_form_atclose(getForm(), C_XFormsView_atCloseMainFormCB, 0);
|
fl_set_form_atclose(getForm(), C_XFormsView_atCloseMainFormCB, 0);
|
||||||
|
|
||||||
// Connect the minibuffer signals
|
// Connect the minibuffer signals
|
||||||
@ -68,7 +68,7 @@ XFormsView::XFormsView(int width, int height)
|
|||||||
|
|
||||||
// Make sure the buttons are disabled if needed.
|
// Make sure the buttons are disabled if needed.
|
||||||
updateToolbar();
|
updateToolbar();
|
||||||
Dialogs::redrawGUI.connect(boost::bind(&XFormsView::redraw, this));
|
getDialogs()->redrawGUI.connect(boost::bind(&XFormsView::redraw, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -123,7 +123,7 @@ void XFormsView::show(int x, int y, string const & title)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void XFormsView::create_form_form_main(int width, int height)
|
void XFormsView::create_form_form_main(Dialogs & dia, int width, int height)
|
||||||
/* to make this work as it should, .lyxrc should have been
|
/* to make this work as it should, .lyxrc should have been
|
||||||
* read first; OR maybe this one should be made dynamic.
|
* read first; OR maybe this one should be made dynamic.
|
||||||
* Hmmmm. Lgb.
|
* Hmmmm. Lgb.
|
||||||
@ -144,7 +144,8 @@ void XFormsView::create_form_form_main(int width, int height)
|
|||||||
|
|
||||||
menubar_.reset(new Menubar(this, menubackend));
|
menubar_.reset(new Menubar(this, menubackend));
|
||||||
|
|
||||||
toolbar_.reset(new Toolbar(this, air, 30 + air + bw, toolbardefaults));
|
toolbar_.reset(new Toolbar(this, dia,
|
||||||
|
air, 30 + air + bw, toolbardefaults));
|
||||||
toolbar_->set(true);
|
toolbar_->set(true);
|
||||||
|
|
||||||
int const ywork = 60 + 2 * air + bw;
|
int const ywork = 60 + 2 * air + bw;
|
||||||
|
@ -20,6 +20,8 @@
|
|||||||
|
|
||||||
#include "frontends/LyXView.h"
|
#include "frontends/LyXView.h"
|
||||||
|
|
||||||
|
class Dialogs;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* XFormsView - xforms implementation of LyXView
|
* XFormsView - xforms implementation of LyXView
|
||||||
*
|
*
|
||||||
@ -32,12 +34,12 @@ public:
|
|||||||
|
|
||||||
~XFormsView();
|
~XFormsView();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* show - display the top-level window
|
* show - display the top-level window
|
||||||
* @param xpos requested x position (or 0)
|
* @param xpos requested x position (or 0)
|
||||||
* @param xpos requested y position (or 0)
|
* @param xpos requested y position (or 0)
|
||||||
* @param title window title
|
* @param title window title
|
||||||
*/
|
*/
|
||||||
void show(int xpos, int ypos, string const & t = string("LyX"));
|
void show(int xpos, int ypos, string const & t = string("LyX"));
|
||||||
|
|
||||||
/// get the xforms main form
|
/// get the xforms main form
|
||||||
@ -61,7 +63,7 @@ private:
|
|||||||
virtual void setWindowTitle(string const & t, string const & it);
|
virtual void setWindowTitle(string const & t, string const & it);
|
||||||
|
|
||||||
/// makes the main form.
|
/// makes the main form.
|
||||||
void create_form_form_main(int width, int height);
|
void create_form_form_main(Dialogs & d, int width, int height);
|
||||||
/// the main form.
|
/// the main form.
|
||||||
boost::scoped_ptr<FL_FORM> form_;
|
boost::scoped_ptr<FL_FORM> form_;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user