author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /microkde/qlayoutengine_p.h | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.zip kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.gz kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.bz2 |
initial public commit of qt4 portp1
-rw-r--r-- | microkde/qlayoutengine_p.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/microkde/qlayoutengine_p.h b/microkde/qlayoutengine_p.h index 2d6a556..e782703 100644 --- a/microkde/qlayoutengine_p.h +++ b/microkde/qlayoutengine_p.h | |||
@@ -1,16 +1,18 @@ | |||
1 | //Added by qt3to4: | ||
2 | #include <Q3MemArray> | ||
1 | // THIS IS A COPY OF THE FILE FOUND IN $QTDIR/src/kernel. Needed to modify qsplitter | 3 | // THIS IS A COPY OF THE FILE FOUND IN $QTDIR/src/kernel. Needed to modify qsplitter |
2 | 4 | ||
3 | /**************************************************************************** | 5 | /**************************************************************************** |
4 | ** $Id$ | 6 | ** $Id$ |
5 | ** | 7 | ** |
6 | ** Internal header file. | 8 | ** Internal header file. |
7 | ** | 9 | ** |
8 | ** Created : 981027 | 10 | ** Created : 981027 |
9 | ** | 11 | ** |
10 | ** Copyright (C) 1998-99 by Trolltech AS. All rights reserved. | 12 | ** Copyright (C) 1998-99 by Trolltech AS. All rights reserved. |
11 | ** | 13 | ** |
12 | ** This file is part of the kernel module of the Qt GUI Toolkit. | 14 | ** This file is part of the kernel module of the Qt GUI Toolkit. |
13 | ** | 15 | ** |
14 | ** This file may be distributed under the terms of the Q Public License | 16 | ** This file may be distributed under the terms of the Q Public License |
15 | ** as defined by Trolltech AS of Norway and appearing in the file | 17 | ** as defined by Trolltech AS of Norway and appearing in the file |
16 | ** LICENSE.QPL included in the packaging of this file. | 18 | ** LICENSE.QPL included in the packaging of this file. |
@@ -42,59 +44,55 @@ | |||
42 | 44 | ||
43 | 45 | ||
44 | // | 46 | // |
45 | // W A R N I N G | 47 | // W A R N I N G |
46 | // ------------- | 48 | // ------------- |
47 | // | 49 | // |
48 | // This file is not part of the Qt API. It exists for the convenience | 50 | // This file is not part of the Qt API. It exists for the convenience |
49 | // of qlayout.cpp, qlayoutengine.cpp, qmainwindow.cpp and qsplitter.cpp. | 51 | // of qlayout.cpp, qlayoutengine.cpp, qmainwindow.cpp and qsplitter.cpp. |
50 | // This header file may change from version to version without notice, | 52 | // This header file may change from version to version without notice, |
51 | // or even be removed. | 53 | // or even be removed. |
52 | // | 54 | // |
53 | // We mean it. | 55 | // We mean it. |
54 | // | 56 | // |
55 | // | 57 | // |
56 | 58 | ||
57 | 59 | ||
58 | #ifndef QT_H | ||
59 | #include "qabstractlayout.h" | ||
60 | #endif // QT_H | ||
61 | |||
62 | #ifndef QT_NO_LAYOUT | 60 | #ifndef QT_NO_LAYOUT |
63 | struct QLayoutStruct | 61 | struct QLayoutStruct |
64 | { | 62 | { |
65 | void initParameters() { minimumSize = sizeHint = 0; | 63 | void initParameters() { minimumSize = sizeHint = 0; |
66 | maximumSize = QWIDGETSIZE_MAX; expansive = FALSE; empty = TRUE; } | 64 | maximumSize = QWIDGETSIZE_MAX; expansive = FALSE; empty = TRUE; } |
67 | void init() { stretch = 0; initParameters(); } | 65 | void init() { stretch = 0; initParameters(); } |
68 | //permanent storage: | 66 | //permanent storage: |
69 | int stretch; | 67 | int stretch; |
70 | //parameters: | 68 | //parameters: |
71 | QCOORD sizeHint; | 69 | QCOORD sizeHint; |
72 | QCOORD maximumSize; | 70 | QCOORD maximumSize; |
73 | QCOORD minimumSize; | 71 | QCOORD minimumSize; |
74 | bool expansive; | 72 | bool expansive; |
75 | bool empty; | 73 | bool empty; |
76 | //temporary storage: | 74 | //temporary storage: |
77 | bool done; | 75 | bool done; |
78 | //result: | 76 | //result: |
79 | int pos; | 77 | int pos; |
80 | int size; | 78 | int size; |
81 | }; | 79 | }; |
82 | 80 | ||
83 | 81 | ||
84 | void qGeomCalc( QMemArray<QLayoutStruct> &chain, int start, int count, int pos, | 82 | void qGeomCalc( Q3MemArray<QLayoutStruct> &chain, int start, int count, int pos, |
85 | int space, int spacer ); | 83 | int space, int spacer ); |
86 | 84 | ||
87 | 85 | ||
88 | 86 | ||
89 | /* | 87 | /* |
90 | Modify total maximum (max) and total expansion (exp) | 88 | Modify total maximum (max) and total expansion (exp) |
91 | when adding boxmax/boxexp. | 89 | when adding boxmax/boxexp. |
92 | 90 | ||
93 | Expansive boxes win over non-expansive boxes. | 91 | Expansive boxes win over non-expansive boxes. |
94 | */ | 92 | */ |
95 | static inline void qMaxExpCalc( QCOORD & max, bool &exp, | 93 | static inline void qMaxExpCalc( QCOORD & max, bool &exp, |
96 | QCOORD boxmax, bool boxexp ) | 94 | QCOORD boxmax, bool boxexp ) |
97 | { | 95 | { |
98 | if ( exp ) { | 96 | if ( exp ) { |
99 | if ( boxexp ) | 97 | if ( boxexp ) |
100 | max = QMAX( max, boxmax ); | 98 | max = QMAX( max, boxmax ); |