Michael Schmitt's patch to remove unused arguments

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@8114 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
André Pönitz 2003-11-21 14:59:24 +00:00
parent bd3c961ace
commit a976dd9104
13 changed files with 27 additions and 16 deletions

View File

@ -180,7 +180,7 @@ void LCursor::getDim(int & asc, int & desc) const
asc = row.baseline(); asc = row.baseline();
desc = row.height() - asc; desc = row.height() - asc;
} else } else
innerInset()->getCursorDim(bv_, asc, desc); innerInset()->getCursorDim(asc, desc);
} }
@ -202,7 +202,7 @@ void LCursor::getPos(int & x, int & y) const
// Ugly as you like. // Ugly as you like.
//inset->getCursorPos(bv_, x, y); //inset->getCursorPos(bv_, x, y);
//y = inset->insetInInsetY() + bv_->text->cursor.y(); //y = inset->insetInInsetY() + bv_->text->cursor.y();
inset->getCursorPos(bv_, x, y); inset->getCursorPos(x, y);
x += inset->x(); x += inset->x();
y += cached_y_; y += cached_y_;
} }

View File

@ -1,3 +1,10 @@
2003-11-21 Michael Schmitt <michael.schmitt@teststep.org>
* insetcollapsable.[Ch]:
* insettabular.[Ch]:
* insettext.[Ch] (getCursorDim): squash unused variable
2003-11-21 Alfredo Braunstein <abraunst@lyx.org> 2003-11-21 Alfredo Braunstein <abraunst@lyx.org>
* insettext.C (edit): x0_,y0_ -> xo_,yo_ * insettext.C (edit): x0_,y0_ -> xo_,yo_

View File

@ -330,9 +330,9 @@ void InsetCollapsable::validate(LaTeXFeatures & features) const
} }
void InsetCollapsable::getCursorPos(BufferView * bv, int & x, int & y) const void InsetCollapsable::getCursorPos(int & x, int & y) const
{ {
inset.getCursorPos(bv, x , y); inset.getCursorPos(x , y);
y += - ascent() + height_collapsed() + inset.ascent(); y += - ascent() + height_collapsed() + inset.ascent();
} }

View File

@ -77,7 +77,7 @@ public:
/// ///
void validate(LaTeXFeatures & features) const; void validate(LaTeXFeatures & features) const;
/// get the screen x,y of the cursor /// get the screen x,y of the cursor
void getCursorPos(BufferView *, int & x, int & y) const; void getCursorPos(int & x, int & y) const;
/// ///
void setFont(BufferView *, LyXFont const &, bool toggleall = false, void setFont(BufferView *, LyXFont const &, bool toggleall = false,
bool selectall = false); bool selectall = false);

View File

