mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 11:25:00 +00:00
Bug 1321412 - Add an operator<< to BaseSize. r=kats
MozReview-Commit-ID: 4zVkyafxtfG --HG-- extra : rebase_source : 4a5a3f09ab0008d7e736cedb817505e6e45b054c
This commit is contained in:
parent
3fe1792b18
commit
d19f5c1380
@ -7,6 +7,8 @@
|
||||
#define MOZILLA_GFX_BASESIZE_H_
|
||||
|
||||
#include <algorithm>
|
||||
#include <ostream>
|
||||
|
||||
#include "mozilla/Attributes.h"
|
||||
|
||||
namespace mozilla {
|
||||
@ -103,6 +105,11 @@ struct BaseSize {
|
||||
return Sub(std::max(aA.width, aB.width),
|
||||
std::max(aA.height, aB.height));
|
||||
}
|
||||
|
||||
friend std::ostream& operator<<(std::ostream& aStream,
|
||||
const BaseSize<T, Sub>& aSize) {
|
||||
return aStream << aSize.width << " x " << aSize.height;
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace gfx
|
||||
|
Loading…
Reference in New Issue
Block a user