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/notation/NotationCanvasView.cpp | 26 ++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'src/gui/editors/notation/NotationCanvasView.cpp') diff --git a/src/gui/editors/notation/NotationCanvasView.cpp b/src/gui/editors/notation/NotationCanvasView.cpp index fb7d2d9..40c2d59 100644 --- a/src/gui/editors/notation/NotationCanvasView.cpp +++ b/src/gui/editors/notation/NotationCanvasView.cpp @@ -49,9 +49,9 @@ namespace Rosegarden { NotationCanvasView::NotationCanvasView(const LinedStaffManager &staffmgr, - TQCanvas *viewing, TQWidget *parent, + TQCanvas *viewing, TQWidget *tqparent, const char *name, WFlags f) : - RosegardenCanvasView(viewing, parent, name, f), + RosegardenCanvasView(viewing, tqparent, name, f), m_linedStaffManager(staffmgr), m_lastYPosNearStaff(0), m_currentStaff(0), @@ -70,13 +70,13 @@ NotationCanvasView::NotationCanvasView(const LinedStaffManager &staffmgr, viewport()->setMouseTracking(true); - m_heightMarker = new QCanvasItemGroup(viewing); + m_heightMarker = new TQCanvasItemGroup(viewing); - m_vert1 = new QCanvasLineGroupable(viewing, m_heightMarker); + m_vert1 = new TQCanvasLineGroupable(viewing, m_heightMarker); m_vert1->setPoints(0, 0, 0, 8); m_vert1->setPen(TQPen(TQColor(64, 64, 64), 1)); - m_vert2 = new QCanvasLineGroupable(viewing, m_heightMarker); + m_vert2 = new TQCanvasLineGroupable(viewing, m_heightMarker); m_vert2->setPoints(17, 0, 17, 8); m_vert2->setPen(TQPen(TQColor(64, 64, 64), 1)); @@ -115,7 +115,7 @@ NotationCanvasView::contentsMouseMoveEvent(TQMouseEvent *e) if (!m_currentStaff) { - emit hoveredOverNoteChanged(TQString::null); + emit hoveredOverNoteChanged(TQString()); if (prevStaff) { m_heightMarker->hide(); canvas()->update(); @@ -191,10 +191,10 @@ void NotationCanvasView::contentsMousePressEvent(TQMouseEvent *e) return ; } - QCanvasNotationSprite *sprite = - dynamic_cast(*it); + TQCanvasNotationSprite *sprite = + dynamic_cast(*it); if (!sprite) { - if (dynamic_cast(*it)) { + if (dynamic_cast(*it)) { emit nonNotationItemPressed(e, *it); return ; } else if (dynamic_cast(*it)) { @@ -378,8 +378,8 @@ NotationCanvasView::setHeightMarkerHeight(TQMouseEvent *e) for (i = 0; i < legerLineCount; ++i) { - QCanvasLineGroupable *line = - new QCanvasLineGroupable(canvas(), m_heightMarker); + TQCanvasLineGroupable *line = + new TQCanvasLineGroupable(canvas(), m_heightMarker); line->setPen(TQPen(TQColor(64, 64, 64), 1)); @@ -411,14 +411,14 @@ NotationCanvasView::getElementAtXCoord(TQMouseEvent *e) // any old element TQCanvasItemList itemList = canvas()->collisions(threshold); TQCanvasItemList::Iterator it; - QCanvasNotationSprite* sprite = 0; + TQCanvasNotationSprite* sprite = 0; for (it = itemList.begin(); it != itemList.end(); ++it) { TQCanvasItem *item = *it; - if ((sprite = dynamic_cast(item))) { + if ((sprite = dynamic_cast(item))) { return & (sprite->getNotationElement()); } } -- cgit v1.2.1