Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
904f4ac8
Commit
904f4ac8
authored
Jul 21, 2011
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 21, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added IHTMLStyle::pageBreakBefore implementation.
parent
faa1f737
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
4 deletions
+27
-4
htmlstyle.c
dlls/mshtml/htmlstyle.c
+11
-4
htmlstyle.h
dlls/mshtml/htmlstyle.h
+1
-0
style.c
dlls/mshtml/tests/style.c
+15
-0
No files found.
dlls/mshtml/htmlstyle.c
View file @
904f4ac8
...
...
@@ -145,6 +145,8 @@ static const WCHAR attrPaddingTop[] =
{
'p'
,
'a'
,
'd'
,
'd'
,
'i'
,
'n'
,
'g'
,
'-'
,
't'
,
'o'
,
'p'
,
0
};
static
const
WCHAR
attrPageBreakAfter
[]
=
{
'p'
,
'a'
,
'g'
,
'e'
,
'-'
,
'b'
,
'r'
,
'e'
,
'a'
,
'k'
,
'-'
,
'a'
,
'f'
,
't'
,
'e'
,
'r'
,
0
};
static
const
WCHAR
attrPageBreakBefore
[]
=
{
'p'
,
'a'
,
'g'
,
'e'
,
'-'
,
'b'
,
'r'
,
'e'
,
'a'
,
'k'
,
'-'
,
'b'
,
'e'
,
'f'
,
'o'
,
'r'
,
'e'
,
0
};
static
const
WCHAR
attrPosition
[]
=
{
'p'
,
'o'
,
's'
,
'i'
,
't'
,
'i'
,
'o'
,
'n'
,
0
};
static
const
WCHAR
attrRight
[]
=
...
...
@@ -229,6 +231,7 @@ static const struct{
{
attrPaddingRight
,
DISPID_IHTMLSTYLE_PADDINGRIGHT
},
{
attrPaddingTop
,
DISPID_IHTMLSTYLE_PADDINGTOP
},
{
attrPageBreakAfter
,
DISPID_IHTMLSTYLE_PAGEBREAKAFTER
},
{
attrPageBreakBefore
,
DISPID_IHTMLSTYLE_PAGEBREAKBEFORE
},
{
attrPosition
,
DISPID_IHTMLSTYLE2_POSITION
},
{
attrRight
,
DISPID_IHTMLSTYLE2_RIGHT
},
{
attrTextAlign
,
DISPID_IHTMLSTYLE_TEXTALIGN
},
...
...
@@ -2348,15 +2351,19 @@ static HRESULT WINAPI HTMLStyle_get_overflow(IHTMLStyle *iface, BSTR *p)
static
HRESULT
WINAPI
HTMLStyle_put_pageBreakBefore
(
IHTMLStyle
*
iface
,
BSTR
v
)
{
HTMLStyle
*
This
=
impl_from_IHTMLStyle
(
iface
);
FIXME
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_w
(
v
));
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_w
(
v
));
return
set_nsstyle_attr
(
This
->
nsstyle
,
STYLEID_PAGE_BREAK_BEFORE
,
v
,
0
);
}
static
HRESULT
WINAPI
HTMLStyle_get_pageBreakBefore
(
IHTMLStyle
*
iface
,
BSTR
*
p
)
{
HTMLStyle
*
This
=
impl_from_IHTMLStyle
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
p
);
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
return
get_nsstyle_attr
(
This
->
nsstyle
,
STYLEID_PAGE_BREAK_BEFORE
,
p
,
0
);
}
static
HRESULT
WINAPI
HTMLStyle_put_pageBreakAfter
(
IHTMLStyle
*
iface
,
BSTR
v
)
...
...
dlls/mshtml/htmlstyle.h
View file @
904f4ac8
...
...
@@ -86,6 +86,7 @@ typedef enum {
STYLEID_PADDING_RIGHT
,
STYLEID_PADDING_TOP
,
STYLEID_PAGE_BREAK_AFTER
,
STYLEID_PAGE_BREAK_BEFORE
,
STYLEID_POSITION
,
STYLEID_RIGHT
,
STYLEID_TEXT_ALIGN
,
...
...
dlls/mshtml/tests/style.c
View file @
904f4ac8
...
...
@@ -1653,6 +1653,21 @@ static void test_body_style(IHTMLStyle *style)
ok
(
!
strcmp_wa
(
str
,
"always"
),
"pageBreakAfter = %s
\n
"
,
wine_dbgstr_w
(
str
));
SysFreeString
(
str
);
/* pageBreakBefore */
hres
=
IHTMLStyle_get_pageBreakBefore
(
style
,
&
str
);
ok
(
hres
==
S_OK
,
"get_pageBreakBefore failed: %08x
\n
"
,
hres
);
ok
(
!
str
,
"pageBreakBefore = %s
\n
"
,
wine_dbgstr_w
(
str
));
str
=
a2bstr
(
"always"
);
hres
=
IHTMLStyle_put_pageBreakBefore
(
style
,
str
);
ok
(
hres
==
S_OK
,
"put_pageBreakBefore failed: %08x
\n
"
,
hres
);
SysFreeString
(
str
);
hres
=
IHTMLStyle_get_pageBreakBefore
(
style
,
&
str
);
ok
(
hres
==
S_OK
,
"get_pageBreakBefore failed: %08x
\n
"
,
hres
);
ok
(
!
strcmp_wa
(
str
,
"always"
),
"pageBreakBefore = %s
\n
"
,
wine_dbgstr_w
(
str
));
SysFreeString
(
str
);
hres
=
IHTMLStyle_QueryInterface
(
style
,
&
IID_IHTMLStyle2
,
(
void
**
)
&
style2
);
ok
(
hres
==
S_OK
,
"Could not get IHTMLStyle2 iface: %08x
\n
"
,
hres
);
if
(
SUCCEEDED
(
hres
))
{
...
...
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