[Webkit-unassigned] [Bug 21816] Clean up ImageBuffer.h so there do not have to be separate ifdefs for each platform
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Oct 22 18:04:35 PDT 2008
https://bugs.webkit.org/show_bug.cgi?id=21816
sam at webkit.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #24580|review? |review-
Flag| |
------- Comment #2 from sam at webkit.org 2008-10-22 18:04 PDT -------
(From update of attachment 24580)
- IntSize size() const { return m_size; }
+ const IntSize& size() const { return m_size; }
What is the reason for this change, the ChangeLog doesn't say? On many systems
it is possible to pass an IntSize in a register.
+ mutable std::auto_ptr<PlatformImageBuffer> m_platform;
This shouldn't be an auto_ptr and should instead just be a member. It could
also use a better name. Perhaps PlatformImageBuffer m_platformImageBuffer;
+ ImageBuffer(std::auto_ptr<PlatformImageBuffer>, const IntSize&,
std::auto_ptr<GraphicsContext>);
This should not take auto_ptrs. I don't even think it needs to take a
PlatformImageBuffer as a parameter. It should just instantiate one itself.
The rest of the patch is based on the model above and thus should be changed as
well. As such, I will only list the style issues from here on.
+class PlatformImageBuffer
+{
The { should go on the same line as the class name. This is repeated a bunch.
+ unsigned int m_bytesPerRow;
Should just be unsigned.
+ QPainter painter() { return m_painter; }
This should probably return a QPainter*.
+ QPainter* m_painter;
This should be an OwnPtr.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the webkit-unassigned
mailing list