Changeset 49242 in webkit


Ignore:
Timestamp:
Oct 7, 2009 7:06:50 AM (14 years ago)
Author:
kenneth@webkit.org
Message:

Do not create valid QColor's for invalid WebCore::Color's.

Patch by Kenneth Rohde Christiansen <kenneth@webkit.org> on 2009-10-07
Reviewed by Simon Hausmann.

  • platform/graphics/qt/ColorQt.cpp:

(WebCore::Color::operator QColor):

Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r49239 r49242  
     12009-10-07  Kenneth Rohde Christiansen  <kenneth@webkit.org>
     2
     3        Reviewed by Simon Hausmann.
     4
     5        Do not create valid QColor's for invalid WebCore::Color's.
     6
     7        * platform/graphics/qt/ColorQt.cpp:
     8        (WebCore::Color::operator QColor):
     9
    1102009-10-07  Janne Koskinen  <janne.p.koskinen@digia.com>
    211
  • trunk/WebCore/platform/graphics/qt/ColorQt.cpp

    r29663 r49242  
    4141Color::operator QColor() const
    4242{
    43     return QColor(red(), green(), blue(), alpha());
     43    if (m_valid)
     44        return QColor(red(), green(), blue(), alpha());
     45    else
     46        return QColor();
    4447}
    4548
Note: See TracChangeset for help on using the changeset viewer.