mirror of
git://projects.qi-hardware.com/openwrt-packages.git
synced 2024-12-22 14:10:48 +02:00
qball: make Enter key work and change fonts
This commit is contained in:
parent
2975657fa1
commit
9da19d44ec
24
qball/patches/001-convenience.patch
Normal file
24
qball/patches/001-convenience.patch
Normal file
@ -0,0 +1,24 @@
|
||||
--- QBall-1.2.orig/QBall/mainwindow.cpp 2011-01-05 01:58:24.000000000 +0300
|
||||
+++ QBall/mainwindow.cpp 2011-02-02 17:18:47.000000000 +0300
|
||||
@@ -274,7 +274,7 @@
|
||||
itemScore->setZValue(1.0);
|
||||
QFont font = itemScore->font();
|
||||
qDebug("font size: %d", font.pointSize());
|
||||
- font.setPointSize(8);
|
||||
+ font.setPointSize(20);
|
||||
itemScore->setFont(font);
|
||||
itemScore->setPos(16, 16);
|
||||
itemScore->setDefaultTextColor(Qt::yellow);
|
||||
@@ -1172,6 +1172,12 @@
|
||||
else if( event->key() == Qt::Key_P ) {
|
||||
gamestate->userPause();
|
||||
}
|
||||
+ else if( event->key() == Qt::Key_Return ) {
|
||||
+ QPushButton *button = qobject_cast< QPushButton* >(qApp->focusWidget());
|
||||
+ if (button) {
|
||||
+ button->click();
|
||||
+ }
|
||||
+ }
|
||||
else {
|
||||
QMainWindow::keyPressEvent(event);
|
||||
}
|
Loading…
Reference in New Issue
Block a user