author | groucho <groucho> | 2003-05-07 09:01:39 (UTC) |
---|---|---|
committer | groucho <groucho> | 2003-05-07 09:01:39 (UTC) |
commit | 118d03d815a7615b9c53363218a7ac45b3f4c514 (patch) (unidiff) | |
tree | 356953e2413cddcec0f35bd47bb6439767da7051 /noncore/apps/opie-reader/ustring.h | |
parent | 00894537decf01c5a5cdc565b2740b5e67a2e90f (diff) | |
download | opie-118d03d815a7615b9c53363218a7ac45b3f4c514.zip opie-118d03d815a7615b9c53363218a7ac45b3f4c514.tar.gz opie-118d03d815a7615b9c53363218a7ac45b3f4c514.tar.bz2 |
Incorporated TimWs current source tree and make it compile
Diffstat (limited to 'noncore/apps/opie-reader/ustring.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-reader/ustring.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/noncore/apps/opie-reader/ustring.h b/noncore/apps/opie-reader/ustring.h index a3ef8df..95da26b 100644 --- a/noncore/apps/opie-reader/ustring.h +++ b/noncore/apps/opie-reader/ustring.h | |||
@@ -60,7 +60,17 @@ inline QString toQString(tchar *_p, unsigned int len) | |||
60 | unsigned int i = 0; | 60 | unsigned int i = 0; |
61 | tchar *p = _p; | 61 | tchar *p = _p; |
62 | QString ret; | 62 | QString ret; |
63 | #ifdef _WINDOWS | ||
64 | //ret.fill(' ', len); | ||
65 | for (i = 0; i < len; i++) | ||
66 | { | ||
67 | if (p[i] == 0) break; | ||
68 | ret.at((uint)i) = p[i]; | ||
69 | } | ||
70 | // while (*p != 0 && i < len) ret.at((uint)i++) = (tchar)(*(p++)); | ||
71 | #else | ||
63 | while (*p != 0 && i < len) ret[i++] = *(p++); | 72 | while (*p != 0 && i < len) ret[i++] = *(p++); |
73 | #endif | ||
64 | return ret; | 74 | return ret; |
65 | } | 75 | } |
66 | 76 | ||