mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 10:00:33 +00:00
Revert "Don't asssert on (too) deeply nested items"
This reverts commit 44d1756783
.
This commit is contained in:
parent
44d1756783
commit
b296941d90
@ -633,45 +633,29 @@ bool BufferParams::spellignored(WordLangTuple const & wl) const
|
||||
|
||||
Bullet & BufferParams::temp_bullet(lyx::size_type const index)
|
||||
{
|
||||
if (index < 4)
|
||||
return pimpl_->temp_bullets[index];
|
||||
// Fallback bullet if we are too deeply nested
|
||||
docstring const fb = from_ascii("?") + convert<docstring>(index + 1);
|
||||
Bullet const & res = Bullet(fb);
|
||||
return const_cast<Bullet&>(res);
|
||||
LASSERT(index < 4, return pimpl_->temp_bullets[0]);
|
||||
return pimpl_->temp_bullets[index];
|
||||
}
|
||||
|
||||
|
||||
Bullet const & BufferParams::temp_bullet(lyx::size_type const index) const
|
||||
{
|
||||
if (index < 4)
|
||||
return pimpl_->temp_bullets[index];
|
||||
// Fallback bullet if we are too deeply nested
|
||||
docstring const fb = from_ascii("?") + convert<docstring>(index + 1);
|
||||
Bullet const & res = Bullet(fb);
|
||||
return res;
|
||||
LASSERT(index < 4, return pimpl_->temp_bullets[0]);
|
||||
return pimpl_->temp_bullets[index];
|
||||
}
|
||||
|
||||
|
||||
Bullet & BufferParams::user_defined_bullet(lyx::size_type const index)
|
||||
{
|
||||
if (index < 4)
|
||||
return pimpl_->user_defined_bullets[index];
|
||||
// Fallback bullet if we are too deeply nested
|
||||
docstring const fb = from_ascii("?") + convert<docstring>(index + 1);
|
||||
Bullet const & res = Bullet(fb);
|
||||
return const_cast<Bullet&>(res);
|
||||
LASSERT(index < 4, return pimpl_->temp_bullets[0]);
|
||||
return pimpl_->user_defined_bullets[index];
|
||||
}
|
||||
|
||||
|
||||
Bullet const & BufferParams::user_defined_bullet(lyx::size_type const index) const
|
||||
{
|
||||
if (index < 4)
|
||||
return pimpl_->user_defined_bullets[index];
|
||||
// Fallback bullet if we are too deeply nested
|
||||
docstring const fb = from_ascii("?") + convert<docstring>(index + 1);
|
||||
Bullet const & res = Bullet(fb);
|
||||
return res;
|
||||
LASSERT(index < 4, return pimpl_->temp_bullets[0]);
|
||||
return pimpl_->user_defined_bullets[index];
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user