author | hash <hash> | 2002-10-24 06:14:10 (UTC) |
---|---|---|
committer | hash <hash> | 2002-10-24 06:14:10 (UTC) |
commit | bdd884e37dc1ee1969d317b29e926768ea5a14df (patch) (side-by-side diff) | |
tree | 30353735e07c853be3c8458b413c4bf0d7bf58bc /noncore/apps/opie-console/mainwindow.cpp | |
parent | f09549e37fee6decd56168043209e8051b8757fb (diff) | |
download | opie-bdd884e37dc1ee1969d317b29e926768ea5a14df.zip opie-bdd884e37dc1ee1969d317b29e926768ea5a14df.tar.gz opie-bdd884e37dc1ee1969d317b29e926768ea5a14df.tar.bz2 |
still a work in progress
Diffstat (limited to 'noncore/apps/opie-console/mainwindow.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/mainwindow.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index c1020fa..8e529a3 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp @@ -205,23 +205,25 @@ void MainWindow::initUI() { m_keyBar = new QToolBar(this); addToolBar( m_keyBar, "Keyboard", QMainWindow::Top, TRUE ); m_keyBar->setHorizontalStretchable( TRUE ); m_keyBar->hide(); m_kb = new FunctionKeyboard(m_keyBar); - connect(m_kb, SIGNAL(keyPressed(ushort, ushort, bool, bool, bool, ushort, ushort)), - this, SLOT(slotKeyReceived(ushort, ushort, bool, bool, bool, ushort, ushort))); + connect(m_kb, SIGNAL(keyPressed(FKey, ushort, ushort, bool)), + this, SLOT(slotKeyReceived(FKey, ushort, ushort, bool))); m_buttonBar = new QToolBar( this ); addToolBar( m_buttonBar, "Buttons", QMainWindow::Top, TRUE ); m_buttonBar->setHorizontalStretchable( TRUE ); m_buttonBar->hide(); + /* m_qb = new QuickButton( m_buttonBar ); connect( m_qb, SIGNAL( keyPressed( ushort, ushort, bool, bool, bool) ), this, SLOT( slotKeyReceived( ushort, ushort, bool, bool, bool) ) ); + */ m_connect->setEnabled( false ); m_disconnect->setEnabled( false ); m_terminate->setEnabled( false ); m_transfer->setEnabled( false ); @@ -517,24 +519,22 @@ void MainWindow::slotFullscreen() { } m_isFullscreen = !m_isFullscreen; } -void MainWindow::slotKeyReceived(ushort u, ushort q, bool, bool pressed, bool, ushort, ushort) { - - //qWarning("unicode: %x, qkey: %x, %s", u, q, pressed ? "pressed" : "released"); +void MainWindow::slotKeyReceived(FKey k, ushort, ushort, bool pressed) { if ( m_curSession ) { QEvent::Type state; if (pressed) state = QEvent::KeyPress; else state = QEvent::KeyRelease; - QKeyEvent ke(state, q, u, 0, QString(QChar(u))); + QKeyEvent ke(state, k.qcode, k.unicode, 0, QString(QChar(k.unicode))); // where should i send this event? doesnt work sending it here QApplication::sendEvent((QObject *)m_curSession->widget(), &ke); ke.ignore(); } } |