Index: qtnx-0.9/qtnxwindow.cpp
===================================================================
--- qtnx-0.9.orig/qtnxwindow.cpp 2008-10-13 14:35:29.000000000 +0200
+++ qtnx-0.9/qtnxwindow.cpp 2008-10-13 14:35:33.000000000 +0200
@@ -315,8 +315,8 @@
session.imageCompressionMethod = config.imageCompressionMethod;
session.imageCompressionLevel = config.imageCompressionLevel;
session.geometry = config.geometry;
- session.keyboard = "defkeymap";
- session.kbtype = "pc102/defkeymap";
+ session.keyboard = config.keyboard;
+ session.kbtype = config.kbtype;
session.media = config.media;
session.agentServer = config.agentServer;
session.agentUser = config.agentUser;
Index: qtnx-0.9/settingsdialog.ui
===================================================================
--- qtnx-0.9.orig/settingsdialog.ui 2008-10-13 14:35:32.000000000 +0200
+++ qtnx-0.9/settingsdialog.ui 2008-10-13 14:35:33.000000000 +0200
@@ -43,14 +43,6 @@
0
-
-
- 0
- 0
- 436
- 439
-
-
Basic
@@ -598,47 +590,31 @@
-
-
- 0
- 0
- 624
- 496
-
-
Advanced
-
-
- 6
-
-
- 9
-
+
-
Network
-
-
- 6
+
+
+
+ 11
+ 28
+ 396
+ 22
+
-
- 9
+
+ Use SSH Tunneling
-
-
-
-
- Use SSH Tunneling
-
-
- true
-
-
-
-
+
+ true
+
+
-
@@ -727,6 +703,108 @@
-
+
+
+ Keyboard
+
+
+
-
+
+
+ 6
+
+
+ 0
+
+
-
+
+
+
+ 0
+ 0
+
+
+
+ Type:
+
+
+
+ -
+
+
-
+
+ Standard
+
+
+ -
+
+ Nokia N810
+
+
+
+
+
+
+ -
+
+
+ 6
+
+
+ 0
+
+
-
+
+
+ true
+
+
+
+ 0
+ 0
+
+
+
+ Language:
+
+
+
+ -
+
+
+ false
+
+
-
+
+ de
+
+
+ -
+
+ us
+
+
+
+
+
+
+ -
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+
+
+
+ -
Qt::Vertical
Index: qtnx-0.9/qtnxsettings.cpp
===================================================================
--- qtnx-0.9.orig/qtnxsettings.cpp 2008-10-13 14:07:34.000000000 +0200
+++ qtnx-0.9/qtnxsettings.cpp 2008-10-13 14:36:44.000000000 +0200
@@ -43,6 +43,7 @@
connect(ui_sd.resolution, SIGNAL(currentIndexChanged(QString)), this, SLOT(resolutionChanged(QString)));
connect(ui_sd.imageCompressionType, SIGNAL(currentIndexChanged(QString)), this, SLOT(compressionChanged(QString)));
+ connect(ui_sd.keyboard, SIGNAL(currentIndexChanged(QString)), this, SLOT(keyboardChanged(QString)));
connect(ui_sd.defaultKey, SIGNAL(stateChanged(int)), this, SLOT(keyChanged(int)));
connect(ui_sd.applyButton, SIGNAL(pressed()), this, SLOT(applyPressed()));
connect(ui_sd.okButton, SIGNAL(pressed()), this, SLOT(okPressed()));
@@ -78,6 +79,16 @@
ui_sd.setAuthKeyButton->setEnabled(true);
}
+ if (config.keyboard == "defkeymap")
+ {
+ ui_sd.keyboard->setCurrentIndex(ui_sd.keyboard->findText(tr("Standard")));
+ } else if (QString(config.keyboard.data()).contains("nokiarx44"))
+ {
+ ui_sd.keyboard->setCurrentIndex(ui_sd.keyboard->findText(tr("Nokia N810")));
+ ui_sd.language->setCurrentIndex(ui_sd.language->findText(QString(config.keyboard.data()).right(2)));
+ ui_sd.language->setEnabled(true);
+ }
+
if (config.sessionType == "unix-kde") {
ui_sd.platform->setCurrentIndex(ui_sd.platform->findText(tr("UNIX")));
ui_sd.type->setCurrentIndex(ui_sd.type->findText(tr("KDE")));
@@ -162,6 +173,15 @@
}
}
+void QtNXSettings::keyboardChanged(QString text)
+{
+ if (text == tr("Nokia N810")) {
+ ui_sd.language->setEnabled(true);
+ } else {
+ ui_sd.language->setEnabled(false);
+ }
+}
+
void QtNXSettings::platformChanged(QString text)
{
}
@@ -230,8 +250,17 @@
config.serverPort = ui_sd.port->value();
// TODO: Add keyboard selection support
- config.keyboard = "defkeymap";
- config.kbtype = "pc102/defkeymap";
+
+ if (ui_sd.keyboard->currentText() == tr("Standard"))
+ {
+ config.keyboard = "defkeymap";
+ config.kbtype = "pc102/defkeymap";
+ } else if (ui_sd.keyboard->currentText() == tr("Nokia N810"))
+ {
+ config.keyboard =
+ "nokiarx44/" + ui_sd.language->currentText().toStdString();
+ config.kbtype = config.keyboard;
+ }
if (ui_sd.platform->currentText() == tr("UNIX")) {
if (ui_sd.type->currentText() == tr("KDE"))
Index: qtnx-0.9/qtnxsettings.h
===================================================================
--- qtnx-0.9.orig/qtnxsettings.h 2008-10-13 14:07:34.000000000 +0200
+++ qtnx-0.9/qtnxsettings.h 2008-10-13 14:35:33.000000000 +0200
@@ -38,6 +38,7 @@
void resolutionChanged(QString);
void compressionChanged(QString);
void platformChanged(QString);
+ void keyboardChanged(QString);
void typeChanged(QString);
void keyChanged(int);
void applyPressed();