]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/QCommandBuffer.C
enable Font cache only for MacOSX and inline width() for other platform.
[lyx.git] / src / frontends / qt4 / QCommandBuffer.C
index aea7f31a5c81728be272a45a1c7ac86225c8c3a5..7081e0820e1e3b9766aefa9539bd700a3219cdeb 100644 (file)
@@ -12,7 +12,7 @@
 
 // Qt defines a macro 'signals' that clashes with a boost namespace.
 // All is well if the namespace is visible first.
-#include "QtView.h"
+#include "GuiView.h"
 
 #include "QCommandBuffer.h"
 #include "QCommandEdit.h"
@@ -58,7 +58,8 @@ protected:
                    || e->x() > width() || e->y() > height()) {
                        hide();
                } else {
-                       emit itemPressed(currentItem());
+                        // emit signal
+                       itemPressed(currentItem());
                }
        }
 
@@ -74,7 +75,7 @@ protected:
 } // end of anon
 
 
-QCommandBuffer::QCommandBuffer(QtView * view, ControlCommandBuffer & control, QWidget * parent)
+QCommandBuffer::QCommandBuffer(GuiView * view, ControlCommandBuffer & control, QWidget * parent)
        : QWidget(parent), view_(view), controller_(control)
 {
        QPixmap qpup(toqstr(libFileSearch("images", "up", "xpm")));
@@ -84,10 +85,10 @@ QCommandBuffer::QCommandBuffer(QtView * view, ControlCommandBuffer & control, QW
        QHBoxLayout * layout = new QHBoxLayout(0);
 
        QPushButton * up = new QPushButton(qpup, "", this);
-       QToolTip::add(up, qt_("Previous command"));
+       up->setToolTip(qt_("Previous command"));
        connect(up, SIGNAL(clicked()), this, SLOT(up()));
        QPushButton * down = new QPushButton(qpdown, "", this);
-       QToolTip::add(down, qt_("Next command"));
+       down->setToolTip(qt_("Next command"));
        connect(down, SIGNAL(clicked()), this, SLOT(down()));
 
        edit_ = new QCommandEdit(this);
@@ -232,3 +233,5 @@ void XMiniBuffer::suffix_timeout()
 
 } // namespace frontend
 } // namespace lyx
+
+#include "QCommandBuffer_moc.cpp"