3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
6 * \author Lars Gullik Bjønnes
8 * Full author contact details are available in file CREDITS
15 #include "ToolbarDefaults.h"
16 #include "Toolbar_pimpl.h"
18 #include "LyXAction.h"
22 Toolbar::Toolbar(LyXView * o, int x, int y, ToolbarDefaults const &tbd)
25 pimpl_ = new Pimpl(o, x, y);
27 // extracts the toolbar actions from tbd
28 for (ToolbarDefaults::const_iterator cit = tbd.begin();
29 cit != tbd.end(); ++cit) {
31 lyxerr[Debug::GUI] << "tool action: " << (*cit) << endl;
42 void Toolbar::update()
49 void Toolbar::setLayout(string const & layout)
51 pimpl_->setLayout(layout);
55 bool Toolbar::updateLayoutList(int textclass)
57 // update the layout display
58 if (last_textclass_ != textclass) {
59 pimpl_->updateLayoutList(true);
60 last_textclass_ = textclass;
63 pimpl_->updateLayoutList(false);
69 void Toolbar::openLayoutList()
71 pimpl_->openLayoutList();
75 void Toolbar::clearLayoutList()
77 pimpl_->clearLayoutList();