Diffstat (limited to 'inputmethods/multikey/keyboard.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | inputmethods/multikey/keyboard.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/inputmethods/multikey/keyboard.cpp b/inputmethods/multikey/keyboard.cpp index 1dd8ca1..de3aa52 100644 --- a/inputmethods/multikey/keyboard.cpp +++ b/inputmethods/multikey/keyboard.cpp @@ -98,5 +98,5 @@ void Keyboard::resizeEvent(QResizeEvent*) int ph = picks->sizeHint().height(); picks->setGeometry( 0, 0, width(), ph ); - keyHeight = (height()-(usePicks ? ph : 0))/keys->rows(); + keyHeight = (height()-(usePicks ? ph : 0))/(keys->rows()?keys->rows():1); int nk; // number of keys? @@ -1322,4 +1322,7 @@ Keys::Keys() { } + if (map.isNull() || !(QFile(map).exists())) { + map = QPEApplication::qpeDir() + "/share/multikey/en.keymap"; + } setKeysFromFile(map); |