author | josef <josef> | 2002-10-13 15:52:00 (UTC) |
---|---|---|
committer | josef <josef> | 2002-10-13 15:52:00 (UTC) |
commit | cb816d85c54242f8958ff77fba334b43be0dcb3d (patch) (unidiff) | |
tree | 6764b80acf8789c410cdc59cb308f3f91fcd9083 /noncore/apps/opie-console/io_modem.cpp | |
parent | 6a9726437a59cf3b18bf57d6e20fb2dfaaa2fc34 (diff) | |
download | opie-cb816d85c54242f8958ff77fba334b43be0dcb3d.zip opie-cb816d85c54242f8958ff77fba334b43be0dcb3d.tar.gz opie-cb816d85c54242f8958ff77fba334b43be0dcb3d.tar.bz2 |
- make dialer accessible transparently when opening a modem session
- implement sending data (currently written to stdout for debug purpose)
Diffstat (limited to 'noncore/apps/opie-console/io_modem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/io_modem.cpp | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/noncore/apps/opie-console/io_modem.cpp b/noncore/apps/opie-console/io_modem.cpp index 4d6035d..41febfb 100644 --- a/noncore/apps/opie-console/io_modem.cpp +++ b/noncore/apps/opie-console/io_modem.cpp | |||
@@ -1,11 +1,13 @@ | |||
1 | 1 | ||
2 | #include "io_modem.h" | 2 | #include "io_modem.h" |
3 | 3 | ||
4 | IOModem:IOModem( const Profile &config ) : IOSerial( config ) { | 4 | #include "dialer.h" |
5 | 5 | ||
6 | IOModem:IOModem( const Profile &config ) : IOSerial( config ) { | ||
7 | m_config = config; | ||
6 | } | 8 | } |
7 | 9 | ||
8 | 10 | ||
9 | IOModem::~IOModem() { | 11 | IOModem::~IOModem() { |
10 | 12 | ||
11 | } | 13 | } |
@@ -15,16 +17,21 @@ void IOModem::close() { | |||
15 | 17 | ||
16 | IOSerial::close(); | 18 | IOSerial::close(); |
17 | 19 | ||
18 | } | 20 | } |
19 | 21 | ||
20 | bool IOModem::open() { | 22 | bool IOModem::open() { |
21 | |||
22 | |||
23 | IOSerial::open(); | 23 | IOSerial::open(); |
24 | 24 | ||
25 | Dialer d(m_profile); | ||
26 | int result = d.exec(); | ||
27 | if(result == QDialog::Accepted) | ||
28 | { | ||
29 | return true; | ||
30 | } | ||
31 | else return false; | ||
25 | } | 32 | } |
26 | 33 | ||
27 | void IOModem::reload( const Profile &config ) { | 34 | void IOModem::reload( const Profile &config ) { |
28 | m_device = config.readEntry("Device", MODEM_DEFAULT_DEVICE); | 35 | m_device = config.readEntry("Device", MODEM_DEFAULT_DEVICE); |
29 | m_baud = config.readNumEntry("Baud", MODEM_DEFAULT_BAUD); | 36 | m_baud = config.readNumEntry("Baud", MODEM_DEFAULT_BAUD); |
30 | m_parity = config.readNumEntry("Parity", MODEM_DEFAULT_PARITY); | 37 | m_parity = config.readNumEntry("Parity", MODEM_DEFAULT_PARITY); |