From 1cbdecfa9fc428ac2d8aca0fa91c9580b3d57353 Mon Sep 17 00:00:00 2001 From: The Android Open Source Project Date: Wed, 17 Dec 2008 18:05:15 -0800 Subject: Code drop from //branches/cupcake/...@124589 --- WebCore/editing/InsertLineBreakCommand.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'WebCore/editing/InsertLineBreakCommand.h') diff --git a/WebCore/editing/InsertLineBreakCommand.h b/WebCore/editing/InsertLineBreakCommand.h index 1f5cdc8..9e73add 100644 --- a/WebCore/editing/InsertLineBreakCommand.h +++ b/WebCore/editing/InsertLineBreakCommand.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2005, 2006 Apple Computer, Inc. All rights reserved. + * Copyright (C) 2005, 2006, 2008 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -32,12 +32,18 @@ namespace WebCore { class InsertLineBreakCommand : public CompositeEditCommand { public: + static PassRefPtr create(Document* document) + { + return adoptRef(new InsertLineBreakCommand(document)); + } + +private: InsertLineBreakCommand(Document*); virtual void doApply(); -private: virtual bool preservesTypingStyle() const; + void insertNodeAfterPosition(Node*, const Position&); void insertNodeBeforePosition(Node*, const Position&); bool shouldUseBreakElement(const Position&); -- cgit v1.1