author | zecke <zecke> | 2003-02-25 20:51:11 (UTC) |
---|---|---|
committer | zecke <zecke> | 2003-02-25 20:51:11 (UTC) |
commit | e6b5b28a59f5b2bf1812f5d84203f42a7d5d6916 (patch) (unidiff) | |
tree | bb6a4d52de61e1ae871ad10a302c1b140d079bb7 | |
parent | 2971a56b1e30af0e1604d898e5a56c6f81f2daf0 (diff) | |
download | opie-e6b5b28a59f5b2bf1812f5d84203f42a7d5d6916.zip opie-e6b5b28a59f5b2bf1812f5d84203f42a7d5d6916.tar.gz opie-e6b5b28a59f5b2bf1812f5d84203f42a7d5d6916.tar.bz2 |
Honor the clicking of the (X)-Button
-rw-r--r-- | core/obex/obexsend.cpp | 4 | ||||
-rw-r--r-- | core/obex/obexsend.h | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/core/obex/obexsend.cpp b/core/obex/obexsend.cpp index 0da57ca..1b19c6b 100644 --- a/core/obex/obexsend.cpp +++ b/core/obex/obexsend.cpp | |||
@@ -163,12 +163,16 @@ void SendWidget::slotStartIrda() { | |||
163 | m_irDeSearch = m_devBox->addDevice(tr("Search again for IrDa."), DeviceBox::Search ); | 163 | m_irDeSearch = m_devBox->addDevice(tr("Search again for IrDa."), DeviceBox::Search ); |
164 | return; | 164 | return; |
165 | } | 165 | } |
166 | m_devBox->setStatus( m_irDaIt.key(), tr("Start sending") ); | 166 | m_devBox->setStatus( m_irDaIt.key(), tr("Start sending") ); |
167 | m_obex->send( m_file ); | 167 | m_obex->send( m_file ); |
168 | } | 168 | } |
169 | void SendWidget::closeEvent( QCloseEvent* e) { | ||
170 | e->accept(); // make sure | ||
171 | QTimer::singleShot(0, this, SLOT(slotDone() ) ); | ||
172 | } | ||
169 | void SendWidget::slotDone() { | 173 | void SendWidget::slotDone() { |
170 | QCopEnvelope e0("QPE/IrDaApplet", "disableIrda()"); | 174 | QCopEnvelope e0("QPE/IrDaApplet", "disableIrda()"); |
171 | QCopEnvelope e1("QPE/Bluetooth", "disableBluetooth()"); | 175 | QCopEnvelope e1("QPE/Bluetooth", "disableBluetooth()"); |
172 | emit done(); | 176 | emit done(); |
173 | } | 177 | } |
174 | QString SendWidget::file()const { | 178 | QString SendWidget::file()const { |
diff --git a/core/obex/obexsend.h b/core/obex/obexsend.h index 02100f7..bf901cb 100644 --- a/core/obex/obexsend.h +++ b/core/obex/obexsend.h | |||
@@ -36,12 +36,15 @@ namespace OpieObex { | |||
36 | public: | 36 | public: |
37 | SendWidget( QWidget* parent = 0, const char* name = 0); | 37 | SendWidget( QWidget* parent = 0, const char* name = 0); |
38 | ~SendWidget(); | 38 | ~SendWidget(); |
39 | 39 | ||
40 | QString file()const; | 40 | QString file()const; |
41 | 41 | ||
42 | protected: | ||
43 | void closeEvent( QCloseEvent* ); | ||
44 | |||
42 | public slots: | 45 | public slots: |
43 | void send( const QString& file, const QString& desc ); | 46 | void send( const QString& file, const QString& desc ); |
44 | 47 | ||
45 | signals: | 48 | signals: |
46 | void done(); | 49 | void done(); |
47 | 50 | ||