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
837bd535
Commit
837bd535
authored
Jul 24, 2007
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Jul 25, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winefile: Change the settings functions to use the W registry functions.
parent
f987ca01
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
23 deletions
+23
-23
winefile.c
programs/winefile/winefile.c
+23
-23
No files found.
programs/winefile/winefile.c
View file @
837bd535
...
...
@@ -1593,25 +1593,25 @@ static windowOptions load_registry_settings(void)
HKEY
hKey
;
windowOptions
opts
;
RegOpenKeyEx
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
KEY_QUERY_VALUE
,
&
hKey
);
RegOpenKeyExW
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
KEY_QUERY_VALUE
,
&
hKey
);
size
=
sizeof
(
DWORD
);
if
(
RegQueryValueEx
(
hKey
,
reg_start_x
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
start_x
,
&
size
)
!=
ERROR_SUCCESS
)
if
(
RegQueryValueEx
W
(
hKey
,
reg_start_x
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
start_x
,
&
size
)
!=
ERROR_SUCCESS
)
opts
.
start_x
=
CW_USEDEFAULT
;
if
(
RegQueryValueEx
(
hKey
,
reg_start_y
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
start_y
,
&
size
)
!=
ERROR_SUCCESS
)
if
(
RegQueryValueEx
W
(
hKey
,
reg_start_y
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
start_y
,
&
size
)
!=
ERROR_SUCCESS
)
opts
.
start_y
=
CW_USEDEFAULT
;
if
(
RegQueryValueEx
(
hKey
,
reg_width
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
width
,
&
size
)
!=
ERROR_SUCCESS
)
if
(
RegQueryValueEx
W
(
hKey
,
reg_width
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
width
,
&
size
)
!=
ERROR_SUCCESS
)
opts
.
width
=
CW_USEDEFAULT
;
if
(
RegQueryValueEx
(
hKey
,
reg_height
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
height
,
&
size
)
!=
ERROR_SUCCESS
)
if
(
RegQueryValueEx
W
(
hKey
,
reg_height
,
NULL
,
&
type
,
(
LPBYTE
)
&
opts
.
height
,
&
size
)
!=
ERROR_SUCCESS
)
opts
.
height
=
CW_USEDEFAULT
;
RegCloseKey
(
hKey
);
...
...
@@ -1630,27 +1630,27 @@ static void save_registry_settings(void)
width
=
wi
.
rcWindow
.
right
-
wi
.
rcWindow
.
left
;
height
=
wi
.
rcWindow
.
bottom
-
wi
.
rcWindow
.
top
;
if
(
RegOpenKeyEx
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
KEY_SET_VALUE
,
&
hKey
)
!=
ERROR_SUCCESS
)
if
(
RegOpenKeyEx
W
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
KEY_SET_VALUE
,
&
hKey
)
!=
ERROR_SUCCESS
)
{
/* Unable to save registry settings - try to create key */
if
(
RegCreateKeyEx
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
NULL
,
REG_OPTION_NON_VOLATILE
,
KEY_SET_VALUE
,
NULL
,
&
hKey
,
NULL
)
!=
ERROR_SUCCESS
)
if
(
RegCreateKeyExW
(
HKEY_CURRENT_USER
,
registry_key
,
0
,
NULL
,
REG_OPTION_NON_VOLATILE
,
KEY_SET_VALUE
,
NULL
,
&
hKey
,
NULL
)
!=
ERROR_SUCCESS
)
{
/* FIXME: Cannot create key */
return
;
}
}
/* Save all of the settings */
RegSetValueEx
(
hKey
,
reg_start_x
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
wi
.
rcWindow
.
left
,
sizeof
(
DWORD
)
);
RegSetValueEx
(
hKey
,
reg_start_y
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
wi
.
rcWindow
.
top
,
sizeof
(
DWORD
)
);
RegSetValueEx
(
hKey
,
reg_width
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
width
,
sizeof
(
DWORD
)
);
RegSetValueEx
(
hKey
,
reg_height
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
height
,
sizeof
(
DWORD
)
);
RegSetValueExW
(
hKey
,
reg_start_x
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
wi
.
rcWindow
.
left
,
sizeof
(
DWORD
)
);
RegSetValueExW
(
hKey
,
reg_start_y
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
wi
.
rcWindow
.
top
,
sizeof
(
DWORD
)
);
RegSetValueExW
(
hKey
,
reg_width
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
width
,
sizeof
(
DWORD
)
);
RegSetValueExW
(
hKey
,
reg_height
,
0
,
REG_DWORD
,
(
LPBYTE
)
&
height
,
sizeof
(
DWORD
)
);
/* TODO: Save more settings here (List vs. Detailed View, etc.) */
RegCloseKey
(
hKey
);
...
...
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