| OLD | NEW |
| 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 21 matching lines...) Expand all Loading... |
| 32 #include "wtf/Assertions.h" | 32 #include "wtf/Assertions.h" |
| 33 | 33 |
| 34 namespace blink { | 34 namespace blink { |
| 35 | 35 |
| 36 RemoveCSSPropertyCommand::RemoveCSSPropertyCommand(Document& document, Element*
element, CSSPropertyID property) | 36 RemoveCSSPropertyCommand::RemoveCSSPropertyCommand(Document& document, Element*
element, CSSPropertyID property) |
| 37 : SimpleEditCommand(document) | 37 : SimpleEditCommand(document) |
| 38 , m_element(element) | 38 , m_element(element) |
| 39 , m_property(property) | 39 , m_property(property) |
| 40 , m_important(false) | 40 , m_important(false) |
| 41 { | 41 { |
| 42 ASSERT(m_element); | 42 DCHECK(m_element); |
| 43 } | 43 } |
| 44 | 44 |
| 45 RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand() | 45 RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand() |
| 46 { | 46 { |
| 47 } | 47 } |
| 48 | 48 |
| 49 void RemoveCSSPropertyCommand::doApply(EditingState*) | 49 void RemoveCSSPropertyCommand::doApply(EditingState*) |
| 50 { | 50 { |
| 51 const StylePropertySet* style = m_element->inlineStyle(); | 51 const StylePropertySet* style = m_element->inlineStyle(); |
| 52 if (!style) | 52 if (!style) |
| (...skipping 12 matching lines...) Expand all Loading... |
| 65 m_element->style()->setPropertyInternal(m_property, String(), m_oldValue, m_
important, IGNORE_EXCEPTION); | 65 m_element->style()->setPropertyInternal(m_property, String(), m_oldValue, m_
important, IGNORE_EXCEPTION); |
| 66 } | 66 } |
| 67 | 67 |
| 68 DEFINE_TRACE(RemoveCSSPropertyCommand) | 68 DEFINE_TRACE(RemoveCSSPropertyCommand) |
| 69 { | 69 { |
| 70 visitor->trace(m_element); | 70 visitor->trace(m_element); |
| 71 SimpleEditCommand::trace(visitor); | 71 SimpleEditCommand::trace(visitor); |
| 72 } | 72 } |
| 73 | 73 |
| 74 } // namespace blink | 74 } // namespace blink |
| OLD | NEW |