Skip to content
Permalink
Browse files
CSSLineBoxContainValue constructor should return PassRef.
<https://webkit.org/b/123710>

Make CSSLineBoxContainValue::create() return a PassRef since it
will never return null.

Reviewed by Sam Weinig.


Canonical link: https://commits.webkit.org/141896@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@158543 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
Andreas Kling committed Nov 3, 2013
1 parent 196b9d2 commit 6f801129eac7d32cea2c773f5770da826ed7516e
Showing 3 changed files with 14 additions and 7 deletions.
@@ -1,3 +1,13 @@
2013-11-03 Andreas Kling <akling@apple.com>

CSSLineBoxContainValue constructor should return PassRef.
<https://webkit.org/b/123710>

Make CSSLineBoxContainValue::create() return a PassRef since it
will never return null.

Reviewed by Sam Weinig.

2013-11-03 Antti Koivisto <antti@apple.com>

LiveNodeLists should have non-null ContainerNode as root
@@ -26,9 +26,7 @@
#include "config.h"
#include "CSSLineBoxContainValue.h"

#include "CSSPrimitiveValue.h"
#include <wtf/text/StringBuilder.h>
#include <wtf/text/WTFString.h>

namespace WebCore {

@@ -41,20 +41,19 @@ typedef unsigned LineBoxContain;
// Used for text-CSSLineBoxContain and box-CSSLineBoxContain
class CSSLineBoxContainValue : public CSSValue {
public:
static PassRefPtr<CSSLineBoxContainValue> create(LineBoxContain value)
static PassRef<CSSLineBoxContainValue> create(LineBoxContain value)
{
return adoptRef(new CSSLineBoxContainValue(value));
return adoptRef(*new CSSLineBoxContainValue(value));
}

String customCSSText() const;
bool equals(const CSSLineBoxContainValue& other) const { return m_value == other.m_value; }
LineBoxContain value() const { return m_value; }

private:
LineBoxContain m_value;
explicit CSSLineBoxContainValue(LineBoxContain);

private:
CSSLineBoxContainValue(LineBoxContain);
LineBoxContain m_value;
};

CSS_VALUE_TYPE_CASTS(CSSLineBoxContainValue, isLineBoxContainValue())

0 comments on commit 6f80112

Please sign in to comment.