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
15c7470a
Commit
15c7470a
authored
Aug 30, 2023
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
Aug 31, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Move HTMLPerformanceNavigation related fields to the window.
Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
6dc7c3cd
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
17 deletions
+27
-17
mshtml_private.h
dlls/mshtml/mshtml_private.h
+3
-3
navigate.c
dlls/mshtml/navigate.c
+3
-3
omnavigator.c
dlls/mshtml/omnavigator.c
+21
-11
No files found.
dlls/mshtml/mshtml_private.h
View file @
15c7470a
...
...
@@ -535,9 +535,6 @@ typedef struct {
LONG
ref
;
ULONG
navigation_type
;
ULONG
redirect_count
;
ULONGLONG
navigation_start_time
;
ULONGLONG
unload_event_start_time
;
ULONGLONG
unload_event_end_time
;
...
...
@@ -647,6 +644,9 @@ struct HTMLInnerWindow {
IDispatch
*
mutation_observer_ctor
;
nsChannelBSC
*
bscallback
;
struct
list
bindings
;
ULONG
navigation_type
;
ULONG
redirect_count
;
};
typedef
enum
{
...
...
dlls/mshtml/navigate.c
View file @
15c7470a
...
...
@@ -1351,9 +1351,9 @@ static HRESULT nsChannelBSC_start_binding(BSCallback *bsc)
DWORD
flags
=
This
->
bsc
.
window
->
base
.
outer_window
->
load_flags
;
if
(
flags
&
BINDING_FROMHIST
)
This
->
bsc
.
window
->
performance_timing
->
navigation_type
=
2
;
/* TYPE_BACK_FORWARD */
This
->
bsc
.
window
->
navigation_type
=
2
;
/* TYPE_BACK_FORWARD */
if
(
flags
&
BINDING_REFRESH
)
This
->
bsc
.
window
->
performance_timing
->
navigation_type
=
1
;
/* TYPE_RELOAD */
This
->
bsc
.
window
->
navigation_type
=
1
;
/* TYPE_RELOAD */
This
->
bsc
.
window
->
base
.
outer_window
->
base
.
inner_window
->
doc
->
skip_mutation_notif
=
FALSE
;
This
->
bsc
.
window
->
performance_timing
->
navigation_start_time
=
get_time_stamp
();
...
...
@@ -1726,7 +1726,7 @@ static HRESULT nsChannelBSC_on_progress(BSCallback *bsc, ULONG progress, ULONG t
break
;
case
BINDSTATUS_REDIRECTING
:
if
(
This
->
is_doc_channel
)
{
This
->
bsc
.
window
->
performance_timing
->
redirect_count
++
;
This
->
bsc
.
window
->
redirect_count
++
;
if
(
!
This
->
bsc
.
window
->
performance_timing
->
redirect_time
)
This
->
bsc
.
window
->
performance_timing
->
redirect_time
=
get_time_stamp
();
}
...
...
dlls/mshtml/omnavigator.c
View file @
15c7470a
...
...
@@ -1977,7 +1977,7 @@ typedef struct {
DispatchEx
dispex
;
IHTMLPerformanceNavigation
IHTMLPerformanceNavigation_iface
;
HTML
PerformanceTiming
*
timing
;
HTML
InnerWindow
*
window
;
}
HTMLPerformanceNavigation
;
static
inline
HTMLPerformanceNavigation
*
impl_from_IHTMLPerformanceNavigation
(
IHTMLPerformanceNavigation
*
iface
)
...
...
@@ -2068,7 +2068,7 @@ static HRESULT WINAPI HTMLPerformanceNavigation_get_type(IHTMLPerformanceNavigat
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
*
p
=
This
->
timing
->
navigation_type
;
*
p
=
This
->
window
->
navigation_type
;
return
S_OK
;
}
...
...
@@ -2078,7 +2078,7 @@ static HRESULT WINAPI HTMLPerformanceNavigation_get_redirectCount(IHTMLPerforman
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
*
p
=
This
->
timing
->
redirect_count
;
*
p
=
This
->
window
->
redirect_count
;
return
S_OK
;
}
...
...
@@ -2120,17 +2120,17 @@ static inline HTMLPerformanceNavigation *HTMLPerformanceNavigation_from_Dispatch
static
void
HTMLPerformanceNavigation_traverse
(
DispatchEx
*
dispex
,
nsCycleCollectionTraversalCallback
*
cb
)
{
HTMLPerformanceNavigation
*
This
=
HTMLPerformanceNavigation_from_DispatchEx
(
dispex
);
if
(
This
->
timing
)
note_cc_edge
((
nsISupports
*
)
&
This
->
timing
->
IHTMLPerformanceTiming_iface
,
"timing
"
,
cb
);
if
(
This
->
window
)
note_cc_edge
((
nsISupports
*
)
&
This
->
window
->
base
.
IHTMLWindow2_iface
,
"window
"
,
cb
);
}
static
void
HTMLPerformanceNavigation_unlink
(
DispatchEx
*
dispex
)
{
HTMLPerformanceNavigation
*
This
=
HTMLPerformanceNavigation_from_DispatchEx
(
dispex
);
if
(
This
->
timing
)
{
HTML
PerformanceTiming
*
timing
=
This
->
timing
;
This
->
timing
=
NULL
;
IHTML
PerformanceTiming_Release
(
&
timing
->
IHTMLPerformanceTiming
_iface
);
if
(
This
->
window
)
{
HTML
InnerWindow
*
window
=
This
->
window
;
This
->
window
=
NULL
;
IHTML
Window2_Release
(
&
window
->
base
.
IHTMLWindow2
_iface
);
}
}
...
...
@@ -2161,6 +2161,7 @@ typedef struct {
DispatchEx
dispex
;
IHTMLPerformance
IHTMLPerformance_iface
;
HTMLInnerWindow
*
window
;
IHTMLPerformanceNavigation
*
navigation
;
HTMLPerformanceTiming
*
timing
;
}
HTMLPerformance
;
...
...
@@ -2262,8 +2263,8 @@ static HRESULT WINAPI HTMLPerformance_get_navigation(IHTMLPerformance *iface,
return
E_OUTOFMEMORY
;
navigation
->
IHTMLPerformanceNavigation_iface
.
lpVtbl
=
&
HTMLPerformanceNavigationVtbl
;
navigation
->
timing
=
This
->
timing
;
IHTML
PerformanceTiming_AddRef
(
&
This
->
timing
->
IHTMLPerformanceTiming
_iface
);
navigation
->
window
=
This
->
window
;
IHTML
Window2_AddRef
(
&
This
->
window
->
base
.
IHTMLWindow2
_iface
);
init_dispatch
(
&
navigation
->
dispex
,
(
IUnknown
*
)
&
navigation
->
IHTMLPerformanceNavigation_iface
,
&
HTMLPerformanceNavigation_dispex
,
dispex_compat_mode
(
&
This
->
dispex
));
...
...
@@ -2323,6 +2324,8 @@ static inline HTMLPerformance *HTMLPerformance_from_DispatchEx(DispatchEx *iface
static
void
HTMLPerformance_traverse
(
DispatchEx
*
dispex
,
nsCycleCollectionTraversalCallback
*
cb
)
{
HTMLPerformance
*
This
=
HTMLPerformance_from_DispatchEx
(
dispex
);
if
(
This
->
window
)
note_cc_edge
((
nsISupports
*
)
&
This
->
window
->
base
.
IHTMLWindow2_iface
,
"window"
,
cb
);
if
(
This
->
navigation
)
note_cc_edge
((
nsISupports
*
)
This
->
navigation
,
"navigation"
,
cb
);
if
(
This
->
timing
)
...
...
@@ -2332,6 +2335,11 @@ static void HTMLPerformance_traverse(DispatchEx *dispex, nsCycleCollectionTraver
static
void
HTMLPerformance_unlink
(
DispatchEx
*
dispex
)
{
HTMLPerformance
*
This
=
HTMLPerformance_from_DispatchEx
(
dispex
);
if
(
This
->
window
)
{
HTMLInnerWindow
*
window
=
This
->
window
;
This
->
window
=
NULL
;
IHTMLWindow2_Release
(
&
window
->
base
.
IHTMLWindow2_iface
);
}
unlink_ref
(
&
This
->
navigation
);
if
(
This
->
timing
)
{
HTMLPerformanceTiming
*
timing
=
This
->
timing
;
...
...
@@ -2373,6 +2381,8 @@ HRESULT create_performance(HTMLInnerWindow *window, IHTMLPerformance **ret)
return
E_OUTOFMEMORY
;
performance
->
IHTMLPerformance_iface
.
lpVtbl
=
&
HTMLPerformanceVtbl
;
performance
->
window
=
window
;
IHTMLWindow2_AddRef
(
&
window
->
base
.
IHTMLWindow2_iface
);
init_dispatch
(
&
performance
->
dispex
,
(
IUnknown
*
)
&
performance
->
IHTMLPerformance_iface
,
&
HTMLPerformance_dispex
,
compat_mode
);
...
...
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