summaryrefslogtreecommitdiff
path: root/qt
authorsandman <sandman>2002-08-30 02:50:56 (UTC)
committer sandman <sandman>2002-08-30 02:50:56 (UTC)
commit57e4c1b05208650eaac76268eb9bb25a1caa2184 (patch) (side-by-side diff)
tree6389ea3b2799dbbb731d1780102568642129e335 /qt
parentc4af3c78c9f6f073c1e0b11b331a2e24df80b9ff (diff)
downloadopie-57e4c1b05208650eaac76268eb9bb25a1caa2184.zip
opie-57e4c1b05208650eaac76268eb9bb25a1caa2184.tar.gz
opie-57e4c1b05208650eaac76268eb9bb25a1caa2184.tar.bz2
New/ported patches for Qt/E 2.3.3
Diffstat (limited to 'qt') (more/less context) (show whitespace changes)
-rw-r--r--qt/qte233-for-opie091-display.patch15
-rw-r--r--qt/qte233-for-opie091-keyboard.patch145
-rw-r--r--qt/qte233-for-opie091-style.patch11
-rw-r--r--qt/qte233-for-opie091-unpolish.patch23
4 files changed, 194 insertions, 0 deletions
diff --git a/qt/qte233-for-opie091-display.patch b/qt/qte233-for-opie091-display.patch
new file mode 100644
index 0000000..d5b97e8
--- a/dev/null
+++ b/qt/qte233-for-opie091-display.patch
@@ -0,0 +1,15 @@
+--- src.orig/kernel/qapplication_qws.cpp Mon Mar 18 02:11:25 2002
++++ src/kernel/qapplication_qws.cpp Fri Aug 30 04:48:23 2002
+@@ -1458,11 +1458,7 @@
+ qt_appType = type;
+ qws_single_process = TRUE;
+ QWSServer::startup(flags);
+- QString strEnv( "QWS_DISPLAY=" );
+- strEnv += qws_display_spec;
+- char p[strEnv.length() + 1];
+- strncpy( p, strEnv.latin1(), strEnv.length() );
+- putenv( p );
++ setenv( "QWS_DISPLAY", qws_display_spec, 1 );
+ }
+
+ if( qt_is_gui_used )
diff --git a/qt/qte233-for-opie091-keyboard.patch b/qt/qte233-for-opie091-keyboard.patch
new file mode 100644
index 0000000..9d76a64
--- a/dev/null
+++ b/qt/qte233-for-opie091-keyboard.patch
@@ -0,0 +1,145 @@
+--- src.orig/kernel/qkeyboard_qws.cpp Mon Mar 18 02:11:25 2002
++++ src/kernel/qkeyboard_qws.cpp Fri Aug 30 04:28:39 2002
+@@ -269,7 +269,7 @@
+ { Qt::Key_O, 'o' , 'O' , 'O'-64 },
+ { Qt::Key_P, 'p' , 'P' , 'P'-64 },
+ { Qt::Key_BraceLeft, '[' , '{' , 0xffff },
+- { Qt::Key_Escape, ']' , '}' , 0xffff },
++ { Qt::Key_BraceRight, ']' , '}' , 0xffff },
+ { Qt::Key_Return, 13 , 13 , 0xffff },
+ { Qt::Key_Control, 0xffff , 0xffff , 0xffff },
+ { Qt::Key_A, 'a' , 'A' , 'A'-64 }, // 30
+@@ -394,7 +394,7 @@
+ bool numLock;
+ #endif
+ bool caps;
+- bool extended;
++ int extended;
+ int modifiers;
+ int prevuni;
+ int prevkey;
+@@ -524,7 +524,7 @@
+ shift = false;
+ alt = false;
+ ctrl = false;
+- extended = false;
++ extended = 0;
+ prevuni = 0;
+ prevkey = 0;
+ caps = FALSE;
+@@ -561,10 +561,24 @@
+ int keyCode = Qt::Key_unknown;
+ bool release = false;
+ int keypad = 0;
++#if defined(QT_QWS_IPAQ)
++ static int ipaq_return_pressed = false; // iPAQ Action Key has ScanCode 0x60: 0x60|0x80 = 0xe0 == extended mode 1 !
++#endif
++
+ #if !defined(QT_QWS_CUSTOM)
+- if (code == 224) {
++ if ((code == 224)
++#if defined(QT_QWS_IPAQ)
++ && !ipaq_return_pressed
++#endif
++ )
++ {
+ // extended
+- extended = true;
++ extended = 1;
++ return;
++ }
++ else if (code == 225) {
++ // extended 2
++ extended = 2;
+ return;
+ }
+ #endif
+@@ -574,7 +588,7 @@
+ code &= 0x7f;
+ }
+
+- if (extended) {
++ if (extended == 1) {
+ switch (code) {
+ case 72:
+ keyCode = Qt::Key_Up;
+@@ -612,6 +626,32 @@
+ case 53:
+ keyCode = Qt::Key_Slash;
+ break;
++ case 0x1d:
++ keyCode = Qt::Key_Control;
++ break;
++ case 0x2a:
++ keyCode = Qt::Key_SysReq;
++ break;
++ case 0x38:
++ keyCode = Qt::Key_Alt;
++ break;
++ case 0x5b:
++ keyCode = Qt::Key_Super_L;
++ break;
++ case 0x5c:
++ keyCode = Qt::Key_Super_R;
++ break;
++ case 0x5d:
++ keyCode = Qt::Key_Menu;
++ break;
++ }
++ } else if (extended == 2) {
++ switch (code) {
++ case 0x1d:
++ return;
++ case 0x45:
++ keyCode = Qt::Key_Pause;
++ break;
+ }
+ } else {
+ #if defined(QT_QWS_CUSTOM)
+@@ -650,6 +690,7 @@
+ repeatable = FALSE;
+ break;
+ case 0x60:
++ ipaq_return_pressed = !release;
+ keyCode = Key_Return;
+ break;
+ case 0x67:
+@@ -687,13 +728,19 @@
+ else
+ repeater->stop();
+ #endif
++
++ /*
++ Translate shift+Key_Tab to Key_Backtab
++ */
++ if (( keyCode == Key_Tab ) && shift )
++ keyCode = Key_Backtab;
+ }
+
+ /*
+ Keypad consists of extended keys 53 and 28,
+ and non-extended keys 55 and 71 through 83.
+ */
+- if ( extended ? (code == 53 || code == 28) :
++ if ((extended == 1) ? (code == 53 || code == 28) :
+ (code == 55 || ( code >= 71 && code <= 83 )) )
+ keypad = Qt::Keypad;
+
+@@ -803,7 +850,7 @@
+ unicode = QWSServer::keyMap()[code].shift_unicode ? QWSServer::keyMap()[code].shift_unicode : 0xffff;
+ else
+ unicode = QWSServer::keyMap()[code].unicode ? QWSServer::keyMap()[code].unicode : 0xffff;
+- } else {
++ } else if (extended == 1) {
+ if ( code == 53 )
+ unicode = '/';
+ }
+@@ -829,7 +876,7 @@
+ prevkey = prevuni = 0;
+ }
+ }
+- extended = false;
++ extended = 0;
+ }
+
+
diff --git a/qt/qte233-for-opie091-style.patch b/qt/qte233-for-opie091-style.patch
new file mode 100644
index 0000000..1944da8
--- a/dev/null
+++ b/qt/qte233-for-opie091-style.patch
@@ -0,0 +1,11 @@
+--- src.orig/widgets/qcommonstyle.cpp Mon Mar 18 02:11:26 2002
++++ src/widgets/qcommonstyle.cpp Fri Aug 30 04:28:27 2002
+@@ -562,7 +562,7 @@
+ bool enabled, bool active )
+ {
+ #ifndef QT_NO_MENUBAR
+-#ifndef QT_NO_STYLE_SGI
++#if 1 // #ifndef QT_NO_STYLE_SGI
+ if (draw_menu_bar_impl != 0) {
+ QDrawMenuBarItemImpl impl = draw_menu_bar_impl;
+ (this->*impl)(p, x, y, w, h, mi, g, enabled, active);
diff --git a/qt/qte233-for-opie091-unpolish.patch b/qt/qte233-for-opie091-unpolish.patch
new file mode 100644
index 0000000..ba9e9b3
--- a/dev/null
+++ b/qt/qte233-for-opie091-unpolish.patch
@@ -0,0 +1,23 @@
+--- src.orig/kernel/qapplication.cpp Mon Mar 18 02:11:25 2002
++++ src/kernel/qapplication.cpp Fri Aug 30 04:28:34 2002
+@@ -930,10 +930,10 @@
+ void QApplication::setStyle( QStyle *style )
+ {
+ QStyle* old = app_style;
+- app_style = style;
+
+ if ( startingUp() ) {
+ delete old;
++ app_style = style;
+ return;
+ }
+
+@@ -954,6 +954,8 @@
+ old->unPolish( qApp );
+ }
+
++ app_style = style;
++
+ // take care of possible palette requirements of certain gui
+ // styles. Do it before polishing the application since the style
+ // might call QApplication::setStyle() itself