Commit 81a9dd71 authored by Gunnar Sletta's avatar Gunnar Sletta Committed by The Qt Project
Browse files

Avoid using QColor::xxxF functions.


In our usecase, the color is always used as a float so using QColor
(which is ushort) internally adds a lot of pointless conversion.
Enough so that it shows up in profiles as 1-2% each. Not a lot,
but easy to fix.

The compare function is also somewhat simplified. For colors we're
primarily searching for equallity. If that fails, we just need to
provide consistent values, so use the address instead of doing
any fancy calculation.

Change-Id: Icae7e78ed767e802c137bab7fcacff66e9a4bc66
Reviewed-by: default avatarYoann Lopes <yoann.lopes@digia.com>
parent cc36ce67
No related merge requests found
Showing with 22 additions and 29 deletions
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment