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
6fe38e56
Commit
6fe38e56
authored
Sep 03, 1999
by
Pascal Lessard
Committed by
Alexandre Julliard
Sep 03, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
The backspace is now handled in the WM_CHAR message.
parent
1cc0a9a2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
12 deletions
+14
-12
edit.c
controls/edit.c
+14
-12
No files found.
controls/edit.c
View file @
6fe38e56
...
@@ -2889,6 +2889,8 @@ static BOOL EDIT_EM_Undo(WND *wnd, EDITSTATE *es)
...
@@ -2889,6 +2889,8 @@ static BOOL EDIT_EM_Undo(WND *wnd, EDITSTATE *es)
*/
*/
static
void
EDIT_WM_Char
(
WND
*
wnd
,
EDITSTATE
*
es
,
CHAR
c
,
DWORD
key_data
)
static
void
EDIT_WM_Char
(
WND
*
wnd
,
EDITSTATE
*
es
,
CHAR
c
,
DWORD
key_data
)
{
{
BOOL
control
=
GetKeyState
(
VK_CONTROL
)
&
0x8000
;
switch
(
c
)
{
switch
(
c
)
{
case
'\r'
:
case
'\r'
:
case
'\n'
:
case
'\n'
:
...
@@ -2904,6 +2906,18 @@ static void EDIT_WM_Char(WND *wnd, EDITSTATE *es, CHAR c, DWORD key_data)
...
@@ -2904,6 +2906,18 @@ static void EDIT_WM_Char(WND *wnd, EDITSTATE *es, CHAR c, DWORD key_data)
if
((
es
->
style
&
ES_MULTILINE
)
&&
!
(
es
->
style
&
ES_READONLY
))
if
((
es
->
style
&
ES_MULTILINE
)
&&
!
(
es
->
style
&
ES_READONLY
))
EDIT_EM_ReplaceSel
(
wnd
,
es
,
TRUE
,
"
\t
"
);
EDIT_EM_ReplaceSel
(
wnd
,
es
,
TRUE
,
"
\t
"
);
break
;
break
;
case
VK_BACK
:
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
!
control
)
{
if
(
es
->
selection_start
!=
es
->
selection_end
)
EDIT_WM_Clear
(
wnd
,
es
);
else
{
/* delete character left of caret */
EDIT_EM_SetSel
(
wnd
,
es
,
-
1
,
0
,
FALSE
);
EDIT_MoveBackward
(
wnd
,
es
,
TRUE
);
EDIT_WM_Clear
(
wnd
,
es
);
}
}
break
;
default:
default:
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
((
BYTE
)
c
>=
' '
)
&&
(
c
!=
127
))
{
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
((
BYTE
)
c
>=
' '
)
&&
(
c
!=
127
))
{
char
str
[
2
];
char
str
[
2
];
...
@@ -3384,18 +3398,6 @@ static LRESULT EDIT_WM_KeyDown(WND *wnd, EDITSTATE *es, INT key, DWORD key_data)
...
@@ -3384,18 +3398,6 @@ static LRESULT EDIT_WM_KeyDown(WND *wnd, EDITSTATE *es, INT key, DWORD key_data)
if
(
es
->
style
&
ES_MULTILINE
)
if
(
es
->
style
&
ES_MULTILINE
)
EDIT_MovePageDown_ML
(
wnd
,
es
,
shift
);
EDIT_MovePageDown_ML
(
wnd
,
es
,
shift
);
break
;
break
;
case
VK_BACK
:
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
!
control
)
{
if
(
es
->
selection_start
!=
es
->
selection_end
)
EDIT_WM_Clear
(
wnd
,
es
);
else
{
/* delete character left of caret */
EDIT_EM_SetSel
(
wnd
,
es
,
-
1
,
0
,
FALSE
);
EDIT_MoveBackward
(
wnd
,
es
,
TRUE
);
EDIT_WM_Clear
(
wnd
,
es
);
}
}
break
;
case
VK_DELETE
:
case
VK_DELETE
:
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
!
(
shift
&&
control
))
{
if
(
!
(
es
->
style
&
ES_READONLY
)
&&
!
(
shift
&&
control
))
{
if
(
es
->
selection_start
!=
es
->
selection_end
)
{
if
(
es
->
selection_start
!=
es
->
selection_end
)
{
...
...
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