author | leseb <leseb> | 2002-07-10 21:59:27 (UTC) |
---|---|---|
committer | leseb <leseb> | 2002-07-10 21:59:27 (UTC) |
commit | f568737c20bea96fb79d85681a72e142ec05d66f (patch) (side-by-side diff) | |
tree | 80d08b351bbdeec5be93885a4c18ba0207ef990a /noncore/graphics/drawpad/shapetool.cpp | |
parent | 01b04adb73c8bc49938b71a4bebe6fb6a5477f75 (diff) | |
download | opie-f568737c20bea96fb79d85681a72e142ec05d66f.zip opie-f568737c20bea96fb79d85681a72e142ec05d66f.tar.gz opie-f568737c20bea96fb79d85681a72e142ec05d66f.tar.bz2 |
Undo/redo reimplemented
Diffstat (limited to 'noncore/graphics/drawpad/shapetool.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/graphics/drawpad/shapetool.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/noncore/graphics/drawpad/shapetool.cpp b/noncore/graphics/drawpad/shapetool.cpp index 8870a78..22e3dd6 100644 --- a/noncore/graphics/drawpad/shapetool.cpp +++ b/noncore/graphics/drawpad/shapetool.cpp @@ -34,2 +34,4 @@ void ShapeTool::mousePressEvent(QMouseEvent* e) { + m_pDrawPadCanvas->backupPage(); + m_mousePressed = true; @@ -43,3 +45,3 @@ void ShapeTool::mouseReleaseEvent(QMouseEvent* e) QPainter painter; - painter.begin(m_pDrawPadCanvas->currentPage()); + painter.begin(m_pDrawPadCanvas->currentPage()->pixmap()); drawFinalShape(painter); @@ -58,3 +60,3 @@ void ShapeTool::mouseReleaseEvent(QMouseEvent* e) bitBlt(m_pDrawPadCanvas->viewport(), viewportRect.x(), viewportRect.y(), - m_pDrawPadCanvas->currentPage(), r.x(), r.y(), r.width(), r.height()); + m_pDrawPadCanvas->currentPage()->pixmap(), r.x(), r.y(), r.width(), r.height()); @@ -63,4 +65,2 @@ void ShapeTool::mouseReleaseEvent(QMouseEvent* e) m_mousePressed = false; - - m_pDrawPadCanvas->backupPage(); } @@ -72,3 +72,3 @@ void ShapeTool::mouseMoveEvent(QMouseEvent* e) QPainter painter; - painter.begin(m_pDrawPadCanvas->currentPage()); + painter.begin(m_pDrawPadCanvas->currentPage()->pixmap()); drawTemporaryShape(painter); @@ -87,3 +87,3 @@ void ShapeTool::mouseMoveEvent(QMouseEvent* e) bitBlt(m_pDrawPadCanvas->viewport(), viewportRect.x(), viewportRect.y(), - m_pDrawPadCanvas->currentPage(), r.x(), r.y(), r.width(), r.height()); + m_pDrawPadCanvas->currentPage()->pixmap(), r.x(), r.y(), r.width(), r.height()); |