mirror of
https://github.com/classilla/tenfourfox.git
synced 2024-10-03 06:55:41 +00:00
#375: M1342719 M1342720
This commit is contained in:
parent
bea84e5072
commit
f4015e0c10
@ -3859,7 +3859,6 @@ CanvasRenderingContext2D::DrawOrMeasureText(const nsAString& aRawText,
|
|||||||
|
|
||||||
// calls bidi algo twice since it needs the full text width and the
|
// calls bidi algo twice since it needs the full text width and the
|
||||||
// bounding boxes before rendering anything
|
// bounding boxes before rendering anything
|
||||||
nsBidi bidiEngine;
|
|
||||||
rv = nsBidiPresUtils::ProcessText(textToDraw.get(),
|
rv = nsBidiPresUtils::ProcessText(textToDraw.get(),
|
||||||
textToDraw.Length(),
|
textToDraw.Length(),
|
||||||
isRTL ? NSBIDI_RTL : NSBIDI_LTR,
|
isRTL ? NSBIDI_RTL : NSBIDI_LTR,
|
||||||
@ -3869,7 +3868,7 @@ CanvasRenderingContext2D::DrawOrMeasureText(const nsAString& aRawText,
|
|||||||
nullptr,
|
nullptr,
|
||||||
0,
|
0,
|
||||||
&totalWidthCoord,
|
&totalWidthCoord,
|
||||||
&bidiEngine);
|
&mBidiEngine);
|
||||||
if (NS_FAILED(rv)) {
|
if (NS_FAILED(rv)) {
|
||||||
return rv;
|
return rv;
|
||||||
}
|
}
|
||||||
@ -3984,7 +3983,7 @@ CanvasRenderingContext2D::DrawOrMeasureText(const nsAString& aRawText,
|
|||||||
nullptr,
|
nullptr,
|
||||||
0,
|
0,
|
||||||
nullptr,
|
nullptr,
|
||||||
&bidiEngine);
|
&mBidiEngine);
|
||||||
|
|
||||||
|
|
||||||
mTarget->SetTransform(oldTransform);
|
mTarget->SetTransform(oldTransform);
|
||||||
|
@ -28,6 +28,7 @@
|
|||||||
#include "FilterSupport.h"
|
#include "FilterSupport.h"
|
||||||
#include "nsSVGEffects.h"
|
#include "nsSVGEffects.h"
|
||||||
#include "Layers.h"
|
#include "Layers.h"
|
||||||
|
#include "nsBidi.h"
|
||||||
|
|
||||||
class nsGlobalWindow;
|
class nsGlobalWindow;
|
||||||
class nsXULElement;
|
class nsXULElement;
|
||||||
@ -821,6 +822,8 @@ protected:
|
|||||||
|
|
||||||
nsTArray<RegionInfo> mHitRegionsOptions;
|
nsTArray<RegionInfo> mHitRegionsOptions;
|
||||||
|
|
||||||
|
nsBidi mBidiEngine;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true if a shadow should be drawn along with a
|
* Returns true if a shadow should be drawn along with a
|
||||||
* drawing operation.
|
* drawing operation.
|
||||||
|
@ -75,9 +75,8 @@ AccessCheck::wrapperSubsumes(JSObject* wrapper)
|
|||||||
bool
|
bool
|
||||||
AccessCheck::isChrome(JSCompartment* compartment)
|
AccessCheck::isChrome(JSCompartment* compartment)
|
||||||
{
|
{
|
||||||
bool privileged;
|
|
||||||
nsIPrincipal* principal = GetCompartmentPrincipal(compartment);
|
nsIPrincipal* principal = GetCompartmentPrincipal(compartment);
|
||||||
return NS_SUCCEEDED(nsXPConnect::SecurityManager()->IsSystemPrincipal(principal, &privileged)) && privileged;
|
return nsXPConnect::SystemPrincipal() == principal;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
Loading…
Reference in New Issue
Block a user