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
13d899ec
Commit
13d899ec
authored
Jan 23, 2015
by
Jacek Caban
Committed by
Alexandre Julliard
Jan 23, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added Exec(OLECMDID_OPTICAL_ZOOM) implementation.
parent
971cf700
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
36 additions
and
24 deletions
+36
-24
mshtml_private.h
dlls/mshtml/mshtml_private.h
+2
-1
nsembed.c
dlls/mshtml/nsembed.c
+22
-0
olecmd.c
dlls/mshtml/olecmd.c
+9
-2
oleobj.c
dlls/mshtml/oleobj.c
+2
-20
htmldoc.c
dlls/mshtml/tests/htmldoc.c
+1
-1
No files found.
dlls/mshtml/mshtml_private.h
View file @
13d899ec
...
...
@@ -818,8 +818,9 @@ void register_nsservice(nsIComponentRegistrar*,nsIServiceManager*) DECLSPEC_HIDD
void
init_nsio
(
nsIComponentManager
*
,
nsIComponentRegistrar
*
)
DECLSPEC_HIDDEN
;
void
release_nsio
(
void
)
DECLSPEC_HIDDEN
;
BOOL
is_gecko_path
(
const
char
*
)
DECLSPEC_HIDDEN
;
void
set_viewer_zoom
(
NSContainer
*
,
float
)
DECLSPEC_HIDDEN
;
void
init_node_cc
(
void
);
void
init_node_cc
(
void
)
DECLSPEC_HIDDEN
;
HRESULT
nsuri_to_url
(
LPCWSTR
,
BOOL
,
BSTR
*
)
DECLSPEC_HIDDEN
;
...
...
dlls/mshtml/nsembed.c
View file @
13d899ec
...
...
@@ -1149,6 +1149,28 @@ BOOL is_gecko_path(const char *path)
return
ret
;
}
void
set_viewer_zoom
(
NSContainer
*
nscontainer
,
float
factor
)
{
nsIContentViewer
*
content_viewer
;
nsIDocShell
*
doc_shell
;
nsresult
nsres
;
TRACE
(
"Setting to %f
\n
"
,
factor
);
nsres
=
get_nsinterface
((
nsISupports
*
)
nscontainer
->
navigation
,
&
IID_nsIDocShell
,
(
void
**
)
&
doc_shell
);
assert
(
nsres
==
NS_OK
);
nsres
=
nsIDocShell_GetContentViewer
(
doc_shell
,
&
content_viewer
);
assert
(
nsres
==
NS_OK
&&
content_viewer
);
nsIDocShell_Release
(
doc_shell
);
nsres
=
nsIContentViewer_SetFullZoom
(
content_viewer
,
factor
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"SetFullZoom failed: %08x
\n
"
,
nsres
);
nsIContentViewer_Release
(
content_viewer
);
}
struct
nsWeakReference
{
nsIWeakReference
nsIWeakReference_iface
;
...
...
dlls/mshtml/olecmd.c
View file @
13d899ec
...
...
@@ -548,8 +548,15 @@ static HRESULT exec_get_print_template(HTMLDocument *This, DWORD nCmdexecopt, VA
static
HRESULT
exec_optical_zoom
(
HTMLDocument
*
This
,
DWORD
nCmdexecopt
,
VARIANT
*
pvaIn
,
VARIANT
*
pvaOut
)
{
FIXME
(
"(%p)->(%d %p %p)
\n
"
,
This
,
nCmdexecopt
,
pvaIn
,
pvaOut
);
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%d %s %p)
\n
"
,
This
,
nCmdexecopt
,
debugstr_variant
(
pvaIn
),
pvaOut
);
if
(
!
pvaIn
||
V_VT
(
pvaIn
)
!=
VT_I4
)
{
FIXME
(
"Unsupported argument %s
\n
"
,
debugstr_variant
(
pvaIn
));
return
E_NOTIMPL
;
}
set_viewer_zoom
(
This
->
doc_obj
->
nscontainer
,
(
float
)
V_I4
(
pvaIn
)
/
100
);
return
S_OK
;
}
static
HRESULT
query_mshtml_copy
(
HTMLDocument
*
This
,
OLECMD
*
cmd
)
...
...
dlls/mshtml/oleobj.c
View file @
13d899ec
...
...
@@ -229,12 +229,9 @@ void set_document_navigation(HTMLDocumentObj *doc, BOOL doc_can_navigate)
static
void
load_settings
(
HTMLDocumentObj
*
doc
)
{
nsIContentViewer
*
content_viewer
;
nsIDocShell
*
doc_shell
;
HKEY
settings_key
;
DWORD
val
,
size
;
LONG
res
;
nsresult
nsres
;
static
const
WCHAR
ie_keyW
[]
=
{
'S'
,
'O'
,
'F'
,
'T'
,
'W'
,
'A'
,
'R'
,
'E'
,
'\\'
,
...
...
@@ -250,23 +247,8 @@ static void load_settings(HTMLDocumentObj *doc)
size
=
sizeof
(
val
);
res
=
RegGetValueW
(
settings_key
,
zoomW
,
zoom_factorW
,
RRF_RT_REG_DWORD
,
NULL
,
&
val
,
&
size
);
RegCloseKey
(
settings_key
);
if
(
res
!=
ERROR_SUCCESS
)
return
;
TRACE
(
"Setting ZoomFactor to %u
\n
"
,
val
);
nsres
=
get_nsinterface
((
nsISupports
*
)
doc
->
nscontainer
->
navigation
,
&
IID_nsIDocShell
,
(
void
**
)
&
doc_shell
);
assert
(
nsres
==
NS_OK
);
nsres
=
nsIDocShell_GetContentViewer
(
doc_shell
,
&
content_viewer
);
assert
(
nsres
==
NS_OK
&&
content_viewer
);
nsIDocShell_Release
(
doc_shell
);
nsres
=
nsIContentViewer_SetFullZoom
(
content_viewer
,
(
float
)
val
/
100000
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"SetFullZoom failed: %08x
\n
"
,
nsres
);
nsIContentViewer_Release
(
content_viewer
);
if
(
res
==
ERROR_SUCCESS
)
set_viewer_zoom
(
doc
->
nscontainer
,
(
float
)
val
/
100000
);
}
static
HRESULT
WINAPI
OleObject_SetClientSite
(
IOleObject
*
iface
,
IOleClientSite
*
pClientSite
)
...
...
dlls/mshtml/tests/htmldoc.c
View file @
13d899ec
...
...
@@ -6641,7 +6641,7 @@ static void test_exec_optical_zoom(IHTMLDocument2 *doc, int factor)
SET_EXPECT
(
GetOverrideKeyPath
);
hres
=
IOleCommandTarget_Exec
(
cmdtrg
,
NULL
,
OLECMDID_OPTICAL_ZOOM
,
OLECMDEXECOPT_DODEFAULT
,
&
v
,
NULL
);
todo_wine
ok
(
hres
==
S_OK
||
broken
(
hres
==
OLECMDERR_E_NOTSUPPORTED
)
/* IE6 */
,
"Exec failed: %08x
\n
"
,
hres
);
ok
(
hres
==
S_OK
||
broken
(
hres
==
OLECMDERR_E_NOTSUPPORTED
)
/* IE6 */
,
"Exec failed: %08x
\n
"
,
hres
);
CLEAR_CALLED
(
GetOverrideKeyPath
);
IOleCommandTarget_Release
(
cmdtrg
);
...
...
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