OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 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 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
223 setDragImageResource(toHTMLImageElement(*image).cachedImage(), location)
; | 223 setDragImageResource(toHTMLImageElement(*image).cachedImage(), location)
; |
224 else | 224 else |
225 setDragImageElement(image, location); | 225 setDragImageElement(image, location); |
226 } | 226 } |
227 | 227 |
228 void DataTransfer::clearDragImage() | 228 void DataTransfer::clearDragImage() |
229 { | 229 { |
230 if (!canSetDragImage()) | 230 if (!canSetDragImage()) |
231 return; | 231 return; |
232 | 232 |
233 m_dragImage = 0; | 233 m_dragImage = nullptr; |
234 m_dragLoc = IntPoint(); | 234 m_dragLoc = IntPoint(); |
235 m_dragImageElement = nullptr; | 235 m_dragImageElement = nullptr; |
236 } | 236 } |
237 | 237 |
238 void DataTransfer::setDragImageResource(ImageResource* img, const IntPoint& loc) | 238 void DataTransfer::setDragImageResource(ImageResource* img, const IntPoint& loc) |
239 { | 239 { |
240 setDragImage(img, 0, loc); | 240 setDragImage(img, 0, loc); |
241 } | 241 } |
242 | 242 |
243 void DataTransfer::setDragImageElement(Node* node, const IntPoint& loc) | 243 void DataTransfer::setDragImageElement(Node* node, const IntPoint& loc) |
(...skipping 262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
506 case DragOperationLink: | 506 case DragOperationLink: |
507 return String("link"); | 507 return String("link"); |
508 default: | 508 default: |
509 return String("copy"); | 509 return String("copy"); |
510 } | 510 } |
511 } | 511 } |
512 | 512 |
513 DEFINE_TRACE(DataTransfer) | 513 DEFINE_TRACE(DataTransfer) |
514 { | 514 { |
515 visitor->trace(m_dataObject); | 515 visitor->trace(m_dataObject); |
| 516 visitor->trace(m_dragImage); |
516 #if ENABLE(OILPAN) | 517 #if ENABLE(OILPAN) |
517 visitor->trace(m_dragImageElement); | 518 visitor->trace(m_dragImageElement); |
518 #endif | 519 #endif |
519 } | 520 } |
520 | 521 |
521 } // namespace blink | 522 } // namespace blink |
OLD | NEW |