X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Finsets%2Finsetref.C;h=b6fccf4831454812d9da9976dabb845714e76d86;hb=4a5b7a5952ad2381fcdf4830511293e184c7c5a1;hp=4624c1d97bbd4906c8fc7c56cb39117daea5754b;hpb=efe0b0b8eb340b7c34ead8afe5d81b410d5e7865;p=lyx.git
diff --git a/src/insets/insetref.C b/src/insets/insetref.C
index 4624c1d97b..b6fccf4831 100644
--- a/src/insets/insetref.C
+++ b/src/insets/insetref.C
@@ -25,15 +25,20 @@ InsetRef::InsetRef(InsetCommandParams const & p, Buffer const & buf, bool)
void InsetRef::edit(BufferView * bv, int, int, unsigned int button)
{
// Eventually trigger dialog with button 3 not 1
- if (button == 3 )
+ if (button == 3)
bv->owner()->getLyXFunc()->
dispatch(LFUN_REF_GOTO, getContents());
- else if (button == 1 )
- bv->owner()->getDialogs()->showRef( this );
+ else if (button == 1)
+ bv->owner()->getDialogs()->showRef(this);
}
-string const InsetRef::getScreenLabel() const
+void InsetRef::edit(BufferView *, bool)
+{
+}
+
+
+string const InsetRef::getScreenLabel(Buffer const *) const
{
string temp;
for (int i = 0; !types[i].latex_name.empty(); ++ i)
@@ -58,7 +63,7 @@ int InsetRef::latex(Buffer const *, ostream & os,
if (getOptions().empty())
os << escape(getCommand());
else {
- InsetCommandParams p( getCmdName(), getContents(), "" );
+ InsetCommandParams p(getCmdName(), getContents(), "");
os << escape(p.getCommand());
}
return 0;
@@ -80,10 +85,10 @@ int InsetRef::linuxdoc(Buffer const *, ostream & os) const
}
-int InsetRef::docBook(Buffer const *, ostream & os) const
+int InsetRef::docbook(Buffer const *, ostream & os) const
{
if (getOptions().empty()) {
- os << "";
+ os << "";
} else {
os << "" << getOptions() << "";
@@ -96,9 +101,9 @@ int InsetRef::docBook(Buffer const *, ostream & os) const
void InsetRef::validate(LaTeXFeatures & features) const
{
if (getCmdName() == "vref" || getCmdName() == "vpageref")
- features.varioref = true;
+ features.require("varioref");
else if (getCmdName() == "prettyref")
- features.prettyref = true;
+ features.require("prettyref");
}
InsetRef::type_info InsetRef::types[] = {