Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: Source/core/editing/RemoveCSSPropertyCommand.cpp

Issue 23822003: Have EditCommand classes deal with Document references, not pointers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2008 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 16 matching lines...) Expand all
27 #include "core/editing/RemoveCSSPropertyCommand.h" 27 #include "core/editing/RemoveCSSPropertyCommand.h"
28 28
29 #include "bindings/v8/ExceptionStatePlaceholder.h" 29 #include "bindings/v8/ExceptionStatePlaceholder.h"
30 #include "core/css/CSSStyleDeclaration.h" 30 #include "core/css/CSSStyleDeclaration.h"
31 #include "core/css/StylePropertySet.h" 31 #include "core/css/StylePropertySet.h"
32 #include "core/dom/Element.h" 32 #include "core/dom/Element.h"
33 #include "wtf/Assertions.h" 33 #include "wtf/Assertions.h"
34 34
35 namespace WebCore { 35 namespace WebCore {
36 36
37 RemoveCSSPropertyCommand::RemoveCSSPropertyCommand(Document* document, PassRefPt r<Element> element, CSSPropertyID property) 37 RemoveCSSPropertyCommand::RemoveCSSPropertyCommand(Document& document, PassRefPt r<Element> element, CSSPropertyID property)
38 : SimpleEditCommand(document) 38 : SimpleEditCommand(document)
39 , m_element(element) 39 , m_element(element)
40 , m_property(property) 40 , m_property(property)
41 , m_important(false) 41 , m_important(false)
42 { 42 {
43 ASSERT(m_element); 43 ASSERT(m_element);
44 } 44 }
45 45
46 RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand() 46 RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand()
47 { 47 {
(...skipping 16 matching lines...) Expand all
64 } 64 }
65 65
66 #ifndef NDEBUG 66 #ifndef NDEBUG
67 void RemoveCSSPropertyCommand::getNodesInCommand(HashSet<Node*>& nodes) 67 void RemoveCSSPropertyCommand::getNodesInCommand(HashSet<Node*>& nodes)
68 { 68 {
69 addNodeAndDescendants(m_element.get(), nodes); 69 addNodeAndDescendants(m_element.get(), nodes);
70 } 70 }
71 #endif 71 #endif
72 72
73 } // namespace WebCore 73 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/editing/RemoveCSSPropertyCommand.h ('k') | Source/core/editing/RemoveFormatCommand.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698