Skip to content

Commit 3a1af19

Browse files
committed
Merge from mozilla-inbound to mozilla-central
2 parents e27ef6c + aff68ff commit 3a1af19

File tree

99 files changed

+8335
-4244
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

99 files changed

+8335
-4244
lines changed

browser/components/build/Makefile.in

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,12 @@ IS_COMPONENT = 1
1212
MODULE_NAME = nsBrowserCompsModule
1313
FORCE_SHARED_LIB = 1
1414

15-
# Because we are an application component, link against the CRT statically
16-
# (on Windows, but only if we're not building our own CRT for jemalloc)
17-
ifndef MOZ_MEMORY
15+
# Statically link the CRT on Windows if building against
16+
# a XULRunner SDK.
17+
ifdef LIBXUL_SDK
1818
USE_STATIC_LIBS = 1
1919
endif
2020

21-
2221
EXPORTS = nsBrowserCompsCID.h
2322

2423
CPPSRCS = nsModule.cpp \
@@ -70,3 +69,6 @@ EXTRA_DSO_LDOPTS += \
7069
endif
7170

7271
include $(topsrcdir)/config/rules.mk
72+
73+
# Ensure that we don't embed a manifest referencing the CRT.
74+
EMBED_MANIFEST_AT =

browser/themes/winstripe/browser-aero.css

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -294,21 +294,23 @@
294294
}
295295

296296
@media not all and (-moz-windows-compositor) {
297-
#main-window:-moz-system-metric(windows-default-theme) {
298-
background-color: rgb(185,209,234);
299-
}
300-
#main-window:-moz-system-metric(windows-default-theme):-moz-window-inactive {
301-
background-color: rgb(215,228,242);
302-
}
303-
304-
#toolbar-menubar:not([autohide=true]):not(:-moz-lwtheme):-moz-system-metric(windows-default-theme),
305-
#TabsToolbar[tabsontop=true]:not(:-moz-lwtheme):-moz-system-metric(windows-default-theme),
306-
#navigator-toolbox[tabsontop=false] > toolbar:not(#toolbar-menubar):not(:-moz-lwtheme):-moz-system-metric(windows-default-theme) {
307-
-moz-binding: url("chrome://global/content/bindings/toolbar.xml#toolbar-drag");
308-
background-color: transparent;
309-
}
310-
#toolbar-menubar[autohide=true]:-moz-system-metric(windows-default-theme) {
311-
background-color: transparent;
297+
@media (-moz-windows-default-theme) {
298+
#main-window {
299+
background-color: rgb(185,209,234);
300+
}
301+
#main-window:-moz-window-inactive {
302+
background-color: rgb(215,228,242);
303+
}
304+
305+
#toolbar-menubar:not([autohide=true]):not(:-moz-lwtheme),
306+
#TabsToolbar[tabsontop=true]:not(:-moz-lwtheme),
307+
#navigator-toolbox[tabsontop=false] > toolbar:not(#toolbar-menubar):not(:-moz-lwtheme) {
308+
-moz-binding: url("chrome://global/content/bindings/toolbar.xml#toolbar-drag");
309+
background-color: transparent;
310+
}
311+
#toolbar-menubar[autohide=true] {
312+
background-color: transparent !important;
313+
}
312314
}
313315

314316
#print-preview-toolbar:not(:-moz-lwtheme) {

browser/themes/winstripe/browser.css

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1551,9 +1551,11 @@ html|*.urlbar-input:-moz-lwtheme:-moz-placeholder,
15511551
}
15521552

15531553
%ifndef WINSTRIPE_AERO
1554-
.ac-url-text:-moz-system-metric(windows-default-theme),
1555-
.ac-action-text:-moz-system-metric(windows-default-theme) {
1556-
color: #006600;
1554+
@media (-moz-windows-default-theme) {
1555+
.ac-url-text,
1556+
.ac-action-text {
1557+
color: #006600;
1558+
}
15571559
}
15581560
%endif
15591561

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
%include places.css
22

33
/* Style Places sidebars as Vista media collection */
4-
#bookmarksPanel:-moz-system-metric(windows-default-theme),
5-
#history-panel:-moz-system-metric(windows-default-theme) {
6-
background-color: #EEF3FA;
7-
}
4+
@media (-moz-windows-default-theme) {
5+
#bookmarksPanel,
6+
#history-panel {
7+
background-color: #EEF3FA;
8+
}
89

