fix bug 920

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6241 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
John Levon 2003-02-25 12:32:48 +00:00
parent 702c38daff
commit 6ea60cf308
3 changed files with 12 additions and 3 deletions

View File

@ -1,3 +1,9 @@
2003-02-25 John Levon <levon@movementarian.org>
* insetgraphicsParams.h:
* insetgraphics.C: don't start a load process if
the inset is set to NoDisplay (bug #920)
2003-02-22 John Levon <levon@movementarian.org>
* insetfloat.C:

View File

@ -219,7 +219,7 @@ string const InsetGraphics::statusMessage() const
switch (cache_->loader.status()) {
case grfx::WaitingToLoad:
msg = _("Waiting for draw request to start loading...");
msg = _("Not shown.");
break;
case grfx::Loading:
msg = _("Loading...");
@ -344,7 +344,10 @@ void InsetGraphics::draw(BufferView * bv, LyXFont const & font,
int old_x = int(x);
x += lwidth;
if (cache_->loader.status() == grfx::WaitingToLoad)
grfx::Params const & gparams = params().as_grfxParams();
if (gparams.display != grfx::NoDisplay
&& cache_->loader.status() == grfx::WaitingToLoad)
cache_->loader.startLoading(*this, *bv);
if (!cache_->loader.monitoring())

View File

@ -76,7 +76,7 @@ struct InsetGraphicsParams
// Only a subset of InsetGraphicsParams is needed for display purposes.
// This function also interrogates lyxrc to ascertain whether
// to display or not.
grfx::Params as_grfxParams(string const & filepath) const;
grfx::Params as_grfxParams(string const & filepath = string()) const;
private:
/// Initialize the object to a default status.