Bug 1351440 - Part 1. Implement imgDrawingParams. r=jwatt

A struct used during painting to provide input flags to determine how
imagelib draw calls should behave, plus an output DrawResult to return
information about the result of any imagelib draw calls that may have
occurred.

MozReview-Commit-ID: 3jGEh5vEPF
This commit is contained in:
cku 2017-05-18 22:03:36 +02:00
Родитель 21f4802365
Коммит d26418ab50
1 изменённых файлов: 16 добавлений и 0 удалений

Просмотреть файл

@ -84,6 +84,22 @@ operator&=(DrawResult& aLeft, const DrawResult aRight)
return aLeft; return aLeft;
} }
/**
* A struct used during painting to provide input flags to determine how
* imagelib draw calls should behave and an output DrawResult to return
* information about the result of any imagelib draw calls that may have
* occurred.
*/
struct imgDrawingParams {
explicit imgDrawingParams(uint32_t aImageFlags = 0)
: imageFlags(aImageFlags), result(DrawResult::SUCCESS)
{}
const uint32_t imageFlags; // imgIContainer::FLAG_* image flags to pass to
// image lib draw calls.
DrawResult result; // To return results from image lib painting.
};
} // namespace image } // namespace image
} // namespace mozilla } // namespace mozilla