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
93a2de1f
Commit
93a2de1f
authored
Aug 14, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Aug 14, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Moved HTMLLocation reference to inner window.
parent
28f35f86
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
23 deletions
+22
-23
htmllocation.c
dlls/mshtml/htmllocation.c
+9
-9
htmlwindow.c
dlls/mshtml/htmlwindow.c
+9
-10
mshtml_private.h
dlls/mshtml/mshtml_private.h
+4
-4
No files found.
dlls/mshtml/htmllocation.c
View file @
93a2de1f
...
...
@@ -37,20 +37,20 @@ WINE_DEFAULT_DEBUG_CHANNEL(mshtml);
static
HRESULT
get_url
(
HTMLLocation
*
This
,
const
WCHAR
**
ret
)
{
if
(
!
This
->
window
||
!
This
->
window
->
url
)
{
if
(
!
This
->
window
||
!
This
->
window
->
base
.
outer_window
||
!
This
->
window
->
base
.
outer_window
->
url
)
{
FIXME
(
"No current URL
\n
"
);
return
E_NOTIMPL
;
}
*
ret
=
This
->
window
->
url
;
*
ret
=
This
->
window
->
base
.
outer_window
->
url
;
return
S_OK
;
}
static
IUri
*
get_uri
(
HTMLLocation
*
This
)
{
if
(
!
This
->
window
)
if
(
!
This
->
window
||
!
This
->
window
->
base
.
outer_window
)
return
NULL
;
return
This
->
window
->
uri
;
return
This
->
window
->
base
.
outer_window
->
uri
;
}
static
HRESULT
get_url_components
(
HTMLLocation
*
This
,
URL_COMPONENTSW
*
url
)
...
...
@@ -165,12 +165,12 @@ static HRESULT WINAPI HTMLLocation_put_href(IHTMLLocation *iface, BSTR v)
TRACE
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_w
(
v
));
if
(
!
This
->
window
)
{
if
(
!
This
->
window
||
!
This
->
window
->
base
.
outer_window
)
{
FIXME
(
"No window available
\n
"
);
return
E_FAIL
;
}
return
navigate_url
(
This
->
window
,
v
,
This
->
window
->
url
);
return
navigate_url
(
This
->
window
->
base
.
outer_window
,
v
,
This
->
window
->
base
.
outer_
window
->
url
);
}
static
HRESULT
WINAPI
HTMLLocation_get_href
(
IHTMLLocation
*
iface
,
BSTR
*
p
)
...
...
@@ -565,12 +565,12 @@ static HRESULT WINAPI HTMLLocation_replace(IHTMLLocation *iface, BSTR bstr)
TRACE
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_w
(
bstr
));
if
(
!
This
->
window
)
{
if
(
!
This
->
window
||
!
This
->
window
->
base
.
outer_window
)
{
FIXME
(
"No window available
\n
"
);
return
E_FAIL
;
}
return
navigate_url
(
This
->
window
,
bstr
,
This
->
window
->
url
);
return
navigate_url
(
This
->
window
->
base
.
outer_window
,
bstr
,
This
->
window
->
base
.
outer_
window
->
url
);
}
static
HRESULT
WINAPI
HTMLLocation_assign
(
IHTMLLocation
*
iface
,
BSTR
bstr
)
...
...
@@ -629,7 +629,7 @@ static dispex_static_data_t HTMLLocation_dispex = {
};
HRESULT
HTMLLocation_Create
(
HTML
Out
erWindow
*
window
,
HTMLLocation
**
ret
)
HRESULT
HTMLLocation_Create
(
HTML
Inn
erWindow
*
window
,
HTMLLocation
**
ret
)
{
HTMLLocation
*
location
;
...
...
dlls/mshtml/htmlwindow.c
View file @
93a2de1f
...
...
@@ -61,7 +61,7 @@ static void release_children(HTMLOuterWindow *This)
}
}
static
HRESULT
get_location
(
HTML
Out
erWindow
*
This
,
HTMLLocation
**
ret
)
static
HRESULT
get_location
(
HTML
Inn
erWindow
*
This
,
HTMLLocation
**
ret
)
{
if
(
This
->
location
)
{
IHTMLLocation_AddRef
(
&
This
->
location
->
IHTMLLocation_iface
);
...
...
@@ -214,11 +214,6 @@ static void release_outer_window(HTMLOuterWindow *This)
if
(
This
->
frame_element
)
This
->
frame_element
->
content_window
=
NULL
;
if
(
This
->
location
)
{
This
->
location
->
window
=
NULL
;
IHTMLLocation_Release
(
&
This
->
location
->
IHTMLLocation_iface
);
}
This
->
window_ref
->
window
=
NULL
;
windowref_release
(
This
->
window_ref
);
...
...
@@ -250,6 +245,11 @@ static void release_inner_window(HTMLInnerWindow *This)
heap_free
(
This
->
global_props
[
i
].
name
);
heap_free
(
This
->
global_props
);
if
(
This
->
location
)
{
This
->
location
->
window
=
NULL
;
IHTMLLocation_Release
(
&
This
->
location
->
IHTMLLocation_iface
);
}
if
(
This
->
image_factory
)
{
This
->
image_factory
->
window
=
NULL
;
IHTMLImageElementFactory_Release
(
&
This
->
image_factory
->
IHTMLImageElementFactory_iface
);
...
...
@@ -707,7 +707,7 @@ static HRESULT WINAPI HTMLWindow2_get_location(IHTMLWindow2 *iface, IHTMLLocatio
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
hres
=
get_location
(
This
->
out
er_window
,
&
location
);
hres
=
get_location
(
This
->
inn
er_window
,
&
location
);
if
(
FAILED
(
hres
))
return
hres
;
...
...
@@ -2335,7 +2335,7 @@ static HRESULT WINAPI WindowDispEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID
VARIANT
*
pvarRes
,
EXCEPINFO
*
pei
,
IServiceProvider
*
pspCaller
)
{
HTMLWindow
*
This
=
impl_from_IDispatchEx
(
iface
);
HTML
OuterWindow
*
window
=
This
->
out
er_window
;
HTML
InnerWindow
*
window
=
This
->
inn
er_window
;
TRACE
(
"(%p)->(%x %x %x %p %p %p %p)
\n
"
,
This
,
id
,
lcid
,
wFlags
,
pdp
,
pvarRes
,
pei
,
pspCaller
);
...
...
@@ -2355,8 +2355,7 @@ static HRESULT WINAPI WindowDispEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID
return
hres
;
}
return
IDispatchEx_InvokeEx
(
&
window
->
base
.
inner_window
->
dispex
.
IDispatchEx_iface
,
id
,
lcid
,
wFlags
,
pdp
,
pvarRes
,
pei
,
pspCaller
);
return
IDispatchEx_InvokeEx
(
&
window
->
dispex
.
IDispatchEx_iface
,
id
,
lcid
,
wFlags
,
pdp
,
pvarRes
,
pei
,
pspCaller
);
}
static
HRESULT
WINAPI
WindowDispEx_DeleteMemberByName
(
IDispatchEx
*
iface
,
BSTR
bstrName
,
DWORD
grfdex
)
...
...
dlls/mshtml/mshtml_private.h
View file @
93a2de1f
...
...
@@ -323,7 +323,7 @@ struct HTMLLocation {
LONG
ref
;
HTML
Out
erWindow
*
window
;
HTML
Inn
erWindow
*
window
;
};
typedef
struct
{
...
...
@@ -371,8 +371,6 @@ struct HTMLOuterWindow {
IInternetSecurityManager
*
secmgr
;
HTMLLocation
*
location
;
struct
list
children
;
struct
list
sibling_entry
;
struct
list
entry
;
...
...
@@ -400,6 +398,8 @@ struct HTMLInnerWindow {
LONG
task_magic
;
HTMLLocation
*
location
;
IMoniker
*
mon
;
nsChannelBSC
*
bscallback
;
struct
list
bindings
;
...
...
@@ -713,7 +713,7 @@ HTMLOuterWindow *nswindow_to_window(const nsIDOMWindow*) DECLSPEC_HIDDEN;
void
get_top_window
(
HTMLOuterWindow
*
,
HTMLOuterWindow
**
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLOptionElementFactory_Create
(
HTMLInnerWindow
*
,
HTMLOptionElementFactory
**
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLImageElementFactory_Create
(
HTMLInnerWindow
*
,
HTMLImageElementFactory
**
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLLocation_Create
(
HTML
Out
erWindow
*
,
HTMLLocation
**
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLLocation_Create
(
HTML
Inn
erWindow
*
,
HTMLLocation
**
)
DECLSPEC_HIDDEN
;
IOmNavigator
*
OmNavigator_Create
(
void
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLScreen_Create
(
IHTMLScreen
**
)
DECLSPEC_HIDDEN
;
HRESULT
create_history
(
IOmHistory
**
)
DECLSPEC_HIDDEN
;
...
...
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