Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
c91e9db0
Commit
c91e9db0
authored
Feb 06, 2012
by
Nikolay Sivov
Committed by
Alexandre Julliard
Feb 06, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32: Use string comparison as autocompletion check.
parent
f39209cd
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
autocomplete.c
dlls/shell32/autocomplete.c
+9
-5
No files found.
dlls/shell32/autocomplete.c
View file @
c91e9db0
...
@@ -121,6 +121,9 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
...
@@ -121,6 +121,9 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
}
}
return
CallWindowProcW
(
This
->
wpOrigEditProc
,
hwnd
,
uMsg
,
wParam
,
lParam
);
return
CallWindowProcW
(
This
->
wpOrigEditProc
,
hwnd
,
uMsg
,
wParam
,
lParam
);
case
WM_KEYUP
:
case
WM_KEYUP
:
{
int
len
;
GetWindowTextW
(
hwnd
,
hwndText
,
sizeof
(
hwndText
)
/
sizeof
(
WCHAR
));
GetWindowTextW
(
hwnd
,
hwndText
,
sizeof
(
hwndText
)
/
sizeof
(
WCHAR
));
switch
(
wParam
)
{
switch
(
wParam
)
{
...
@@ -208,7 +211,8 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
...
@@ -208,7 +211,8 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
SendMessageW
(
This
->
hwndListBox
,
LB_RESETCONTENT
,
0
,
0
);
SendMessageW
(
This
->
hwndListBox
,
LB_RESETCONTENT
,
0
,
0
);
HeapFree
(
GetProcessHeap
(),
0
,
This
->
txtbackup
);
HeapFree
(
GetProcessHeap
(),
0
,
This
->
txtbackup
);
This
->
txtbackup
=
HeapAlloc
(
GetProcessHeap
(),
0
,
(
lstrlenW
(
hwndText
)
+
1
)
*
sizeof
(
WCHAR
));
len
=
strlenW
(
hwndText
);
This
->
txtbackup
=
HeapAlloc
(
GetProcessHeap
(),
0
,
(
len
+
1
)
*
sizeof
(
WCHAR
));
lstrcpyW
(
This
->
txtbackup
,
hwndText
);
lstrcpyW
(
This
->
txtbackup
,
hwndText
);
/* Returns if there is no text to search and we doesn't want to display all the entries */
/* Returns if there is no text to search and we doesn't want to display all the entries */
...
@@ -223,15 +227,14 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
...
@@ -223,15 +227,14 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
if
(
hr
!=
S_OK
)
if
(
hr
!=
S_OK
)
break
;
break
;
if
(
StrStrIW
(
strs
,
hwndText
)
==
strs
)
{
if
(
!
strncmpiW
(
hwndText
,
strs
,
len
)
)
{
if
(
!
filled
&&
(
This
->
options
&
ACO_AUTOAPPEND
))
{
if
(
!
filled
&&
(
This
->
options
&
ACO_AUTOAPPEND
))
{
INT
typed_length
=
strlenW
(
hwndText
);
WCHAR
buffW
[
255
];
WCHAR
buffW
[
255
];
strcpyW
(
buffW
,
hwndText
);
strcpyW
(
buffW
,
hwndText
);
strcatW
(
buffW
,
&
strs
[
typed_length
]);
strcatW
(
buffW
,
&
strs
[
len
]);
SetWindowTextW
(
hwnd
,
buffW
);
SetWindowTextW
(
hwnd
,
buffW
);
SendMessageW
(
hwnd
,
EM_SETSEL
,
typed_length
,
strlenW
(
strs
));
SendMessageW
(
hwnd
,
EM_SETSEL
,
len
,
strlenW
(
strs
));
if
(
!
(
This
->
options
&
ACO_AUTOSUGGEST
))
if
(
!
(
This
->
options
&
ACO_AUTOSUGGEST
))
break
;
break
;
}
}
...
@@ -262,6 +265,7 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
...
@@ -262,6 +265,7 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
}
}
break
;
break
;
}
case
WM_DESTROY
:
case
WM_DESTROY
:
{
{
WNDPROC
proc
=
This
->
wpOrigEditProc
;
WNDPROC
proc
=
This
->
wpOrigEditProc
;
...
...
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