9-
.sidebar-placesTree:-moz-system-metric(windows-default-theme) {
10-
background-color: transparent;
11-
border-top: none;
10+
.sidebar-placesTree {
11+
background-color: transparent;
12+
border-top: none;
13+
}
1214
}

content/canvas/src/nsCanvasRenderingContext2DAzure.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -809,7 +809,7 @@ class nsCanvasRenderingContext2DAzure :
809809
if (state.patternStyles[aStyle]->mRepeat == nsCanvasPatternAzure::NOREPEAT) {
810810
mode = EXTEND_CLAMP;
811811
} else {
812-
mode = EXTEND_WRAP;
812+
mode = EXTEND_REPEAT;
813813
}
814814
mPattern = new (mSurfacePattern.addr())
815815
SurfacePattern(state.patternStyles[aStyle]->mSurface, mode);

docshell/test/unit/test_nsIDownloadHistory.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,9 @@ function run_test()
9191
return;
9292
}
9393

94+
// Needed to properly setup and shutdown the profile.
95+
do_get_profile();
96+
9497
Services.prefs.setBoolPref("places.history.enabled", true);
9598

9699
for (var i = 0; i < tests.length; i++)

dom/indexedDB/test/Makefile.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,11 +124,12 @@ TEST_FILES = \
124124
test_setVersion_events.html \
125125
test_setVersion_exclusion.html \
126126
test_unique_index_update.html \
127-
test_writer_starvation.html \
128127
third_party_iframe1.html \
129128
third_party_iframe2.html \
130129
$(NULL)
131130

131+
# test_writer_starvation.html disabled for infinite loops, bug 595368
132+
132133
ifeq (browser,$(MOZ_BUILD_APP))
133134
BROWSER_TEST_FILES = \
134135
browser_forgetThisSite.js \

extensions/spellcheck/hunspell/src/README.hunspell

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
******* END LICENSE BLOCK *******
3737

3838
Hunspell Version: 1.3.2
39-
Additional Patches: Bug 710967
39+
Additional Patches: 694002, 710967
4040

4141
Hunspell Author: L�szl� N�meth
4242
MySpell Author: Kevin Hendricks & David Einstein

extensions/spellcheck/hunspell/src/affentry.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,9 @@ SfxEntry::SfxEntry(AffixMgr * pmgr, affentry* dp)
467467
memcpy(c.l.conds1, dp->c.l.conds1, MAXCONDLEN_1);
468468
c.l.conds2 = dp->c.l.conds2;
469469
} else memcpy(c.conds, dp->c.conds, MAXCONDLEN);
470-
470+
next = NULL;
471+
nextne = NULL;
472+
nexteq = NULL;
471473
rappnd = myrevstrdup(appnd);
472474
morphcode = dp->morphcode;
473475
contclass = dp->contclass;

gfx/2d/2D.h

Lines changed: 94 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -148,13 +148,19 @@ struct StrokeOptions {
148148
*
149149
* mFilter - Filter used when resampling source surface region to the
150150
* destination region.
151+
* aSamplingBounds - This indicates whether the implementation is allowed
152+
* to sample pixels outside the source rectangle as
153+
* specified in DrawSurface on the surface.
151154
*/
152155
struct DrawSurfaceOptions {
153-
DrawSurfaceOptions(Filter aFilter = FILTER_LINEAR)
156+
DrawSurfaceOptions(Filter aFilter = FILTER_LINEAR,
157+
SamplingBounds aSamplingBounds = SAMPLING_UNBOUNDED)
154158
: mFilter(aFilter)
159+
, mSamplingBounds(aSamplingBounds)
155160
{ }
156161

157162
Filter mFilter : 3;
163+
SamplingBounds mSamplingBounds : 1;
158164
};
159165

160166
/*
@@ -212,16 +218,20 @@ class LinearGradientPattern : public Pattern
212218
public:
213219
/*
214220
* aBegin Start of the linear gradient
215-
* aEnd End of the linear gradient
221+
* aEnd End of the linear gradient - NOTE: In the case of a zero length
222+
* gradient it will act as the color of the last stop.
216223
* aStops GradientStops object for this gradient, this should match the
217224
* backend type of the draw target this pattern will be used with.
225+
* aMatrix A matrix that transforms the pattern into user space
218226
*/
219227
LinearGradientPattern(const Point &aBegin,
220228
const Point &aEnd,
221-
GradientStops *aStops)
229+
GradientStops *aStops,
230+
const Matrix &aMatrix = Matrix())
222231
: mBegin(aBegin)
223232
, mEnd(aEnd)
224233
, mStops(aStops)
234+
, mMatrix(aMatrix)
225235
{
226236
}
227237