@ -970,7 +970,7 @@ void InsetTabular::calculate_dimensions_of_cells(MetricsInfo & mi) const
} }
void InsetTabular::getCursorPos(BufferView *, int & x, int & y) const void InsetTabular::getCursorPos(int & x, int & y) const
{ {
x = TEXT_TO_INSET_OFFSET + cursorx_ - xo_; x = TEXT_TO_INSET_OFFSET + cursorx_ - xo_;
y = TEXT_TO_INSET_OFFSET + cursory_; y = TEXT_TO_INSET_OFFSET + cursory_;

View File

@ -110,7 +110,7 @@ public:
/// ///
InsetOld::Code lyxCode() const { return InsetOld::TABULAR_CODE; } InsetOld::Code lyxCode() const { return InsetOld::TABULAR_CODE; }
/// get the absolute screen x,y of the cursor /// get the absolute screen x,y of the cursor
void getCursorPos(BufferView *, int & x, int & y) const; void getCursorPos(int & x, int & y) const;
/// ///
bool tabularFeatures(BufferView * bv, std::string const & what); bool tabularFeatures(BufferView * bv, std::string const & what);
/// ///

View File

@ -438,7 +438,7 @@ void InsetText::validate(LaTeXFeatures & features) const
} }
void InsetText::getCursorPos(BufferView *, int & x, int & y) const void InsetText::getCursorPos(int & x, int & y) const
{ {
x = text_.cursor.x() + TEXT_TO_INSET_OFFSET; x = text_.cursor.x() + TEXT_TO_INSET_OFFSET;
y = text_.cursor.y() - dim_.asc + TEXT_TO_INSET_OFFSET; y = text_.cursor.y() - dim_.asc + TEXT_TO_INSET_OFFSET;

View File

@ -89,7 +89,7 @@ public:
/// ///
InsetOld::Code lyxCode() const { return InsetOld::TEXT_CODE; } InsetOld::Code lyxCode() const { return InsetOld::TEXT_CODE; }
/// FIXME, document /// FIXME, document
void getCursorPos(BufferView *, int & x, int & y) const; void getCursorPos(int & x, int & y) const;
/// ///
int insetInInsetY() const; int insetInInsetY() const;
/// ///

View File

@ -107,7 +107,7 @@ UpdatableInset::priv_dispatch(FuncRequest const & cmd, idx_type &, pos_type &)
} }
void UpdatableInset::getCursorDim(BufferView *, int &, int &) const void UpdatableInset::getCursorDim(int &, int &) const
{ {
BOOST_ASSERT(false); BOOST_ASSERT(false);
} }

View File

@ -30,9 +30,9 @@ public:
virtual EDITABLE editable() const; virtual EDITABLE editable() const;
/// return the cursor pos, relative to the inset pos /// return the cursor pos, relative to the inset pos
virtual void getCursorPos(BufferView *, int &, int &) const {} virtual void getCursorPos(int &, int &) const {}
/// return the cursor dim /// return the cursor dim
virtual void getCursorDim(BufferView *, int &, int &) const; virtual void getCursorDim(int &, int &) const;
/// ///
virtual bool insertInset(BufferView *, InsetOld *) { return false; } virtual bool insertInset(BufferView *, InsetOld *) { return false; }
/// ///

View File

@ -1,3 +1,7 @@
2003-11-21 Michael Schmitt <michael.schmitt@teststep.org>
* formulabase.C (getCursorDim): squash unused variable
2003-11-20 Angus Leeming <leeming@lyx.org> 2003-11-20 Angus Leeming <leeming@lyx.org>
* formulabase.C (getCursorDim): squash warning about unused variable. * formulabase.C (getCursorDim): squash warning about unused variable.

View File

@ -170,7 +170,7 @@ void InsetFormulaBase::getCursor(BufferView &, int & x, int & y) const
} }
void InsetFormulaBase::getCursorPos(BufferView *, int & x, int & y) const void InsetFormulaBase::getCursorPos(int & x, int & y) const
{ {
if (!mathcursor) { if (!mathcursor) {
lyxerr << "getCursorPos - should not happen"; lyxerr << "getCursorPos - should not happen";
@ -186,7 +186,7 @@ void InsetFormulaBase::getCursorPos(BufferView *, int & x, int & y) const
} }
void InsetFormulaBase::getCursorDim(BufferView *, int & asc, int & desc) const void InsetFormulaBase::getCursorDim(int & asc, int & desc) const
{ {
if (!mathcursor) if (!mathcursor)
return; return;

View File

@ -45,9 +45,9 @@ public:
/// what appears in the minibuffer when opening /// what appears in the minibuffer when opening
virtual std::string const editMessage() const; virtual std::string const editMessage() const;
/// ///
virtual void getCursorPos(BufferView *, int &, int &) const; virtual void getCursorPos(int &, int &) const;
/// ///
virtual void getCursorDim(BufferView *, int &, int &) const; virtual void getCursorDim(int &, int &) const;
/// get the absolute document x,y of the cursor /// get the absolute document x,y of the cursor
virtual void getCursor(BufferView & bv, int & x, int & y) const; virtual void getCursor(BufferView & bv, int & x, int & y) const;
/// ///