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
3d1627f6
Commit
3d1627f6
authored
Jul 31, 2006
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 31, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shdocvw: Added SetExtent and GetExtent implementation.
parent
13557abb
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
81 additions
and
4 deletions
+81
-4
oleobject.c
dlls/shdocvw/oleobject.c
+15
-4
shdocvw.h
dlls/shdocvw/shdocvw.h
+1
-0
webbrowser.c
dlls/shdocvw/tests/webbrowser.c
+65
-0
No files found.
dlls/shdocvw/oleobject.c
View file @
3d1627f6
...
...
@@ -395,15 +395,23 @@ static HRESULT WINAPI OleObject_GetUserType(IOleObject *iface, DWORD dwFormOfTyp
static
HRESULT
WINAPI
OleObject_SetExtent
(
IOleObject
*
iface
,
DWORD
dwDrawAspect
,
SIZEL
*
psizel
)
{
WebBrowser
*
This
=
OLEOBJ_THIS
(
iface
);
FIXME
(
"(%p)->(%lx %p)
\n
"
,
This
,
dwDrawAspect
,
psizel
);
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%lx %p)
\n
"
,
This
,
dwDrawAspect
,
psizel
);
/* Tests show that dwDrawAspect is ignored */
memcpy
(
&
This
->
extent
,
psizel
,
sizeof
(
SIZEL
));
return
S_OK
;
}
static
HRESULT
WINAPI
OleObject_GetExtent
(
IOleObject
*
iface
,
DWORD
dwDrawAspect
,
SIZEL
*
psizel
)
{
WebBrowser
*
This
=
OLEOBJ_THIS
(
iface
);
FIXME
(
"(%p)->(%lx, %p)
\n
"
,
This
,
dwDrawAspect
,
psizel
);
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%lx, %p)
\n
"
,
This
,
dwDrawAspect
,
psizel
);
/* Tests show that dwDrawAspect is ignored */
memcpy
(
psizel
,
&
This
->
extent
,
sizeof
(
SIZEL
));
return
S_OK
;
}
static
HRESULT
WINAPI
OleObject_Advise
(
IOleObject
*
iface
,
IAdviseSink
*
pAdvSink
,
...
...
@@ -808,6 +816,9 @@ void WebBrowser_OleObject_Init(WebBrowser *This)
memset
(
&
This
->
pos_rect
,
0
,
sizeof
(
RECT
));
memset
(
&
This
->
clip_rect
,
0
,
sizeof
(
RECT
));
memset
(
&
This
->
frameinfo
,
0
,
sizeof
(
OLEINPLACEFRAMEINFO
));
This
->
extent
.
cx
=
1323
;
This
->
extent
.
cy
=
529
;
}
void
WebBrowser_OleObject_Destroy
(
WebBrowser
*
This
)
...
...
dlls/shdocvw/shdocvw.h
View file @
3d1627f6
...
...
@@ -119,6 +119,7 @@ typedef struct {
RECT
pos_rect
;
RECT
clip_rect
;
OLEINPLACEFRAMEINFO
frameinfo
;
SIZEL
extent
;
HWND
shell_embedding_hwnd
;
...
...
dlls/shdocvw/tests/webbrowser.c
View file @
3d1627f6
...
...
@@ -828,6 +828,70 @@ static void test_GetControlInfo(IUnknown *unk)
IOleControl_Release
(
control
);
}
static
void
test_Extent
(
IUnknown
*
unk
)
{
IOleObject
*
oleobj
;
SIZE
size
;
HRESULT
hres
;
hres
=
IUnknown_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
ok
(
hres
==
S_OK
,
"Could not get IOleObkect: %08lx
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
DVASPECT_CONTENT
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
1323
&&
size
.
cy
==
529
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
800
;
size
.
cy
=
700
;
hres
=
IOleObject_SetExtent
(
oleobj
,
DVASPECT_CONTENT
,
&
size
);
ok
(
hres
==
S_OK
,
"SetExtent failed: %08lx
\n
"
,
hres
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
DVASPECT_CONTENT
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
800
&&
size
.
cy
==
700
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
0
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
800
&&
size
.
cy
==
700
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
900
;
size
.
cy
=
800
;
hres
=
IOleObject_SetExtent
(
oleobj
,
0
,
&
size
);
ok
(
hres
==
S_OK
,
"SetExtent failed: %08lx
\n
"
,
hres
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
0
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
900
&&
size
.
cy
==
800
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
0xdeadbeef
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
900
&&
size
.
cy
==
800
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
1000
;
size
.
cy
=
900
;
hres
=
IOleObject_SetExtent
(
oleobj
,
0xdeadbeef
,
&
size
);
ok
(
hres
==
S_OK
,
"SetExtent failed: %08lx
\n
"
,
hres
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
0xdeadbeef
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
1000
&&
size
.
cy
==
900
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
size
.
cx
=
size
.
cy
=
0xdeadbeef
;
hres
=
IOleObject_GetExtent
(
oleobj
,
DVASPECT_CONTENT
,
&
size
);
ok
(
hres
==
S_OK
,
"GetExtent failed: %08lx
\n
"
,
hres
);
ok
(
size
.
cx
==
1000
&&
size
.
cy
==
900
,
"size = {%ld %ld}
\n
"
,
size
.
cx
,
size
.
cy
);
IOleObject_Release
(
oleobj
);
}
static
void
test_WebBrowser
(
void
)
{
IUnknown
*
unk
=
NULL
;
...
...
@@ -842,6 +906,7 @@ static void test_WebBrowser(void)
test_ClassInfo
(
unk
);
test_ClientSite
(
unk
,
&
ClientSite
);
test_Extent
(
unk
);
test_DoVerb
(
unk
);
test_ClientSite
(
unk
,
NULL
);
test_ie_funcs
(
unk
);
...
...
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