author | zecke <zecke> | 2004-04-08 00:42:01 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-04-08 00:42:01 (UTC) |
commit | 5afca2540a2d6bf733c89ea97748496a679bc576 (patch) (unidiff) | |
tree | 3e4e419ccc0e1b1cb71cc2cf7e75d36f9301de81 /noncore/graphics/drawpad/drawpad.cpp | |
parent | 8c54ad421c7bee65b2a1442ce85c09f2eff3efc6 (diff) | |
download | opie-5afca2540a2d6bf733c89ea97748496a679bc576.zip opie-5afca2540a2d6bf733c89ea97748496a679bc576.tar.gz opie-5afca2540a2d6bf733c89ea97748496a679bc576.tar.bz2 |
Import a QPixmap via QCOP
Diffstat (limited to 'noncore/graphics/drawpad/drawpad.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/graphics/drawpad/drawpad.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/noncore/graphics/drawpad/drawpad.cpp b/noncore/graphics/drawpad/drawpad.cpp index 3331193..d9d0ce0 100644 --- a/noncore/graphics/drawpad/drawpad.cpp +++ b/noncore/graphics/drawpad/drawpad.cpp | |||
@@ -54,6 +54,8 @@ DrawPad::DrawPad(QWidget* parent, const char* name, WFlags /*fl*/ ) | |||
54 | : QMainWindow(parent, name, WStyle_ContextHelp) | 54 | : QMainWindow(parent, name, WStyle_ContextHelp) |
55 | { | 55 | { |
56 | // init members | 56 | // init members |
57 | connect( qApp, SIGNAL(appMessage(const QCString&, const QByteArray&)), | ||
58 | this, SLOT(slotAppMessage(const QCString&, const QByteArray&)) ); | ||
57 | 59 | ||
58 | m_pDrawPadCanvas = new DrawPadCanvas(this, this); | 60 | m_pDrawPadCanvas = new DrawPadCanvas(this, this); |
59 | 61 | ||
@@ -663,3 +665,20 @@ void DrawPad::saveConfig() | |||
663 | config.writeEntry("PenColor", m_pen.color().name()); | 665 | config.writeEntry("PenColor", m_pen.color().name()); |
664 | config.writeEntry("BrushColor", m_brush.color().name()); | 666 | config.writeEntry("BrushColor", m_brush.color().name()); |
665 | } | 667 | } |
668 | |||
669 | |||
670 | /* | ||
671 | * Import a Thumbnail from SCAP or similiar | ||
672 | */ | ||
673 | void DrawPad::slotAppMessage( const QCString& str, const QByteArray& ar ) { | ||
674 | QDataStream stream(ar, IO_ReadOnly ); | ||
675 | /* | ||
676 | * import the pixmap | ||
677 | */ | ||
678 | if ( str == "importPixmap(QPixmap)" ) { | ||
679 | QPixmap pix; | ||
680 | stream >> pix;; | ||
681 | m_pDrawPadCanvas->importPixmap( pix ); | ||
682 | QPEApplication::setKeepRunning(); | ||
683 | } | ||
684 | } | ||