mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 879004 - Move template methods to header file. r=BenWa
This commit is contained in:
parent
8cf123d18d
commit
9b6d544096
@ -6,7 +6,6 @@
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#include "LayersLogging.h"
|
||||
#include "nsPrintfCString.h"
|
||||
|
||||
using namespace mozilla::gfx;
|
||||
|
||||
@ -95,16 +94,6 @@ AppendToString(nsACString& s, const nsIntPoint& p,
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
template<class T>
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const PointTyped<T>& p,
|
||||
const char* pfx, const char* sfx)
|
||||
{
|
||||
s += pfx;
|
||||
s += nsPrintfCString("(x=%f, y=%f)", p.x, p.y);
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const nsIntRect& r,
|
||||
const char* pfx, const char* sfx)
|
||||
@ -116,18 +105,6 @@ AppendToString(nsACString& s, const nsIntRect& r,
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
template<class T>
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const RectTyped<T>& r,
|
||||
const char* pfx, const char* sfx)
|
||||
{
|
||||
s += pfx;
|
||||
s.AppendPrintf(
|
||||
"(x=%f, y=%f, w=%f, h=%f)",
|
||||
r.x, r.y, r.width, r.height);
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const nsIntRegion& r,
|
||||
const char* pfx, const char* sfx)
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include "gfxColor.h"
|
||||
#include "gfx3DMatrix.h"
|
||||
#include "nsRegion.h"
|
||||
#include "nsPrintfCString.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace layers {
|
||||
@ -47,7 +48,12 @@ AppendToString(nsACString& s, const nsIntPoint& p,
|
||||
template<class T>
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const mozilla::gfx::PointTyped<T>& p,
|
||||
const char* pfx="", const char* sfx="");
|
||||
const char* pfx="", const char* sfx="")
|
||||
{
|
||||
s += pfx;
|
||||
s += nsPrintfCString("(x=%f, y=%f)", p.x, p.y);
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const nsIntRect& r,
|
||||
@ -56,7 +62,14 @@ AppendToString(nsACString& s, const nsIntRect& r,
|
||||
template<class T>
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const mozilla::gfx::RectTyped<T>& r,
|
||||
const char* pfx="", const char* sfx="");
|
||||
const char* pfx="", const char* sfx="")
|
||||
{
|
||||
s += pfx;
|
||||
s.AppendPrintf(
|
||||
"(x=%f, y=%f, w=%f, h=%f)",
|
||||
r.x, r.y, r.width, r.height);
|
||||
return s += sfx;
|
||||
}
|
||||
|
||||
nsACString&
|
||||
AppendToString(nsACString& s, const nsIntRegion& r,
|
||||
|
Loading…
Reference in New Issue
Block a user