/* This file is part of
- * ======================================================
+ * ======================================================
*
* LyX, The Document Processor
*
void FormToc::showInset( InsetCommand * const inset )
{
if ( dialog_!=0 || inset == 0 ) return;
-
+
inset_ = inset;
ih_ = inset_->hideDialog.connect(SigC::slot(this, &FormToc::hide));
-
+
params = inset->params();
show();
}
void FormToc::createInset( string const & arg )
{
if( dialog_!=0 ) return;
-
+
params.setFromString( arg );
show();
}
Gtk::MenuItem * e;
choice_->get_menu()->items().clear();
-
+
e = manage( new Gtk::MenuItem(_("Table of Contents")) );
e->activate.connect(SigC::bind<Buffer::TocType>(SigC::slot(this, &FormToc::changeList), Buffer::TOC_TOC));
choice_->get_menu()->append( *e );
// wrap buttons and connect slots
b_refresh = Gtk::wrap( GTK_BUTTON( lookup_widget(pd, "button_refresh") ) );
b_close = Gtk::wrap( GTK_BUTTON( lookup_widget(pd, "button_close") ) );
-
+
b_refresh->clicked.connect(SigC::bind<bool>(SigC::slot(this, &FormToc::updateSlot),false));
b_close->clicked.connect(dialog_->destroy.slot());
dialog_->destroy.connect(SigC::slot(this, &FormToc::free));
list_->items().push_back( *l );
return;
}
-
-
+
+
if (dialog_ != 0 &&
lv_->view()->available())
{
int selection = 0;
-
+
if( params.getCmdName() == "tableofcontents" )
{
type = Buffer::TOC_TOC;
ignore_callback_ = true;
choice_->set_history(selection);
ignore_callback_ = false;
-
+
list_->items().clear();
dialog_->set_title(wintitle);
void FormToc::apply(Buffer::TocItem tg)
{
-#if 0
+#if 0
// Doesn't compile anymore...
if (!lv_->view()->available()) return;
ih_.disconnect();
}
}
-