implement openLayoutList

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4738 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
John Levon 2002-07-21 23:08:30 +00:00
parent 313ab401fe
commit 4ef66c42fc
4 changed files with 16 additions and 7 deletions

View File

@ -1,3 +1,8 @@
2002-07-22 John Levon <moz@compsoc.man.ac.uk>
* Toolbar_pimpl.h:
* Toolbar_pimpl.C: implement getLayoutList()
2002-07-21 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
* Toolbar_pimpl.C: use BufferParams::getLyXTextClass

View File

@ -124,6 +124,5 @@ QtView
Toolbar_pimpl
- mathed symbols (*)
- openLayoutList() (remove ?)
- ::set() ???
- set() ??
- push() ??

View File

@ -84,6 +84,13 @@ QPixmap getIconPixmap(int action)
} // namespace anon
class QLComboBox : public QComboBox {
public:
QLComboBox(QWidget * parent) : QComboBox(parent) {}
void popup() { QComboBox::popup(); }
};
Toolbar::Pimpl::Pimpl(LyXView * o, Dialogs &, int, int)
: owner_(static_cast<QtView *>(o)),
combo_(0)
@ -213,9 +220,7 @@ void Toolbar::Pimpl::clearLayoutList()
void Toolbar::Pimpl::openLayoutList()
{
#if 0 // popup() is protected
combo_->popup();
#endif
}
@ -239,7 +244,7 @@ void Toolbar::Pimpl::add(int action, bool)
toolbars_.push_back(new QToolBar(owner_));
break;
case ToolbarDefaults::LAYOUTS: {
combo_ = new QComboBox(toolbars_.back());
combo_ = new QLComboBox(toolbars_.back());
QSizePolicy p(QSizePolicy::Minimum, QSizePolicy::Fixed);
combo_->setSizePolicy(p);
combo_->setFocusPolicy(QWidget::TabFocus);

View File

@ -28,7 +28,7 @@
class QtView;
class QToolBar;
class QComboBox;
class QLComboBox;
class ToolbarProxy;
struct Toolbar::Pimpl {
@ -77,7 +77,7 @@ private:
std::vector<QToolBar *> toolbars_;
QComboBox * combo_;
QLComboBox * combo_;
typedef std::map<QToolButton *, int> ButtonMap;