Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
fb35a575
Commit
fb35a575
authored
May 09, 2008
by
Kusanagi Kouichi
Committed by
Alexandre Julliard
May 09, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
imm32: Avoid false FIXMEs.
parent
b8a57423
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
127 additions
and
116 deletions
+127
-116
imm.c
dlls/imm32/imm.c
+127
-116
No files found.
dlls/imm32/imm.c
View file @
fb35a575
...
@@ -1008,81 +1008,86 @@ LONG WINAPI ImmGetCompositionStringA(
...
@@ -1008,81 +1008,86 @@ LONG WINAPI ImmGetCompositionStringA(
compdata
=
ImmLockIMCC
(
data
->
IMC
.
hCompStr
);
compdata
=
ImmLockIMCC
(
data
->
IMC
.
hCompStr
);
compstr
=
(
LPCOMPOSITIONSTRING
)
compdata
;
compstr
=
(
LPCOMPOSITIONSTRING
)
compdata
;
if
(
dwIndex
==
GCS_RESULTSTR
&&
compstr
->
dwResultStrLen
>
0
&&
switch
(
dwIndex
)
compstr
->
dwResultStrOffset
>
0
)
{
{
LPWSTR
ResultStr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultStrOffset
);
case
GCS_RESULTSTR
:
if
(
compstr
->
dwResultStrLen
>
0
&&
compstr
->
dwResultStrOffset
>
0
)
{
LPWSTR
ResultStr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultStrOffset
);
TRACE
(
"GCS_RESULTSTR %p %i
\n
"
,
ResultStr
,
TRACE
(
"GCS_RESULTSTR %p %i
\n
"
,
ResultStr
,
compstr
->
dwResultStrLen
);
compstr
->
dwResultStrLen
);
buf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
compstr
->
dwResultStrLen
*
3
);
buf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
compstr
->
dwResultStrLen
*
3
);
rc
=
WideCharToMultiByte
(
CP_ACP
,
0
,
ResultStr
,
rc
=
WideCharToMultiByte
(
CP_ACP
,
0
,
ResultStr
,
compstr
->
dwResultStrLen
,
buf
,
compstr
->
dwResultStrLen
,
buf
,
compstr
->
dwResultStrLen
*
3
,
NULL
,
NULL
);
compstr
->
dwResultStrLen
*
3
,
NULL
,
NULL
);
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
buf
,
rc
);
memcpy
(
lpBuf
,
buf
,
rc
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
);
}
}
else
if
(
dwIndex
==
GCS_COMPSTR
&&
compstr
->
dwCompStrLen
>
0
&&
break
;
compstr
->
dwCompStrOffset
>
0
)
case
GCS_COMPSTR
:
{
if
(
compstr
->
dwCompStrLen
>
0
&&
compstr
->
dwCompStrOffset
>
0
)
LPWSTR
CompString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompStrOffset
);
{
LPWSTR
CompString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompStrOffset
);
TRACE
(
"GCS_COMPSTR %p %i
\n
"
,
CompString
,
compstr
->
dwCompStrLen
);
TRACE
(
"GCS_COMPSTR %p %i
\n
"
,
CompString
,
compstr
->
dwCompStrLen
);
buf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
compstr
->
dwCompStrLen
*
3
);
buf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
compstr
->
dwCompStrLen
*
3
);
rc
=
WideCharToMultiByte
(
CP_ACP
,
0
,
CompString
,
rc
=
WideCharToMultiByte
(
CP_ACP
,
0
,
CompString
,
compstr
->
dwCompStrLen
,
buf
,
compstr
->
dwCompStrLen
,
buf
,
compstr
->
dwCompStrLen
*
3
,
NULL
,
NULL
);
compstr
->
dwCompStrLen
*
3
,
NULL
,
NULL
);
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
buf
,
rc
);
memcpy
(
lpBuf
,
buf
,
rc
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
);
}
}
else
if
(
dwIndex
==
GCS_COMPATTR
&&
compstr
->
dwCompAttrLen
>
0
&&
break
;
compstr
->
dwCompAttrOffset
>
0
)
case
GCS_COMPATTR
:
{
if
(
compstr
->
dwCompAttrLen
>
0
&&
compstr
->
dwCompAttrOffset
>
0
)
LPWSTR
Compattr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompAttrOffset
);
{
TRACE
(
"GCS_COMPATTR %p %i
\n
"
,
Compattr
,
compstr
->
dwCompAttrLen
);
LPWSTR
Compattr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompAttrOffset
);
TRACE
(
"GCS_COMPATTR %p %i
\n
"
,
Compattr
,
compstr
->
dwCompAttrLen
);
rc
=
compstr
->
dwCompAttrLen
;
rc
=
compstr
->
dwCompAttrLen
;
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
Compattr
,
rc
);
memcpy
(
lpBuf
,
Compattr
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_COMPCLAUSE
&&
compstr
->
dwCompClauseLen
>
0
&&
break
;
compstr
->
dwCompClauseOffset
>
0
)
case
GCS_COMPCLAUSE
:
{
if
(
compstr
->
dwCompClauseLen
>
0
&&
compstr
->
dwCompClauseOffset
>
0
)
LPWSTR
Compclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompClauseOffset
);
{
TRACE
(
"GCS_COMPCLAUSE %p %i
\n
"
,
Compclause
,
compstr
->
dwCompClauseLen
);
LPWSTR
Compclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompClauseOffset
);
TRACE
(
"GCS_COMPCLAUSE %p %i
\n
"
,
Compclause
,
compstr
->
dwCompClauseLen
);
rc
=
compstr
->
dwCompClauseLen
;
rc
=
compstr
->
dwCompClauseLen
;
if
(
dwBufLen
>=
compstr
->
dwCompClauseLen
)
if
(
dwBufLen
>=
compstr
->
dwCompClauseLen
)
memcpy
(
lpBuf
,
Compclause
,
rc
);
memcpy
(
lpBuf
,
Compclause
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_RESULTCLAUSE
&&
compstr
->
dwResultClauseLen
>
0
&&
break
;
compstr
->
dwResultClauseOffset
>
0
)
case
GCS_RESULTCLAUSE
:
{
if
(
compstr
->
dwResultClauseLen
>
0
&&
compstr
->
dwResultClauseOffset
>
0
)
LPWSTR
Resultclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultClauseOffset
);
{
TRACE
(
"GCS_RESULTCLAUSE %p %i
\n
"
,
Resultclause
,
compstr
->
dwResultClauseLen
);
LPWSTR
Resultclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultClauseOffset
);
TRACE
(
"GCS_RESULTCLAUSE %p %i
\n
"
,
Resultclause
,
compstr
->
dwResultClauseLen
);
rc
=
compstr
->
dwResultClauseLen
;
rc
=
compstr
->
dwResultClauseLen
;
if
(
dwBufLen
>=
compstr
->
dwResultClauseLen
)
if
(
dwBufLen
>=
compstr
->
dwResultClauseLen
)
memcpy
(
lpBuf
,
Resultclause
,
rc
);
memcpy
(
lpBuf
,
Resultclause
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_CURSORPOS
)
break
;
{
case
GCS_CURSORPOS
:
TRACE
(
"GCS_CURSORPOS
\n
"
);
TRACE
(
"GCS_CURSORPOS
\n
"
);
rc
=
compstr
->
dwCursorPos
;
rc
=
compstr
->
dwCursorPos
;
}
break
;
else
if
(
dwIndex
==
GCS_DELTASTART
)
case
GCS_DELTASTART
:
{
TRACE
(
"GCS_DELTASTART
\n
"
);
TRACE
(
"GCS_DELTASTART
\n
"
);
rc
=
compstr
->
dwDeltaStart
;
rc
=
compstr
->
dwDeltaStart
;
}
break
;
else
default:
{
FIXME
(
"Unhandled index 0x%x
\n
"
,
dwIndex
);
FIXME
(
"Unhandled index 0x%x
\n
"
,
dwIndex
);
break
;
}
}
ImmUnlockIMCC
(
data
->
IMC
.
hCompStr
);
ImmUnlockIMCC
(
data
->
IMC
.
hCompStr
);
...
@@ -1113,74 +1118,80 @@ LONG WINAPI ImmGetCompositionStringW(
...
@@ -1113,74 +1118,80 @@ LONG WINAPI ImmGetCompositionStringW(
compdata
=
ImmLockIMCC
(
data
->
IMC
.
hCompStr
);
compdata
=
ImmLockIMCC
(
data
->
IMC
.
hCompStr
);
compstr
=
(
LPCOMPOSITIONSTRING
)
compdata
;
compstr
=
(
LPCOMPOSITIONSTRING
)
compdata
;
if
(
dwIndex
==
GCS_RESULTSTR
&&
compstr
->
dwResultStrLen
>
0
&&
switch
(
dwIndex
)
compstr
->
dwResultStrOffset
>
0
)
{
{
LPWSTR
ResultStr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultStrOffset
);
case
GCS_RESULTSTR
:
rc
=
compstr
->
dwResultStrLen
*
sizeof
(
WCHAR
);
if
(
compstr
->
dwResultStrLen
>
0
&&
compstr
->
dwResultStrOffset
>
0
)
{
LPWSTR
ResultStr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultStrOffset
);
rc
=
compstr
->
dwResultStrLen
*
sizeof
(
WCHAR
);
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
ResultStr
,
rc
);
memcpy
(
lpBuf
,
ResultStr
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_RESULTREADSTR
&&
compstr
->
dwResultReadStrLen
>
0
&&
break
;
compstr
->
dwResultReadStrOffset
>
0
)
case
GCS_RESULTREADSTR
:
{
if
(
compstr
->
dwResultReadStrLen
>
0
&&
compstr
->
dwResultReadStrOffset
>
0
)
LPWSTR
ResultReadString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultReadStrOffset
);
{
LPWSTR
ResultReadString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwResultReadStrOffset
);
rc
=
compstr
->
dwResultReadStrLen
*
sizeof
(
WCHAR
);
rc
=
compstr
->
dwResultReadStrLen
*
sizeof
(
WCHAR
);
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
ResultReadString
,
rc
);
memcpy
(
lpBuf
,
ResultReadString
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_COMPSTR
&&
compstr
->
dwCompStrLen
>
0
&&
break
;
compstr
->
dwCompStrOffset
>
0
)
case
GCS_COMPSTR
:
{
if
(
compstr
->
dwCompStrLen
>
0
&&
compstr
->
dwCompStrOffset
>
0
)
LPWSTR
CompString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompStrOffset
);
{
rc
=
compstr
->
dwCompStrLen
*
sizeof
(
WCHAR
);
LPWSTR
CompString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompStrOffset
);
if
(
dwBufLen
>=
rc
)
rc
=
compstr
->
dwCompStrLen
*
sizeof
(
WCHAR
);
memcpy
(
lpBuf
,
CompString
,
rc
);
if
(
dwBufLen
>=
rc
)
}
memcpy
(
lpBuf
,
CompString
,
rc
);
else
if
(
dwIndex
==
GCS_COMPATTR
&&
compstr
->
dwCompAttrLen
>
0
&&
}
compstr
->
dwCompAttrOffset
>
0
)
break
;
{
case
GCS_COMPATTR
:
if
(
compstr
->
dwCompAttrLen
>
0
&&
compstr
->
dwCompAttrOffset
>
0
)
{
LPWSTR
Compattr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompAttrOffset
);
LPWSTR
Compattr
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompAttrOffset
);
rc
=
compstr
->
dwCompAttrLen
;
rc
=
compstr
->
dwCompAttrLen
;
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
Compattr
,
rc
);
memcpy
(
lpBuf
,
Compattr
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_COMPCLAUSE
&&
compstr
->
dwCompClauseLen
>
0
&&
break
;
compstr
->
dwCompClauseOffset
>
0
)
case
GCS_COMPCLAUSE
:
{
if
(
compstr
->
dwCompClauseLen
>
0
&&
compstr
->
dwCompClauseOffset
>
0
)
LPWSTR
Compclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompClauseOffset
);
{
LPWSTR
Compclause
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompClauseOffset
);
rc
=
compstr
->
dwCompClauseLen
;
rc
=
compstr
->
dwCompClauseLen
;
if
(
dwBufLen
>=
compstr
->
dwCompClauseLen
)
if
(
dwBufLen
>=
compstr
->
dwCompClauseLen
)
memcpy
(
lpBuf
,
Compclause
,
rc
);
memcpy
(
lpBuf
,
Compclause
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_COMPREADSTR
&&
compstr
->
dwCompReadStrLen
>
0
&&
break
;
compstr
->
dwCompReadStrOffset
>
0
)
case
GCS_COMPREADSTR
:
{
if
(
compstr
->
dwCompReadStrLen
>
0
&&
compstr
->
dwCompReadStrOffset
>
0
)
LPWSTR
CompReadString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompReadStrOffset
);
{
LPWSTR
CompReadString
=
(
LPWSTR
)(
compdata
+
compstr
->
dwCompReadStrOffset
);
rc
=
compstr
->
dwCompReadStrLen
*
sizeof
(
WCHAR
);
rc
=
compstr
->
dwCompReadStrLen
*
sizeof
(
WCHAR
);
if
(
dwBufLen
>=
rc
)
if
(
dwBufLen
>=
rc
)
memcpy
(
lpBuf
,
CompReadString
,
rc
);
memcpy
(
lpBuf
,
CompReadString
,
rc
);
}
}
else
if
(
dwIndex
==
GCS_CURSORPOS
)
break
;
{
case
GCS_CURSORPOS
:
TRACE
(
"GCS_CURSORPOS
\n
"
);
TRACE
(
"GCS_CURSORPOS
\n
"
);
rc
=
compstr
->
dwCursorPos
;
rc
=
compstr
->
dwCursorPos
;
}
break
;
else
if
(
dwIndex
==
GCS_DELTASTART
)
case
GCS_DELTASTART
:
{
TRACE
(
"GCS_DELTASTART
\n
"
);
TRACE
(
"GCS_DELTASTART
\n
"
);
rc
=
compstr
->
dwDeltaStart
;
rc
=
compstr
->
dwDeltaStart
;
}
break
;
else
default:
{
FIXME
(
"Unhandled index 0x%x
\n
"
,
dwIndex
);
FIXME
(
"Unhandled index 0x%x
\n
"
,
dwIndex
);
break
;
}
}
ImmUnlockIMCC
(
data
->
IMC
.
hCompStr
);
ImmUnlockIMCC
(
data
->
IMC
.
hCompStr
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment