diff options
author | Michael Lauer <mickey@vanille-media.de> | 2005-07-08 05:30:44 +0000 |
---|---|---|
committer | OpenEmbedded Project <openembedded-devel@lists.openembedded.org> | 2005-07-08 05:30:44 +0000 |
commit | 7d816d1cf57d263d52bb1990de7338165b65fd37 (patch) | |
tree | 23496c17f866943f25ed6f0408dc7c72203b95e2 /packages/qte/qte-2.3.10/suspend-resume-hooks.patch | |
parent | 38179267815bc8f09779dd797dd8285239c9046c (diff) |
Qt-Embedded 2.3.10 patches courtesy Manuel Teira:
- add suspend-resume hook for qws server
- implement suspend-resume helpers in W100 driver
Diffstat (limited to 'packages/qte/qte-2.3.10/suspend-resume-hooks.patch')
-rw-r--r-- | packages/qte/qte-2.3.10/suspend-resume-hooks.patch | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/packages/qte/qte-2.3.10/suspend-resume-hooks.patch b/packages/qte/qte-2.3.10/suspend-resume-hooks.patch new file mode 100644 index 0000000000..34e6ba2133 --- /dev/null +++ b/packages/qte/qte-2.3.10/suspend-resume-hooks.patch @@ -0,0 +1,64 @@ +Suspend/Resume hooks for QScreen and usage from QApplication +Manuel Teira <manuel.teira@telefonica.net> + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- qt-2.3.10/src/kernel/qgfx_qws.h~suspend-resume-hooks ++++ qt-2.3.10/src/kernel/qgfx_qws.h +@@ -192,6 +192,8 @@ + virtual int pixmapLinestepAlignment() { return 64; } + + virtual void sync() {} ++ virtual void prepareToSuspend() {} ++ virtual void prepareToResume() {} + virtual bool onCard(unsigned char *) const; + virtual bool onCard(unsigned char *, ulong& out_offset) const; + +--- qt-2.3.10/src/kernel/qapplication_qws.cpp~suspend-resume-hooks ++++ qt-2.3.10/src/kernel/qapplication_qws.cpp +@@ -480,6 +480,7 @@ + int region_offset_window; + #ifndef QT_NO_COP + QWSQCopMessageEvent *qcop_response; ++ bool manageAPMMessage( QWSQCopMessageEvent *e ); + #endif + QWSEvent* current_event; + QValueList<int> unused_identifiers; +@@ -840,7 +841,7 @@ + QWSQCopMessageEvent *pe = (QWSQCopMessageEvent*)e; + if ( pe->simpleData.is_response ) { + qcop_response = pe; +- } else { ++ } else if ( !manageAPMMessage( pe ) ) { + queue.append(e); + } + #endif +@@ -851,6 +852,26 @@ + } + } + ++#ifndef QT_NO_COP ++bool QWSDisplayData::manageAPMMessage( QWSQCopMessageEvent *e ) ++{ ++ if ( e->channel.data() != QCString( "QPE/System" ) ) { ++ return FALSE; ++ } ++ if ( e->message.data() == QCString( "aboutToSuspend()" ) ) { ++ if ( qt_screen ) qt_screen->prepareToSuspend(); ++ delete e; ++ return TRUE; ++ } ++ if ( e->message.data() == QCString( "returnFromSuspend()" ) ) { ++ if ( qt_screen ) qt_screen->prepareToResume(); ++ delete e; ++ return TRUE; ++ } ++ return FALSE; ++} ++#endif ++ + void QWSDisplayData::offsetPendingExpose( int window, const QPoint &offset ) + { + if ( offset.isNull() ) |