From 458efa7b0c935cbaafa2791021a5f8f7241aa876 Mon Sep 17 00:00:00 2001 From: tpearson Date: Mon, 2 May 2011 22:38:52 +0000 Subject: Initial TQt4 port of Rosegarden This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/rosegarden@1230242 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/gui/editors/matrix/MatrixCanvasView.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/gui/editors/matrix/MatrixCanvasView.cpp') diff --git a/src/gui/editors/matrix/MatrixCanvasView.cpp b/src/gui/editors/matrix/MatrixCanvasView.cpp index f97ceaf..5782164 100644 --- a/src/gui/editors/matrix/MatrixCanvasView.cpp +++ b/src/gui/editors/matrix/MatrixCanvasView.cpp @@ -45,9 +45,9 @@ namespace Rosegarden MatrixCanvasView::MatrixCanvasView(MatrixStaff& staff, SnapGrid *snapGrid, bool drumMode, - TQCanvas *viewing, TQWidget *parent, + TQCanvas *viewing, TQWidget *tqparent, const char *name, WFlags f) - : RosegardenCanvasView(viewing, parent, name, f), + : RosegardenCanvasView(viewing, tqparent, name, f), m_staff(staff), m_snapGrid(snapGrid), m_drumMode(drumMode), @@ -55,7 +55,7 @@ MatrixCanvasView::MatrixCanvasView(MatrixStaff& staff, m_previousEvPitch(0), m_mouseWasPressed(false), m_ignoreClick(false), - m_smoothModifier(Qt::ShiftButton), + m_smoothModifier(TQt::ShiftButton), m_lastSnap(SnapGrid::SnapToBeat), m_isSnapTemporary(false) { @@ -130,7 +130,7 @@ void MatrixCanvasView::contentsMousePressEvent(TQMouseEvent* e) // TQCanvas::collisions() can be a bit optimistic and report // items which are close to the point but not actually under it. // So a little sanity check helps. - if (!rect.contains(p, true)) continue; + if (!rect.tqcontains(p, true)) continue; mel = &(mRect->getMatrixElement()); // std::cerr << "MatrixCanvasView::contentsMousePressEvent: collision with an existing matrix element" << std::endl; @@ -198,7 +198,7 @@ void MatrixCanvasView::contentsMouseMoveEvent(TQMouseEvent* e) QCanvasMatrixRectangle *mRect = 0; if ((mRect = dynamic_cast(item))) { - if (!mRect->rect().contains(p, true)) + if (!mRect->rect().tqcontains(p, true)) continue; mel = &(mRect->getMatrixElement()); MATRIX_DEBUG << "have element" << endl; @@ -268,7 +268,7 @@ void MatrixCanvasView::slotExternalWheelEvent(TQWheelEvent* e) void MatrixCanvasView::updateGridSnap(TQMouseEvent *e) { - Qt::ButtonState bs = e->state(); + TQt::ButtonState bs = e->state(); // MATRIX_DEBUG << "MatrixCanvasView::updateGridSnap : bs = " // << bs << " - sm = " << getSmoothModifier() << ", is temporary " << m_isSnapTemporary << ", saved is " << m_lastSnap << endl; -- cgit v1.2.1