@@ -230,6 +240,7 @@ class LinearGradientPattern : public Pattern
230240
Point mBegin;
231241
Point mEnd;
232242
RefPtr<GradientStops> mStops;
243+
Matrix mMatrix;
233244
};
234245

235246
/*
@@ -245,17 +256,20 @@ class RadialGradientPattern : public Pattern
245256
* aEnd End of the linear gradient
246257
* aStops GradientStops object for this gradient, this should match the
247258
* backend type of the draw target this pattern will be used with.
259+
* aMatrix A matrix that transforms the pattern into user space
248260
*/
249261
RadialGradientPattern(const Point &aCenter1,
250262
const Point &aCenter2,
251263
Float aRadius1,
252264
Float aRadius2,
253-
GradientStops *aStops)
265+
GradientStops *aStops,
266+
const Matrix &aMatrix = Matrix())
254267
: mCenter1(aCenter1)
255268
, mCenter2(aCenter2)
256269
, mRadius1(aRadius1)
257270
, mRadius2(aRadius2)
258271
, mStops(aStops)
272+
, mMatrix(aMatrix)
259273
{
260274
}
261275

@@ -266,6 +280,7 @@ class RadialGradientPattern : public Pattern
266280
Float mRadius1;
267281
Float mRadius2;
268282
RefPtr<GradientStops> mStops;
283+
Matrix mMatrix;
269284
};
270285

271286
/*
@@ -275,16 +290,27 @@ class RadialGradientPattern : public Pattern
275290
class SurfacePattern : public Pattern
276291
{
277292
public:
278-
SurfacePattern(SourceSurface *aSourceSurface, ExtendMode aExtendMode)
293+
/*
294+
* aSourceSurface Surface to use for drawing
295+
* aExtendMode This determines how the image is extended outside the bounds
296+
* of the image.
297+
* aMatrix A matrix that transforms the pattern into user space
298+
* aFilter Resampling filter used for resampling the image.
299+
*/
300+
SurfacePattern(SourceSurface *aSourceSurface, ExtendMode aExtendMode,
301+
const Matrix &aMatrix = Matrix(), Filter aFilter = FILTER_LINEAR)
279302
: mSurface(aSourceSurface)
280303
, mExtendMode(aExtendMode)
304+
, mFilter(aFilter)
305+
, mMatrix(aMatrix)
281306
{}
282307

283308
virtual PatternType GetType() const { return PATTERN_SURFACE; }
284309

285310
RefPtr<SourceSurface> mSurface;
286311
ExtendMode mExtendMode;
287312
Filter mFilter;
313+
Matrix mMatrix;
288314
};
289315

290316
/*
@@ -311,6 +337,7 @@ class SourceSurface : public RefCounted<SourceSurface>
311337
class DataSourceSurface : public SourceSurface
312338
{
313339
public:
340+
virtual SurfaceType GetType() const { return SURFACE_DATA; }
314341
/* Get the raw bitmap data of the surface */
315342
virtual unsigned char *GetData() = 0;
316343
/*
@@ -319,6 +346,12 @@ class DataSourceSurface : public SourceSurface
319346
*/
320347
virtual int32_t Stride() = 0;
321348

349+
/*
350+
* This function is called after modifying the data on the source surface
351+
* directly through the data pointer.
352+
*/
353+
virtual void MarkDirty() {}
354+
322355
virtual TemporaryRef<DataSourceSurface> GetDataSurface() { RefPtr<DataSourceSurface> temp = this; return temp.forget(); }
323356
};
324357

@@ -606,13 +639,34 @@ class DrawTarget : public RefCounted<DrawTarget>
606639
const Pattern &aPattern,
607640
const DrawOptions &aOptions = DrawOptions()) = 0;
608641

