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
0947bc78
Commit
0947bc78
authored
Jul 30, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 30, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ieframe/tests: Use proper helpers for iface calls.
parent
4ffcf335
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
19 deletions
+20
-19
intshcut.c
dlls/ieframe/tests/intshcut.c
+1
-1
webbrowser.c
dlls/ieframe/tests/webbrowser.c
+19
-18
No files found.
dlls/ieframe/tests/intshcut.c
View file @
0947bc78
...
...
@@ -143,7 +143,7 @@ static void _test_shortcut_url(unsigned line, IUnknown *unk, const char *exurl)
ok_
(
__FILE__
,
line
)(
!
strcmp
(
url_a
,
exurl
),
"unexpected URL, got %s, expected %s
\n
"
,
url_a
,
exurl
);
CoTaskMemFree
(
url_a
);
IUnknown_Release
(
locator_a
);
IUnknown_Release
(
(
IUnknown
*
)
locator_a
);
}
#define check_string_transform(a,b,c,d,e) _check_string_transform(__LINE__,a,b,c,d,e)
...
...
dlls/ieframe/tests/webbrowser.c
View file @
0947bc78
...
...
@@ -288,7 +288,7 @@ static IDispatch *_get_document(unsigned line, IWebBrowser2 *wb)
hres
=
IDispatch_QueryInterface
(
disp
,
&
IID_IHTMLDocument2
,
(
void
**
)
&
html_doc
);
ok_
(
__FILE__
,
line
)(
hres
==
S_OK
,
"Could not get IHTMLDocument iface: %08x
\n
"
,
hres
);
ok
(
disp
==
(
IDispatch
*
)
html_doc
,
"disp != html_doc
\n
"
);
IHTMLDocument_Release
(
html_doc
);
IHTMLDocument
2
_Release
(
html_doc
);
return
disp
;
}
...
...
@@ -1750,7 +1750,7 @@ static void test_DoVerb(IWebBrowser2 *unk)
RECT
rect
=
{
0
,
0
,
1000
,
1000
};
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_OleObject) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -1798,7 +1798,7 @@ static void call_DoVerb(IWebBrowser2 *unk, LONG verb)
RECT
rect
=
{
60
,
60
,
600
,
600
};
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_OleObject) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -1816,7 +1816,7 @@ static HWND get_hwnd(IWebBrowser2 *unk)
HWND
hwnd
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleInPlaceObject
,
(
void
**
)
&
inplace
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleInPlaceObject
,
(
void
**
)
&
inplace
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_OleInPlaceObject) failed: %08x
\n
"
,
hres
);
hres
=
IOleInPlaceObject_GetWindow
(
inplace
,
&
hwnd
);
...
...
@@ -1859,7 +1859,7 @@ static void test_ClientSite(IWebBrowser2 *unk, IOleClientSite *client, BOOL stop
HWND
hwnd
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_OleObject) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -1867,7 +1867,7 @@ static void test_ClientSite(IWebBrowser2 *unk, IOleClientSite *client, BOOL stop
test_GetMiscStatus
(
oleobj
);
test_SetHostNames
(
oleobj
);
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleInPlaceObject
,
(
void
**
)
&
inplace
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleInPlaceObject
,
(
void
**
)
&
inplace
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_OleInPlaceObject) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
{
IOleObject_Release
(
oleobj
);
...
...
@@ -1929,7 +1929,7 @@ static void test_ClassInfo(IWebBrowser2 *unk)
GUID
guid
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IProvideClassInfo2
,
(
void
**
)
&
class_info
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IProvideClassInfo2
,
(
void
**
)
&
class_info
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_IProvideClassInfo) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2394,7 +2394,7 @@ static void test_wb_funcs(IWebBrowser2 *wb, BOOL is_clientsite)
IOleControl
*
control
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
wb
,
&
IID_IOleControl
,
(
void
**
)
&
control
);
hres
=
I
WebBrowser2
_QueryInterface
(
wb
,
&
IID_IOleControl
,
(
void
**
)
&
control
);
ok
(
hres
==
S_OK
,
"Could not get IOleControl interface: %08x
\n
"
,
hres
);
test_Silent
(
wb
,
control
,
is_clientsite
);
...
...
@@ -2410,7 +2410,7 @@ static void test_GetControlInfo(IWebBrowser2 *unk)
CONTROLINFO
info
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleControl
,
(
void
**
)
&
control
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleControl
,
(
void
**
)
&
control
);
ok
(
hres
==
S_OK
,
"Could not get IOleControl: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2440,7 +2440,7 @@ static void test_Extent(IWebBrowser2 *unk)
if
(
dpi_x
!=
96
||
dpi_y
!=
96
)
trace
(
"dpi: %d / %d
\n
"
,
dpi_y
,
dpi_y
);
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleObject
,
(
void
**
)
&
oleobj
);
ok
(
hres
==
S_OK
,
"Could not get IOleObkect: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2510,7 +2510,7 @@ static void test_ConnectionPoint(IWebBrowser2 *unk, BOOL init)
static
DWORD
dw
=
100
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IConnectionPointContainer
,
(
void
**
)
&
container
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IConnectionPointContainer
,
(
void
**
)
&
container
);
ok
(
hres
==
S_OK
,
"QueryInterface(IID_IConnectionPointContainer) failed: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2801,7 +2801,7 @@ static void test_olecmd(IWebBrowser2 *unk, BOOL loaded)
OLECMD
cmds
[
3
];
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleCommandTarget
,
(
void
**
)
&
cmdtrg
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleCommandTarget
,
(
void
**
)
&
cmdtrg
);
ok
(
hres
==
S_OK
,
"Could not get IOleCommandTarget iface: %08x
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2831,7 +2831,7 @@ static void test_IServiceProvider(IWebBrowser2 *unk)
IUnknown
*
iface
;
HRESULT
hres
;
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IServiceProvider
,
(
void
**
)
&
servprov
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IServiceProvider
,
(
void
**
)
&
servprov
);
ok
(
hres
==
S_OK
,
"QueryInterface returned %08x, expected S_OK
\n
"
,
hres
);
if
(
FAILED
(
hres
))
return
;
...
...
@@ -2909,7 +2909,7 @@ static void test_go_back(IWebBrowser2 *wb, const char *back_url)
todo_wine
CHECK_CALLED
(
Invoke_COMMANDSTATECHANGE
);
}
static
void
test_QueryInterface
(
IWebBrowser2
*
unk
)
static
void
test_QueryInterface
(
IWebBrowser2
*
wb
)
{
IQuickActivate
*
qa
=
(
IQuickActivate
*
)
0xdeadbeef
;
IRunnableObject
*
runnable
=
(
IRunnableObject
*
)
0xdeadbeef
;
...
...
@@ -2921,6 +2921,7 @@ static void test_QueryInterface(IWebBrowser2 *unk)
IOleLink
*
link
=
(
void
*
)
0xdeadbeef
;
IMarshal
*
marshal
=
(
void
*
)
0xdeadbeef
;
IStdMarshalInfo
*
marshalinfo
=
(
void
*
)
0xdeadbeef
;
IUnknown
*
unk
=
(
IUnknown
*
)
wb
;
HRESULT
hres
;
hres
=
IUnknown_QueryInterface
(
unk
,
&
IID_IQuickActivate
,
(
void
**
)
&
qa
);
...
...
@@ -3054,7 +3055,7 @@ static void test_TranslateAccelerator(IWebBrowser2 *unk)
test_Navigate2
(
unk
,
"about:blank"
);
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleInPlaceActiveObject
,
(
void
**
)
&
pao
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleInPlaceActiveObject
,
(
void
**
)
&
pao
);
ok
(
hres
==
S_OK
,
"Got 0x%08x
\n
"
,
hres
);
if
(
SUCCEEDED
(
hres
))
{
/* One accelerator that should be handled by mshtml */
...
...
@@ -3075,7 +3076,7 @@ static void test_TranslateAccelerator(IWebBrowser2 *unk)
test_UIActivate
(
unk
,
TRUE
);
/* Test again after UIActivate */
hres
=
I
Unknown
_QueryInterface
(
unk
,
&
IID_IOleInPlaceActiveObject
,
(
void
**
)
&
pao
);
hres
=
I
WebBrowser2
_QueryInterface
(
unk
,
&
IID_IOleInPlaceActiveObject
,
(
void
**
)
&
pao
);
ok
(
hres
==
S_OK
,
"Got 0x%08x
\n
"
,
hres
);
if
(
SUCCEEDED
(
hres
))
{
/* One accelerator that should be handled by mshtml */
...
...
@@ -3125,14 +3126,14 @@ static void test_TranslateAccelerator(IWebBrowser2 *unk)
for
(
keycode
=
0
;
keycode
<=
0x100
;
keycode
++
)
{
msg_a
.
wParam
=
keycode
;
SET_EXPECT
(
DocHost_TranslateAccelerator
);
hres
=
IDocHostUIHandler_TranslateAccelerator
(
dochost
,
&
msg_a
,
&
CGID_MSHTML
,
1234
);
hres
=
IDocHostUIHandler
2
_TranslateAccelerator
(
dochost
,
&
msg_a
,
&
CGID_MSHTML
,
1234
);
ok
(
hres
==
0xdeadbeef
,
"Got 0x%08x
\n
"
,
hres
);
CHECK_CALLED
(
DocHost_TranslateAccelerator
);
}
hr_dochost_TranslateAccelerator
=
E_NOTIMPL
;
SET_EXPECT
(
DocHost_TranslateAccelerator
);
hres
=
IDocHostUIHandler_TranslateAccelerator
(
dochost
,
&
msg_a
,
&
CGID_MSHTML
,
1234
);
hres
=
IDocHostUIHandler
2
_TranslateAccelerator
(
dochost
,
&
msg_a
,
&
CGID_MSHTML
,
1234
);
ok
(
hres
==
E_NOTIMPL
,
"Got 0x%08x
\n
"
,
hres
);
CHECK_CALLED
(
DocHost_TranslateAccelerator
);
...
...
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