Skip to content
Permalink
Browse files
[BlackBerry] Update BB10 form theme.
https://bugs.webkit.org/show_bug.cgi?id=100760

Patch by Tiancheng Jiang <tijiang@rim.com> on 2012-11-14
Reviewed by Rob Buis.

RIM PR 225755
Internally Reviewed by Eli Fidler.
Update checkbox, radio and menulist button style. Adjust border width
and line height.

* platform/blackberry/RenderThemeBlackBerry.cpp:
(WebCore::RenderThemeBlackBerry::adjustMenuListButtonStyle):
* platform/blackberry/RenderThemeBlackBerry.h:
(RenderThemeBlackBerry):

Canonical link: https://commits.webkit.org/120436@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@134724 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
Tiancheng Jiang authored and webkit-commit-queue committed Nov 15, 2012
1 parent 5779090 commit f7cae066d870bb14751e013a17e868b7fd2c59fa
Showing 3 changed files with 19 additions and 23 deletions.
@@ -1,3 +1,20 @@
2012-11-14 Tiancheng Jiang <tijiang@rim.com>

[BlackBerry] Update BB10 form theme.
https://bugs.webkit.org/show_bug.cgi?id=100760

Reviewed by Rob Buis.

RIM PR 225755
Internally Reviewed by Eli Fidler.
Update checkbox, radio and menulist button style. Adjust border width
and line height.

* platform/blackberry/RenderThemeBlackBerry.cpp:
(WebCore::RenderThemeBlackBerry::adjustMenuListButtonStyle):
* platform/blackberry/RenderThemeBlackBerry.h:
(RenderThemeBlackBerry):

2012-11-14 Erik Arvidsson <arv@chromium.org>

Update DOMException name: InvalidModificationError
@@ -461,7 +461,8 @@ void RenderThemeBlackBerry::adjustMenuListButtonStyle(StyleResolver*, RenderStyl
const int minHeight = style->fontSize() * 2;

style->resetPadding();
style->setHeight(Length(Auto));
style->setMinHeight(Length(minHeight, Fixed));
style->setLineHeight(RenderStyle::initialLineHeight());

style->setPaddingRight(Length(minHeight + paddingRight, Fixed));
style->setPaddingLeft(Length(paddingLeft, Fixed));
@@ -629,26 +630,6 @@ void RenderThemeBlackBerry::adjustMenuListStyle(StyleResolver* css, RenderStyle*
adjustMenuListButtonStyle(css, style, element);
}

void RenderThemeBlackBerry::adjustCheckboxStyle(StyleResolver*, RenderStyle* style, Element*) const
{
setCheckboxSize(style);
style->setBoxShadow(nullptr);
Length margin(marginSize, Fixed);
style->setMarginBottom(margin);
style->setMarginRight(margin);
style->setCursor(CURSOR_WEBKIT_GRAB);
}

void RenderThemeBlackBerry::adjustRadioStyle(StyleResolver*, RenderStyle* style, Element*) const
{
setRadioSize(style);
style->setBoxShadow(nullptr);
Length margin(marginSize, Fixed);
style->setMarginBottom(margin);
style->setMarginRight(margin);
style->setCursor(CURSOR_WEBKIT_GRAB);
}

static IntRect computeMenuListArrowButtonRect(const IntRect& rect)
{
// FIXME: The menu list arrow button should have a minimum and maximum width (to ensure usability) or
@@ -71,8 +71,6 @@ class RenderThemeBlackBerry : public RenderTheme {
virtual bool paintSearchFieldCancelButton(RenderObject*, const PaintInfo&, const IntRect&);

virtual void adjustMenuListButtonStyle(StyleResolver*, RenderStyle*, Element*) const;
virtual void adjustCheckboxStyle(StyleResolver*, RenderStyle*, Element*) const;
virtual void adjustRadioStyle(StyleResolver*, RenderStyle*, Element*) const;
virtual bool paintMenuList(RenderObject*, const PaintInfo&, const IntRect&);

virtual void adjustMediaControlStyle(StyleResolver*, RenderStyle*, Element*) const;

0 comments on commit f7cae06

Please sign in to comment.