Commit 7fd972a6 authored by adele's avatar adele

Reviewed by Darin.

        Windows theme for textareas.  Also made some formatting changes. 

        * rendering/RenderThemeWin.cpp:
        (WebCore::RenderThemeWin::supportsFocus):
        (WebCore::RenderThemeWin::getThemeData):
        (WebCore::RenderThemeWin::adjustButtonStyle):
        (WebCore::RenderThemeWin::adjustTextFieldStyle):
        (WebCore::RenderThemeWin::adjustTextAreaStyle):
        (WebCore::RenderThemeWin::paintTextArea):
        * rendering/RenderThemeWin.h:
        (WebCore::RenderThemeWin::supportsHover):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@14704 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 83434681
2006-06-02 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Windows theme for textareas. Also made some formatting changes.
* rendering/RenderThemeWin.cpp:
(WebCore::RenderThemeWin::supportsFocus):
(WebCore::RenderThemeWin::getThemeData):
(WebCore::RenderThemeWin::adjustButtonStyle):
(WebCore::RenderThemeWin::adjustTextFieldStyle):
(WebCore::RenderThemeWin::adjustTextAreaStyle):
(WebCore::RenderThemeWin::paintTextArea):
* rendering/RenderThemeWin.h:
(WebCore::RenderThemeWin::supportsHover):
2006-06-02 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
Reviewed by Hyatt, checked in by Tim H.
......
......@@ -153,6 +153,7 @@ bool RenderThemeWin::supportsFocus(EAppearance appearance)
case PushButtonAppearance:
case ButtonAppearance:
case TextFieldAppearance:
case TextAreaAppearance:
return true;
default:
return false;
......@@ -197,6 +198,7 @@ ThemeData RenderThemeWin::getThemeData(RenderObject* o)
result.m_state = determineState(o);
break;
case TextFieldAppearance:
case TextAreaAppearance:
result.m_part = TFP_TEXTFIELD;
result.m_state = determineState(o);
break;
......@@ -205,7 +207,7 @@ ThemeData RenderThemeWin::getThemeData(RenderObject* o)
return result;
}
void RenderThemeWin::adjustButtonStyle(CSSStyleSelector* selector, RenderStyle* style, WebCore::Element* e) const
void RenderThemeWin::adjustButtonStyle(CSSStyleSelector*, RenderStyle* style, Element*) const
{
addIntrinsicMargins(style);
}
......@@ -292,7 +294,7 @@ void RenderThemeWin::setRadioSize(RenderStyle* style) const
setCheckboxSize(style);
}
void RenderThemeWin::adjustTextFieldStyle(CSSStyleSelector* selector, RenderStyle* style, WebCore::Element* e) const
void RenderThemeWin::adjustTextFieldStyle(CSSStyleSelector*, RenderStyle* style, Element*) const
{
addIntrinsicMargins(style);
}
......@@ -322,4 +324,14 @@ bool RenderThemeWin::paintTextField(RenderObject* o, const RenderObject::PaintIn
return false;
}
void RenderThemeWin::adjustTextAreaStyle(CSSStyleSelector*, RenderStyle* style, Element*) const
{
addIntrinsicMargins(style);
}
bool RenderThemeWin::paintTextArea(RenderObject* o, const RenderObject::PaintInfo& i, const IntRect& r)
{
return paintTextField(o, i, r);
}
}
......@@ -46,30 +46,33 @@ public:
~RenderThemeWin();
// A method asking if the theme's controls actually care about redrawing when hovered.
virtual bool supportsHover(const RenderStyle* style) const { return true; }
virtual bool supportsHover(const RenderStyle*) const { return true; }
virtual bool paintCheckbox(RenderObject* o, const RenderObject::PaintInfo& i, const IntRect& r)
{ return paintButton(o, i, r); }
virtual void setCheckboxSize(RenderStyle* style) const;
virtual void setCheckboxSize(RenderStyle*) const;
virtual bool paintRadio(RenderObject* o, const RenderObject::PaintInfo& i, const IntRect& r)
{ return paintButton(o, i, r); }
virtual void setRadioSize(RenderStyle* style) const;
virtual void setRadioSize(RenderStyle*) const;
virtual void adjustButtonStyle(CSSStyleSelector* selector, RenderStyle* style, WebCore::Element* e) const;
virtual bool paintButton(RenderObject* o, const RenderObject::PaintInfo& i, const IntRect& r);
virtual void adjustButtonStyle(CSSStyleSelector*, RenderStyle*, Element*) const;
virtual bool paintButton(RenderObject*, const RenderObject::PaintInfo&, const IntRect&);
virtual void adjustTextFieldStyle(CSSStyleSelector* selector, RenderStyle* style, WebCore::Element* e) const;
virtual bool paintTextField(RenderObject* o, const RenderObject::PaintInfo& i, const IntRect& r);
virtual void adjustTextFieldStyle(CSSStyleSelector*, RenderStyle*, Element*) const;
virtual bool paintTextField(RenderObject*, const RenderObject::PaintInfo&, const IntRect&);
virtual void adjustTextAreaStyle(CSSStyleSelector*, RenderStyle*, WebCore::Element*) const;
virtual bool paintTextArea(RenderObject*, const RenderObject::PaintInfo&, const IntRect&);
private:
void addIntrinsicMargins(RenderStyle* style) const;
void addIntrinsicMargins(RenderStyle*) const;
void close();
unsigned determineState(RenderObject* o);
bool supportsFocus(EAppearance appearance);
unsigned determineState(RenderObject*);
bool supportsFocus(EAppearance);
ThemeData getThemeData(RenderObject* o);
ThemeData getThemeData(RenderObject*);
HMODULE m_themeDLL;
mutable HANDLE m_buttonTheme;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment