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

Side by Side Diff: Source/core/html/canvas/CanvasRenderingContext.h

Issue 1219013005: Fix virtual/override/final usage in Source/core/html/. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 5 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/TextDocument.h ('k') | Source/core/html/canvas/CanvasRenderingContext2D.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) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 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 29 matching lines...) Expand all
40 40
41 class CanvasImageSource; 41 class CanvasImageSource;
42 class HTMLCanvasElement; 42 class HTMLCanvasElement;
43 class ImageData; 43 class ImageData;
44 44
45 class CORE_EXPORT CanvasRenderingContext : public NoBaseWillBeGarbageCollectedFi nalized<CanvasRenderingContext>, public ActiveDOMObject, public ScriptWrappable { 45 class CORE_EXPORT CanvasRenderingContext : public NoBaseWillBeGarbageCollectedFi nalized<CanvasRenderingContext>, public ActiveDOMObject, public ScriptWrappable {
46 WTF_MAKE_NONCOPYABLE(CanvasRenderingContext); 46 WTF_MAKE_NONCOPYABLE(CanvasRenderingContext);
47 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED(CanvasRenderingContext); 47 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED(CanvasRenderingContext);
48 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(CanvasRenderingContext); 48 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(CanvasRenderingContext);
49 public: 49 public:
50 virtual ~CanvasRenderingContext() { } 50 ~CanvasRenderingContext() override { }
51 51
52 // A Canvas can either be "2D" or "webgl" but never both. If you request a 2 D canvas and the existing 52 // A Canvas can either be "2D" or "webgl" but never both. If you request a 2 D canvas and the existing
53 // context is already 2D, just return that. If the existing context is WebGL , then destroy it 53 // context is already 2D, just return that. If the existing context is WebGL , then destroy it
54 // before creating a new 2D context. Vice versa when requesting a WebGL canv as. Requesting a 54 // before creating a new 2D context. Vice versa when requesting a WebGL canv as. Requesting a
55 // context with any other type string will destroy any existing context. 55 // context with any other type string will destroy any existing context.
56 enum ContextType { 56 enum ContextType {
57 // Do not change assigned numbers of existing items: add new features to the end of the list. 57 // Do not change assigned numbers of existing items: add new features to the end of the list.
58 Context2d = 0, 58 Context2d = 0,
59 ContextExperimentalWebgl = 2, 59 ContextExperimentalWebgl = 2,
60 ContextWebgl = 3, 60 ContextWebgl = 3,
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 virtual int externallyAllocatedBytesPerPixel() { ASSERT_NOT_REACHED(); retur n 0; } 95 virtual int externallyAllocatedBytesPerPixel() { ASSERT_NOT_REACHED(); retur n 0; }
96 96
97 bool wouldTaintOrigin(CanvasImageSource*); 97 bool wouldTaintOrigin(CanvasImageSource*);
98 void didMoveToNewDocument(Document*); 98 void didMoveToNewDocument(Document*);
99 99
100 protected: 100 protected:
101 CanvasRenderingContext(HTMLCanvasElement*); 101 CanvasRenderingContext(HTMLCanvasElement*);
102 DECLARE_VIRTUAL_TRACE(); 102 DECLARE_VIRTUAL_TRACE();
103 103
104 // ActiveDOMObject notifications 104 // ActiveDOMObject notifications
105 bool hasPendingActivity() const override final; 105 bool hasPendingActivity() const final;
106 void stop() override = 0; 106 void stop() override = 0;
107 107
108 private: 108 private:
109 RawPtrWillBeMember<HTMLCanvasElement> m_canvas; 109 RawPtrWillBeMember<HTMLCanvasElement> m_canvas;
110 HashSet<String> m_cleanURLs; 110 HashSet<String> m_cleanURLs;
111 HashSet<String> m_dirtyURLs; 111 HashSet<String> m_dirtyURLs;
112 }; 112 };
113 113
114 } // namespace blink 114 } // namespace blink
115 115
116 #endif 116 #endif
OLDNEW
« no previous file with comments | « Source/core/html/TextDocument.h ('k') | Source/core/html/canvas/CanvasRenderingContext2D.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698