642+
/*
643+
* This takes a source pattern and a mask, and composites the source pattern
644+
* onto the destination surface using the alpha channel of the mask pattern
645+
* as a mask for the operation.
646+
*
647+
* aSource Source pattern
648+
* aMask Mask pattern
649+
* aOptions Drawing options
650+
*/
651+
virtual void Mask(const Pattern &aSource,
652+
const Pattern &aMask,
653+
const DrawOptions &aOptions = DrawOptions()) = 0;
654+
609655
/*
610656
* Push a clip to the DrawTarget.
611657
*
612658
* aPath The path to clip to
613659
*/
614660
virtual void PushClip(const Path *aPath) = 0;
615661

662+
/*
663+
* Push an axis-aligned rectangular clip to the DrawTarget. This rectangle
664+
* is specified in user space.
665+
*
666+
* aRect The rect to clip to
667+
*/
668+
virtual void PushClipRect(const Rect &aRect) = 0;
669+
616670
/* Pop a clip from the DrawTarget. A pop without a corresponding push will
617671
* be ignored.
618672
*/
@@ -625,9 +679,9 @@ class DrawTarget : public RefCounted<DrawTarget>
625679
* The SourceSurface does not take ownership of aData, and may be freed at any time.
626680
*/
627681
virtual TemporaryRef<SourceSurface> CreateSourceSurfaceFromData(unsigned char *aData,
628-
const IntSize &aSize,
629-
int32_t aStride,
630-
SurfaceFormat aFormat) const = 0;
682+
const IntSize &aSize,
683+
int32_t aStride,
684+
SurfaceFormat aFormat) const = 0;
631685

632686
/*
633687
* Create a SourceSurface optimized for use with this DrawTarget from
@@ -666,8 +720,13 @@ class DrawTarget : public RefCounted<DrawTarget>
666720
*
667721
* aStops An array of gradient stops
668722
* aNumStops Number of stops in the array aStops
723+
* aExtendNone This describes how to extend the stop color outside of the
724+
* gradient area.
669725
*/
670-
virtual TemporaryRef<GradientStops> CreateGradientStops(GradientStop *aStops, uint32_t aNumStops) const = 0;
726+
virtual TemporaryRef<GradientStops>
727+
CreateGradientStops(GradientStop *aStops,
728+
uint32_t aNumStops,
729+
ExtendMode aExtendMode = EXTEND_CLAMP) const = 0;
671730

672731
const Matrix &GetTransform() const { return mTransform; }
673732

@@ -695,12 +754,34 @@ class DrawTarget : public RefCounted<DrawTarget>
695754
class Factory
696755
{
697756
public:
698-
#ifdef USE_CAIRO
699757
static TemporaryRef<DrawTarget> CreateDrawTargetForCairoSurface(cairo_surface_t* aSurface);
700-
#endif
701758

702-
static TemporaryRef<DrawTarget> CreateDrawTarget(BackendType aBackend, const IntSize &aSize, SurfaceFormat aFormat);
703-
static TemporaryRef<ScaledFont> CreateScaledFontForNativeFont(const NativeFont &aNativeFont, Float aSize);
759+
static TemporaryRef<DrawTarget>
760+
CreateDrawTarget(BackendType aBackend, const IntSize &aSize, SurfaceFormat aFormat);
761+
762+
static TemporaryRef<DrawTarget>
763+
CreateDrawTargetForData(BackendType aBackend, unsigned char* aData, const IntSize &aSize, int32_t aStride, SurfaceFormat aFormat);
764+
765+
static TemporaryRef<ScaledFont>
766+
CreateScaledFontForNativeFont(const NativeFont &aNativeFont, Float aSize);
767+
768+
/*
769+
* This creates a simple data source surface for a certain size. It allocates
770+
* new memory for the surface. This memory is freed when the surface is
771+
* destroyed.
772+
*/
773+
static TemporaryRef<DataSourceSurface>
774+
CreateDataSourceSurface(const IntSize &aSize, SurfaceFormat aFormat);
775+
776+
/*
777+
* This creates a simple data source surface for some existing data. It will
778+
* wrap this data and the data for this source surface. The caller is
779+
* responsible for deallocating the memory only after destruction of the
780+
* surface.
781+
*/
782+
static TemporaryRef<DataSourceSurface>
783+
CreateDataSourceSurfaceFromData(unsigned char *aData, int32_t aStride,
784+
const IntSize &aSize, SurfaceFormat aFormat);
704785

705786
#ifdef WIN32
706787
static TemporaryRef<DrawTarget> CreateDrawTargetForD3D10Texture(ID3D10Texture2D *aTexture, SurfaceFormat aFormat);

0 commit comments

Comments
 (0)