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
4663d5d1
Commit
4663d5d1
authored
Aug 08, 2005
by
Stefan Leichter
Committed by
Alexandre Julliard
Aug 08, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Basic implementation of AtlModuleUpdateRegistryFromResourceD.
parent
7257b707
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
25 deletions
+41
-25
atl_main.c
dlls/atl/atl_main.c
+0
-21
registrar.c
dlls/atl/registrar.c
+41
-4
No files found.
dlls/atl/atl_main.c
View file @
4663d5d1
...
@@ -166,27 +166,6 @@ HRESULT WINAPI AtlInternalQueryInterface(LPVOID this, const _ATL_INTMAP_ENTRY* p
...
@@ -166,27 +166,6 @@ HRESULT WINAPI AtlInternalQueryInterface(LPVOID this, const _ATL_INTMAP_ENTRY* p
}
}
/***********************************************************************
/***********************************************************************
* AtlModuleUpdateRegistryFromResourceD [ATL.@]
*
*/
HRESULT
WINAPI
AtlModuleUpdateRegistryFromResourceD
(
_ATL_MODULEW
*
pM
,
LPCOLESTR
lpszRes
,
BOOL
bRegister
,
struct
_ATL_REGMAP_ENTRY
*
pMapEntries
,
IRegistrar
*
pReg
)
{
HINSTANCE
hInst
=
pM
->
m_hInst
;
/* everything inside this function below this point
* should go into atl71.AtlUpdateRegistryFromResourceD
*/
WCHAR
module_name
[
MAX_PATH
];
GetModuleFileNameW
(
hInst
,
module_name
,
MAX_PATH
);
FIXME
(
"stub %p (%s), %s, %d, %p, %p
\n
"
,
hInst
,
debugstr_w
(
module_name
),
debugstr_w
(
lpszRes
),
bRegister
,
pMapEntries
,
pReg
);
return
S_OK
;
}
/***********************************************************************
* AtlModuleRegisterServer [ATL.@]
* AtlModuleRegisterServer [ATL.@]
*
*
*/
*/
...
...
dlls/atl/registrar.c
View file @
4663d5d1
...
@@ -31,6 +31,7 @@
...
@@ -31,6 +31,7 @@
#define ATL_INITGUID
#define ATL_INITGUID
#include "atliface.h"
#include "atliface.h"
#include "atlbase.h"
#include "wine/debug.h"
#include "wine/debug.h"
#include "wine/unicode.h"
#include "wine/unicode.h"
...
@@ -753,14 +754,13 @@ HRESULT WINAPI ATL_DllGetClassObject(REFCLSID clsid, REFIID riid, LPVOID *ppvObj
...
@@ -753,14 +754,13 @@ HRESULT WINAPI ATL_DllGetClassObject(REFCLSID clsid, REFIID riid, LPVOID *ppvObj
extern
HINSTANCE
hInst
;
extern
HINSTANCE
hInst
;
static
HRESULT
do_register_
server
(
BOOL
do_register
)
static
HRESULT
do_register_
dll_server
(
LPCOLESTR
wszDll
,
LPCOLESTR
wszId
,
BOOL
do_register
)
{
{
WCHAR
buf
[
MAX_PATH
];
WCHAR
buf
[
MAX_PATH
];
HRESULT
hres
;
HRESULT
hres
;
IRegistrar
*
pRegistrar
;
IRegistrar
*
pRegistrar
;
static
const
WCHAR
wszModule
[]
=
{
'M'
,
'O'
,
'D'
,
'U'
,
'L'
,
'E'
,
0
};
static
const
WCHAR
wszModule
[]
=
{
'M'
,
'O'
,
'D'
,
'U'
,
'L'
,
'E'
,
0
};
static
const
WCHAR
wszDll
[]
=
{
'a'
,
't'
,
'l'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
const
WCHAR
wszRegistry
[]
=
{
'R'
,
'E'
,
'G'
,
'I'
,
'S'
,
'T'
,
'R'
,
'Y'
,
0
};
static
const
WCHAR
wszRegistry
[]
=
{
'R'
,
'E'
,
'G'
,
'I'
,
'S'
,
'T'
,
'R'
,
'Y'
,
0
};
static
const
WCHAR
wszCLSID_ATLRegistrar
[]
=
static
const
WCHAR
wszCLSID_ATLRegistrar
[]
=
{
'C'
,
'L'
,
'S'
,
'I'
,
'D'
,
'_'
,
'A'
,
'T'
,
'L'
,
'R'
,
'e'
,
'g'
,
'i'
,
's'
,
't'
,
'r'
,
'a'
,
'r'
,
0
};
{
'C'
,
'L'
,
'S'
,
'I'
,
'D'
,
'_'
,
'A'
,
'T'
,
'L'
,
'R'
,
'e'
,
'g'
,
'i'
,
's'
,
't'
,
'r'
,
'a'
,
'r'
,
0
};
...
@@ -772,14 +772,51 @@ static HRESULT do_register_server(BOOL do_register)
...
@@ -772,14 +772,51 @@ static HRESULT do_register_server(BOOL do_register)
IRegistrar_AddReplacement
(
pRegistrar
,
wszCLSID_ATLRegistrar
,
buf
);
IRegistrar_AddReplacement
(
pRegistrar
,
wszCLSID_ATLRegistrar
,
buf
);
if
(
do_register
)
if
(
do_register
)
hres
=
IRegistrar_ResourceRegister
(
pRegistrar
,
wszDll
,
1
,
wszRegistry
);
hres
=
IRegistrar_ResourceRegister
Sz
(
pRegistrar
,
wszDll
,
wszId
,
wszRegistry
);
else
else
hres
=
IRegistrar_ResourceUnregister
(
pRegistrar
,
wszDll
,
1
,
wszRegistry
);
hres
=
IRegistrar_ResourceUnregister
Sz
(
pRegistrar
,
wszDll
,
wszId
,
wszRegistry
);
IRegistrar_Release
(
pRegistrar
);
IRegistrar_Release
(
pRegistrar
);
return
hres
;
return
hres
;
}
}
static
HRESULT
do_register_server
(
BOOL
do_register
)
{
static
const
WCHAR
wszDll
[]
=
{
'a'
,
't'
,
'l'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
UINT
nID
=
1
;
return
do_register_dll_server
(
wszDll
,
(
LPCOLESTR
)
nID
,
do_register
);
}
/***********************************************************************
* AtlModuleUpdateRegistryFromResourceD [ATL.@]
*
*/
HRESULT
WINAPI
AtlModuleUpdateRegistryFromResourceD
(
_ATL_MODULEW
*
pM
,
LPCOLESTR
lpszRes
,
BOOL
bRegister
,
struct
_ATL_REGMAP_ENTRY
*
pMapEntries
,
IRegistrar
*
pReg
)
{
HINSTANCE
lhInst
=
pM
->
m_hInst
;
/* everything inside this function below this point
* should go into atl71.AtlUpdateRegistryFromResourceD
*/
WCHAR
module_name
[
MAX_PATH
];
TRACE
(
"stub %p (%s), %s, %d, %p, %p
\n
"
,
hInst
,
debugstr_w
(
module_name
),
debugstr_w
(
lpszRes
),
bRegister
,
pMapEntries
,
pReg
);
if
(
pMapEntries
||
pReg
)
{
FIXME
(
"MapEntries and Registrar parameter not supported
\n
"
);
return
E_FAIL
;
}
if
(
!
GetModuleFileNameW
(
lhInst
,
module_name
,
MAX_PATH
))
{
FIXME
(
"%p (%s) did not get module name
\n
"
,
lhInst
,
debugstr_w
(
module_name
));
return
E_FAIL
;
}
return
do_register_dll_server
(
module_name
,
lpszRes
,
bRegister
);
}
/***********************************************************************
/***********************************************************************
* DllRegisterServer (ATL.@)
* DllRegisterServer (ATL.@)
*/
*/
...
...
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