summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/libpreload/config.in5
-rw-r--r--core/launcher/libpreload/libpreload.pro14
-rw-r--r--core/launcher/libpreload/preload.cpp138
-rw-r--r--core/launcher/opie-taskbar.control2
4 files changed, 1 insertions, 158 deletions
diff --git a/core/launcher/libpreload/config.in b/core/launcher/libpreload/config.in
deleted file mode 100644
index c3cfd6f..0000000
--- a/core/launcher/libpreload/config.in
+++ b/dev/null
@@ -1,5 +0,0 @@
1config LIBPRELOAD
2 boolean "Preload library"
3 default "y" if ! X11
4 default "n" if X11
5 depends on ! X11
diff --git a/core/launcher/libpreload/libpreload.pro b/core/launcher/libpreload/libpreload.pro
deleted file mode 100644
index ed426da..0000000
--- a/core/launcher/libpreload/libpreload.pro
+++ b/dev/null
@@ -1,14 +0,0 @@
1TEMPLATE = lib
2
3CONFIG = qt release warn_on
4
5SOURCES = preload.cpp
6
7HEADERS =
8
9INCLUDEPATH += $(QTDIR)/include
10
11DESTDIR = $(QTDIR)/lib
12TARGET = preload
13
14VERSION = 1.0.0
diff --git a/core/launcher/libpreload/preload.cpp b/core/launcher/libpreload/preload.cpp
deleted file mode 100644
index 345620b..0000000
--- a/core/launcher/libpreload/preload.cpp
+++ b/dev/null
@@ -1,138 +0,0 @@
1
2#define _GNU_SOURCE
3//#define private public
4//#define protected public
5
6#include <qapplication.h>
7#include <qwsdecoration_qws.h>
8#include <qcommonstyle.h>
9
10//#include <qapplication.h>
11//#include <qfont.h>
12
13//class QStyle;
14//class QApplication;
15class QFont;
16//class QWSDecoration;
17class QFontDatabase;
18
19#include <dlfcn.h>
20#include <unistd.h>
21#include <stdio.h>
22#include <stdlib.h>
23
24
25typedef void ( *qapp_setstyle_t ) ( QStyle * );
26typedef void ( *qapp_setdeco_t ) ( QWSDecoration * );
27typedef void ( *qapp_setfont_t ) ( const QFont &, bool, const char * );
28typedef void ( *qapp_polish_t ) ( QApplication *, QWidget * );
29typedef QValueList <int> ( *qfdb_pointsizes_t ) ( QFontDatabase *, QString const &, QString const &, QString const & );
30
31
32static int *opie_block_style_p = 0;
33
34extern "C" {
35
36extern void __gmon_start ( ) __attribute(( weak ));
37
38extern void __gmon_start__ ( )
39{
40}
41
42static void *resolve_symbol ( const char *sym )
43{
44 void *adr = ::dlsym ( RTLD_NEXT, sym );
45
46 if ( !adr )
47 ::fprintf ( stderr, "PANIC: Could not resolve symbol \"%s\"\n", sym );
48
49 return adr;
50}
51
52void polish__12QApplicationP7QWidget ( QApplication *that, QWidget *w )
53{
54 static qapp_polish_t qpolish = 0;
55
56 if ( !qpolish )
57 qpolish = (qapp_polish_t) resolve_symbol ( "polish__12QApplicationP7QWidget" );
58
59 if ( qpolish )
60 ( *qpolish ) ( that, w );
61
62 if (( ::strcmp ( qApp-> argv ( ) [0], "HancomMobileWord" ) == 0 ) && ( w-> inherits ( "HTextEdit" ))) {
63 QPalette pal = w-> palette ( );
64 pal. setColor ( QColorGroup::Background, pal. color ( QPalette::Active, QColorGroup::Base ));
65 w-> setPalette ( pal );
66 // w-> setPalette ( w-> palette ( ). active ( ). color ( QColorGroup::Base ));
67 }
68}
69
70extern QValueList <int> pointSizes__13QFontDatabaseRC7QStringN21 ( QFontDatabase *that, QString const &family, QString const &style, QString const &charset )
71{
72 static qfdb_pointsizes_t qpointsizes = 0;
73
74 if ( !qpointsizes )
75 qpointsizes = (qfdb_pointsizes_t) resolve_symbol ( "pointSizes__13QFontDatabaseRC7QStringN21" );
76
77 QValueList <int> sl;
78
79 if ( qpointsizes ) {
80 sl = ( *qpointsizes ) ( that, family, style, charset );
81
82 if ( ::strcmp ( qApp-> argv ( ) [0], "HancomMobileWord" ) == 0 ) {
83 for ( QValueList <int>::Iterator it = sl. begin ( ); it != sl. end ( ); ++it )
84 *it *= 10;
85 }
86 }
87
88 return sl;
89}
90
91extern void setStyle__12QApplicationP6QStyle ( QStyle *style )
92{
93 static qapp_setstyle_t qsetstyle = 0;
94
95 if ( !qsetstyle )
96 qsetstyle = (qapp_setstyle_t) resolve_symbol ( "setStyle__12QApplicationP6QStyle" );
97
98 if ( !opie_block_style_p )
99 opie_block_style_p = (int *) resolve_symbol ( "opie_block_style" );
100
101 if ( !qsetstyle || ( opie_block_style_p && ( *opie_block_style_p & 0x01 )))
102 delete style;
103 else
104 ( *qsetstyle ) ( style );
105}
106
107extern void setFont__12QApplicationRC5QFontbPCc ( const QFont &fnt, bool informWidgets, const char * className )
108{
109 static qapp_setfont_t qsetfont = 0;
110
111 if ( !qsetfont )
112 qsetfont = (qapp_setfont_t) resolve_symbol ( "setFont__12QApplicationRC5QFontbPCc" );
113
114 if ( !opie_block_style_p )
115 opie_block_style_p = (int *) resolve_symbol ( "opie_block_style" );
116
117 if ( qsetfont && !( opie_block_style_p && ( *opie_block_style_p & 0x02 )))
118 ( *qsetfont ) ( fnt, informWidgets, className );
119}
120
121
122extern void qwsSetDecoration__12QApplicationP13QWSDecoration ( QWSDecoration *deco )
123{
124 static qapp_setdeco_t qsetdeco = 0;
125
126 if ( !qsetdeco )
127 qsetdeco = (qapp_setdeco_t) resolve_symbol ( "qwsSetDecoration__12QApplicationP13QWSDecoration" );
128
129 if ( !opie_block_style_p )
130 opie_block_style_p = (int *) resolve_symbol ( "opie_block_style" );
131
132 if ( !qsetdeco || ( opie_block_style_p && ( *opie_block_style_p & 0x04 )))
133 delete deco;
134 else
135 ( *qsetdeco ) ( deco );
136}
137
138}
diff --git a/core/launcher/opie-taskbar.control b/core/launcher/opie-taskbar.control
index dca4b08..13e5715 100644
--- a/core/launcher/opie-taskbar.control
+++ b/core/launcher/opie-taskbar.control
@@ -1,4 +1,4 @@
1Files: bin/qpe $QTDIR/lib/libpreload.so* apps/Settings/Calibrate.desktop pics/launcher plugins/applets/libsuspendapplet.so* plugins/applets/libhomeapplet.so* plugins/applets/liblogoutapplet.so* 1Files: bin/qpe apps/Settings/Calibrate.desktop pics/launcher plugins/applets/libsuspendapplet.so* plugins/applets/libhomeapplet.so* plugins/applets/liblogoutapplet.so*
2Priority: required 2Priority: required
3Section: opie/system 3Section: opie/system
4Maintainer: Project Opie <opie@handhelds.org> 4Maintainer: Project Opie <opie@handhelds.org>