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

Side by Side Diff: Source/core/html/ImageDocument.cpp

Issue 932403002: InlinedVisitor: Migrate html to use inlined tracing (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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
« no previous file with comments | « Source/core/html/ImageDocument.h ('k') | Source/core/html/LabelableElement.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2010 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 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 } 371 }
372 372
373 #if !ENABLE(OILPAN) 373 #if !ENABLE(OILPAN)
374 void ImageDocument::dispose() 374 void ImageDocument::dispose()
375 { 375 {
376 m_imageElement = nullptr; 376 m_imageElement = nullptr;
377 HTMLDocument::dispose(); 377 HTMLDocument::dispose();
378 } 378 }
379 #endif 379 #endif
380 380
381 void ImageDocument::trace(Visitor* visitor) 381 DEFINE_TRACE(ImageDocument)
382 { 382 {
383 visitor->trace(m_imageElement); 383 visitor->trace(m_imageElement);
384 HTMLDocument::trace(visitor); 384 HTMLDocument::trace(visitor);
385 } 385 }
386 386
387 // -------- 387 // --------
388 388
389 void ImageEventListener::handleEvent(ExecutionContext*, Event* event) 389 void ImageEventListener::handleEvent(ExecutionContext*, Event* event)
390 { 390 {
391 if (event->type() == EventTypeNames::resize) 391 if (event->type() == EventTypeNames::resize)
392 m_doc->windowSizeChanged(ImageDocument::ScaleOnlyUnzoomedDocument); 392 m_doc->windowSizeChanged(ImageDocument::ScaleOnlyUnzoomedDocument);
393 else if (event->type() == EventTypeNames::click && event->isMouseEvent()) { 393 else if (event->type() == EventTypeNames::click && event->isMouseEvent()) {
394 MouseEvent* mouseEvent = toMouseEvent(event); 394 MouseEvent* mouseEvent = toMouseEvent(event);
395 m_doc->imageClicked(mouseEvent->x(), mouseEvent->y()); 395 m_doc->imageClicked(mouseEvent->x(), mouseEvent->y());
396 } 396 }
397 } 397 }
398 398
399 bool ImageEventListener::operator==(const EventListener& listener) 399 bool ImageEventListener::operator==(const EventListener& listener)
400 { 400 {
401 if (const ImageEventListener* imageEventListener = ImageEventListener::cast( &listener)) 401 if (const ImageEventListener* imageEventListener = ImageEventListener::cast( &listener))
402 return m_doc == imageEventListener->m_doc; 402 return m_doc == imageEventListener->m_doc;
403 return false; 403 return false;
404 } 404 }
405 405
406 } 406 }
OLDNEW
« no previous file with comments | « Source/core/html/ImageDocument.h ('k') | Source/core/html/LabelableElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698