mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 18:08:10 +00:00
Fix gcc warning and be 64 bit clean.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18312 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
accafcb88c
commit
9e371e2a24
@ -79,9 +79,9 @@ BufferParams & ControlDocument::params() const
|
||||
}
|
||||
|
||||
|
||||
int ControlDocument::id() const
|
||||
BufferId ControlDocument::id() const
|
||||
{
|
||||
return (int) &kernel().buffer();
|
||||
return &kernel().buffer();
|
||||
}
|
||||
|
||||
|
||||
|
@ -23,6 +23,9 @@ class TextClass;
|
||||
|
||||
namespace frontend {
|
||||
|
||||
///
|
||||
typedef void const * BufferId;
|
||||
|
||||
/** A controller for Document dialogs.
|
||||
*/
|
||||
class ControlDocument : public Dialog::Controller {
|
||||
@ -50,7 +53,7 @@ public:
|
||||
///
|
||||
BufferParams & params() const;
|
||||
///
|
||||
int id() const;
|
||||
BufferId id() const;
|
||||
///
|
||||
void setLanguage() const;
|
||||
///
|
||||
|
@ -112,7 +112,7 @@ PreambleModule::PreambleModule(): current_id_(0)
|
||||
}
|
||||
|
||||
|
||||
void PreambleModule::update(BufferParams const & params, int id)
|
||||
void PreambleModule::update(BufferParams const & params, BufferId id)
|
||||
{
|
||||
QString preamble = toqstr(params.preamble);
|
||||
// Nothing to do if the params and preamble are unchanged.
|
||||
|
@ -144,12 +144,15 @@ private:
|
||||
};
|
||||
|
||||
|
||||
typedef void const * BufferId;
|
||||
|
||||
|
||||
class PreambleModule : public UiWidget<Ui::PreambleUi>
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
PreambleModule();
|
||||
void update(BufferParams const & params, int id);
|
||||
void update(BufferParams const & params, BufferId id);
|
||||
void apply(BufferParams & params);
|
||||
|
||||
Q_SIGNALS:
|
||||
@ -161,9 +164,9 @@ protected:
|
||||
void on_preambleTE_textChanged() { changed(); }
|
||||
|
||||
private:
|
||||
typedef std::map<int, std::pair<int,int> > Coords;
|
||||
typedef std::map<BufferId, std::pair<int,int> > Coords;
|
||||
Coords preamble_coords_;
|
||||
int current_id_;
|
||||
BufferId current_id_;
|
||||
};
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user