*/
#include <config.h>
-#ifdef __GNUG__
-#pragma implementation
-#endif
#include "inseturl.h"
#include "BufferView.h"
{}
+InsetUrl::~InsetUrl()
+{
+ InsetCommandMailer mailer("url", *this);
+ mailer.hideDialog();
+}
+
+
void InsetUrl::edit(BufferView * bv, int, int, mouse_button::state)
{
- bv->owner()->getDialogs().showUrl(this);
+ InsetCommandMailer mailer("url", *this);
+ mailer.showDialog(bv);
}
temp = _("HtmlUrl: ");
string url;
-
+
if (!getOptions().empty())
url += getOptions();
else
int InsetUrl::ascii(Buffer const *, ostream & os, int) const
{
if (getOptions().empty())
- os << "[" << getContents() << "]";
+ os << '[' << getContents() << ']';
else
- os << "[" << getContents() << "||" << getOptions() << "]";
+ os << '[' << getContents() << "||" << getOptions() << ']';
return 0;
}
int InsetUrl::linuxdoc(Buffer const *, ostream & os) const
{
- os << "<" << getCmdName()
+ os << '<' << getCmdName()
<< " url=\"" << getContents() << "\""
<< " name=\"" << getOptions() << "\">";