Diff
Modified: trunk/Source/WebCore/ChangeLog (155418 => 155419)
--- trunk/Source/WebCore/ChangeLog 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/ChangeLog 2013-09-10 06:07:40 UTC (rev 155419)
@@ -1,5 +1,18 @@
2013-09-09 Andreas Kling <[email protected]>
+ HTMLTextAreaElement no longer needs custom style resolve callbacks.
+ <https://webkit.org/b/121073>
+
+ Reviewed by Ryosuke Niwa.
+
+ After r155408 HTMLTextAreaElement doesn't override didAttachRenderer() anymore,
+ so we don't need to fire callbacks on textarea elements during style resolve.
+
+ * html/HTMLTextAreaElement.cpp:
+ (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
+
+2013-09-09 Andreas Kling <[email protected]>
+
ScriptController should have a Frame& internally.
<https://webkit.org/b/121071>
Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.cpp (155418 => 155419)
--- trunk/Source/WebCore/html/HTMLTextAreaElement.cpp 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.cpp 2013-09-10 06:07:40 UTC (rev 155419)
@@ -98,7 +98,6 @@
{
ASSERT(hasTagName(textareaTag));
setFormControlValueMatchesRenderer(true);
- setHasCustomStyleResolveCallbacks();
}
PassRefPtr<HTMLTextAreaElement> HTMLTextAreaElement::create(const QualifiedName& tagName, Document* document, HTMLFormElement* form)
Modified: trunk/Source/WebCore/page/Frame.cpp (155418 => 155419)
--- trunk/Source/WebCore/page/Frame.cpp 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/page/Frame.cpp 2013-09-10 06:07:40 UTC (rev 155419)
@@ -161,7 +161,7 @@
, m_editor(Editor::create(*this))
, m_selection(adoptPtr(new FrameSelection(this)))
, m_eventHandler(adoptPtr(new EventHandler(*this)))
- , m_animationController(adoptPtr(new AnimationController(this)))
+ , m_animationController(createOwned<AnimationController>(*this)))
, m_pageZoomFactor(parentPageZoomFactor(this))
, m_textZoomFactor(parentTextZoomFactor(this))
#if ENABLE(ORIENTATION_EVENTS)
Modified: trunk/Source/WebCore/page/animation/AnimationController.cpp (155418 => 155419)
--- trunk/Source/WebCore/page/animation/AnimationController.cpp 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/page/animation/AnimationController.cpp 2013-09-10 06:07:40 UTC (rev 155419)
@@ -50,7 +50,7 @@
static const double cAnimationTimerDelay = 0.025;
static const double cBeginAnimationUpdateTimeNotSet = -1;
-AnimationControllerPrivate::AnimationControllerPrivate(Frame* frame)
+AnimationControllerPrivate::AnimationControllerPrivate(Frame& frame)
: m_animationTimer(this, &AnimationControllerPrivate::animationTimerFired)
, m_updateStyleIfNeededDispatcher(this, &AnimationControllerPrivate::updateStyleIfNeededDispatcherFired)
, m_frame(frame)
@@ -112,7 +112,7 @@
}
if (calledSetChanged)
- m_frame->document()->updateStyleIfNeeded();
+ m_frame.document()->updateStyleIfNeeded();
return timeToNextService;
}
@@ -163,7 +163,7 @@
void AnimationControllerPrivate::fireEventsAndUpdateStyle()
{
// Protect the frame from getting destroyed in the event handler
- RefPtr<Frame> protector = m_frame;
+ Ref<Frame> protector(m_frame);
bool updateStyle = !m_eventsToDispatch.isEmpty() || !m_nodeChangesToDispatch.isEmpty();
@@ -186,8 +186,8 @@
m_nodeChangesToDispatch.clear();
- if (updateStyle && m_frame)
- m_frame->document()->updateStyleIfNeeded();
+ if (updateStyle)
+ m_frame.document()->updateStyleIfNeeded();
}
void AnimationControllerPrivate::startUpdateStyleIfNeededDispatcher()
@@ -224,7 +224,7 @@
double timeToNextService = updateAnimations(CallSetChanged);
if (timeToNextService >= 0)
- m_frame->document()->view()->scheduleAnimation();
+ m_frame.document()->view()->scheduleAnimation();
}
#endif
@@ -266,10 +266,10 @@
if (isSuspended())
return;
- suspendAnimationsForDocument(m_frame->document());
+ suspendAnimationsForDocument(m_frame.document());
// Traverse subframes
- for (Frame* child = m_frame->tree().firstChild(); child; child = child->tree().nextSibling())
+ for (Frame* child = m_frame.tree().firstChild(); child; child = child->tree().nextSibling())
child->animation().suspendAnimations();
m_isSuspended = true;
@@ -280,10 +280,10 @@
if (!isSuspended())
return;
- resumeAnimationsForDocument(m_frame->document());
+ resumeAnimationsForDocument(m_frame.document());
// Traverse subframes
- for (Frame* child = m_frame->tree().firstChild(); child; child = child->tree().nextSibling())
+ for (Frame* child = m_frame.tree().firstChild(); child; child = child->tree().nextSibling())
child->animation().resumeAnimations();
m_isSuspended = false;
@@ -490,8 +490,8 @@
removeFromAnimationsWaitingForStartTimeResponse(animation);
}
-AnimationController::AnimationController(Frame* frame)
- : m_data(adoptPtr(new AnimationControllerPrivate(frame)))
+AnimationController::AnimationController(Frame& frame)
+ : m_data(createOwned<AnimationControllerPrivate>(frame)))
, m_beginAnimationUpdateCount(0)
{
}
Modified: trunk/Source/WebCore/page/animation/AnimationController.h (155418 => 155419)
--- trunk/Source/WebCore/page/animation/AnimationController.h 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/page/animation/AnimationController.h 2013-09-10 06:07:40 UTC (rev 155419)
@@ -46,7 +46,7 @@
class AnimationController {
public:
- AnimationController(Frame*);
+ explicit AnimationController(Frame&);
~AnimationController();
void cancelAnimations(RenderObject*);
@@ -83,7 +83,7 @@
static bool supportsAcceleratedAnimationOfProperty(CSSPropertyID);
private:
- OwnPtr<AnimationControllerPrivate> m_data;
+ const OwnPtr<AnimationControllerPrivate> m_data;
int m_beginAnimationUpdateCount;
};
Modified: trunk/Source/WebCore/page/animation/AnimationControllerPrivate.h (155418 => 155419)
--- trunk/Source/WebCore/page/animation/AnimationControllerPrivate.h 2013-09-10 06:01:03 UTC (rev 155418)
+++ trunk/Source/WebCore/page/animation/AnimationControllerPrivate.h 2013-09-10 06:07:40 UTC (rev 155419)
@@ -58,7 +58,7 @@
class AnimationControllerPrivate {
WTF_MAKE_NONCOPYABLE(AnimationControllerPrivate); WTF_MAKE_FAST_ALLOCATED;
public:
- AnimationControllerPrivate(Frame*);
+ explicit AnimationControllerPrivate(Frame&);
~AnimationControllerPrivate();
// Returns the time until the next animation needs to be serviced, or -1 if there are none.
@@ -125,7 +125,7 @@
RenderObjectAnimationMap m_compositeAnimations;
Timer<AnimationControllerPrivate> m_animationTimer;
Timer<AnimationControllerPrivate> m_updateStyleIfNeededDispatcher;
- Frame* m_frame;
+ Frame& m_frame;
class EventToDispatch {
public: