| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 2  * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 
| 3  * | 3  * | 
| 4  * Redistribution and use in source and binary forms, with or without | 4  * Redistribution and use in source and binary forms, with or without | 
| 5  * modification, are permitted provided that the following conditions | 5  * modification, are permitted provided that the following conditions | 
| 6  * are met: | 6  * are met: | 
| 7  * 1. Redistributions of source code must retain the above copyright | 7  * 1. Redistributions of source code must retain the above copyright | 
| 8  *    notice, this list of conditions and the following disclaimer. | 8  *    notice, this list of conditions and the following disclaimer. | 
| 9  * 2. Redistributions in binary form must reproduce the above copyright | 9  * 2. Redistributions in binary form must reproduce the above copyright | 
| 10  *    notice, this list of conditions and the following disclaimer in the | 10  *    notice, this list of conditions and the following disclaimer in the | 
| (...skipping 774 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 785 PassRefPtr<HTMLElement> createDefaultParagraphElement(Document& document) | 785 PassRefPtr<HTMLElement> createDefaultParagraphElement(Document& document) | 
| 786 { | 786 { | 
| 787     switch (document.frame()->editor().defaultParagraphSeparator()) { | 787     switch (document.frame()->editor().defaultParagraphSeparator()) { | 
| 788     case EditorParagraphSeparatorIsDiv: | 788     case EditorParagraphSeparatorIsDiv: | 
| 789         return HTMLDivElement::create(document); | 789         return HTMLDivElement::create(document); | 
| 790     case EditorParagraphSeparatorIsP: | 790     case EditorParagraphSeparatorIsP: | 
| 791         return HTMLParagraphElement::create(document); | 791         return HTMLParagraphElement::create(document); | 
| 792     } | 792     } | 
| 793 | 793 | 
| 794     ASSERT_NOT_REACHED(); | 794     ASSERT_NOT_REACHED(); | 
| 795     return 0; | 795     return nullptr; | 
| 796 } | 796 } | 
| 797 | 797 | 
| 798 PassRefPtr<HTMLElement> createBreakElement(Document& document) | 798 PassRefPtr<HTMLElement> createBreakElement(Document& document) | 
| 799 { | 799 { | 
| 800     return HTMLBRElement::create(document); | 800     return HTMLBRElement::create(document); | 
| 801 } | 801 } | 
| 802 | 802 | 
| 803 PassRefPtr<HTMLElement> createOrderedListElement(Document& document) | 803 PassRefPtr<HTMLElement> createOrderedListElement(Document& document) | 
| 804 { | 804 { | 
| 805     return HTMLOListElement::create(document); | 805     return HTMLOListElement::create(document); | 
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1118     // if the selection starts just before a paragraph break, skip over it | 1118     // if the selection starts just before a paragraph break, skip over it | 
| 1119     if (isEndOfParagraph(visiblePosition)) | 1119     if (isEndOfParagraph(visiblePosition)) | 
| 1120         return visiblePosition.next().deepEquivalent().downstream(); | 1120         return visiblePosition.next().deepEquivalent().downstream(); | 
| 1121 | 1121 | 
| 1122     // otherwise, make sure to be at the start of the first selected node, | 1122     // otherwise, make sure to be at the start of the first selected node, | 
| 1123     // instead of possibly at the end of the last node before the selection | 1123     // instead of possibly at the end of the last node before the selection | 
| 1124     return visiblePosition.deepEquivalent().downstream(); | 1124     return visiblePosition.deepEquivalent().downstream(); | 
| 1125 } | 1125 } | 
| 1126 | 1126 | 
| 1127 } // namespace WebCore | 1127 } // namespace WebCore | 
| OLD | NEW | 
|---|