mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge m-c to birch.
This commit is contained in:
commit
7c692c494b
@ -61,9 +61,7 @@ function test()
|
||||
|
||||
executeSoon(function () {
|
||||
var win = gBrowser.replaceTabWithWindow(t);
|
||||
win.addEventListener("load", function () {
|
||||
win.removeEventListener("load", arguments.callee, true);
|
||||
|
||||
whenDelayedStartupFinished(win, function () {
|
||||
// Verify that the original window now only has the initial tab left in it.
|
||||
is(gBrowser.tabs[0], tabs[0], "tab0");
|
||||
is(gBrowser.getBrowserForTab(gBrowser.tabs[0]).contentWindow.location, "about:blank", "tab0 uri");
|
||||
@ -82,7 +80,7 @@ function test()
|
||||
}, false);
|
||||
win.gBrowser.goBack();
|
||||
});
|
||||
}, true);
|
||||
});
|
||||
});
|
||||
}, true);
|
||||
b.loadURI("about:blank");
|
||||
@ -111,10 +109,10 @@ function test()
|
||||
gBrowser.getBrowserForTab(tabs[i]).addEventListener("load", fn(waitForLoad,i), true);
|
||||
}
|
||||
|
||||
setLocation(1, "data:text/html,<title>tab1</title><body>tab1<iframe>");
|
||||
setLocation(2, "data:text/plain,tab2");
|
||||
setLocation(3, "data:text/html,<title>tab3</title><body>tab3<iframe>");
|
||||
setLocation(4, "data:text/html,<body onload='clicks=0' onclick='++clicks'>"+embed);
|
||||
setLocation(1, "data:text/html;charset=utf-8,<title>tab1</title><body>tab1<iframe>");
|
||||
setLocation(2, "data:text/plain;charset=utf-8,tab2");
|
||||
setLocation(3, "data:text/html;charset=utf-8,<title>tab3</title><body>tab3<iframe>");
|
||||
setLocation(4, "data:text/html;charset=utf-8,<body onload='clicks=0' onclick='++clicks'>"+embed);
|
||||
gBrowser.selectedTab = tabs[3];
|
||||
|
||||
}
|
||||
|
@ -124,11 +124,14 @@ var tests = {
|
||||
let numIcons = Object.keys(Social.provider.ambientNotificationIcons).length;
|
||||
ok(numIcons == 3, "prevent adding more than 3 ambient notification icons");
|
||||
|
||||
let statusIcon = document.getElementById("social-provider-button").nextSibling;
|
||||
let mButton = document.getElementById("social-mark-button");
|
||||
let pButton = document.getElementById("social-provider-button");
|
||||
waitForCondition(function() {
|
||||
statusIcon = document.getElementById("social-provider-button").nextSibling;
|
||||
return !!statusIcon;
|
||||
// wait for a new button to be inserted inbetween the provider and mark
|
||||
// button
|
||||
return pButton.nextSibling != mButton;
|
||||
}, function () {
|
||||
let statusIcon = pButton.nextSibling;
|
||||
let badge = statusIcon.getAttribute("badge");
|
||||
is(badge, "42", "status value is correct");
|
||||
// If there is a counter, the aria-label should reflect it.
|
||||
@ -136,6 +139,7 @@ var tests = {
|
||||
|
||||
ambience.counter = 0;
|
||||
Social.provider.setAmbientNotification(ambience);
|
||||
statusIcon = pButton.nextSibling;
|
||||
badge = statusIcon.getAttribute("badge");
|
||||
is(badge, "", "status value is correct");
|
||||
// If there is no counter, the aria-label should be the same as the label
|
||||
|
@ -2781,6 +2781,8 @@ let SessionStoreInternal = {
|
||||
return;
|
||||
}
|
||||
|
||||
TelemetryStopwatch.start("FX_SESSION_RESTORE_RESTORE_WINDOW_MS");
|
||||
|
||||
// We're not returning from this before we end up calling restoreHistoryPrecursor
|
||||
// for this window, so make sure we send the SSWindowStateBusy event.
|
||||
this._setWindowStateBusy(aWindow);
|
||||
@ -2933,6 +2935,8 @@ let SessionStoreInternal = {
|
||||
// set smoothScroll back to the original value
|
||||
tabstrip.smoothScroll = smoothScroll;
|
||||
|
||||
TelemetryStopwatch.finish("FX_SESSION_RESTORE_RESTORE_WINDOW_MS");
|
||||
|
||||
this._sendRestoreCompletedNotifications();
|
||||
},
|
||||
|
||||
|
@ -488,7 +488,7 @@ class Automation(object):
|
||||
ldLibraryPath = ldLibraryPath + ":" + env[envVar]
|
||||
env[envVar] = ldLibraryPath
|
||||
elif self.IS_WIN32:
|
||||
env["PATH"] = env["PATH"] + ";" + ldLibraryPath
|
||||
env["PATH"] = env["PATH"] + ";" + str(ldLibraryPath)
|
||||
|
||||
if crashreporter:
|
||||
env['MOZ_CRASHREPORTER_NO_REPORT'] = '1'
|
||||
|
@ -5241,7 +5241,7 @@ class CGJsonifierMethod(CGSpecializedMethod):
|
||||
' return false;\n'
|
||||
'}\n')
|
||||
for m in self.descriptor.interface.members:
|
||||
if m.isAttr() and not m.isStatic():
|
||||
if m.isAttr() and not m.isStatic() and m.type.isSerializable():
|
||||
ret += ('{ // scope for "temp"\n'
|
||||
' JS::Rooted<JS::Value> temp(cx);\n'
|
||||
' if (!get_%s(cx, obj, self, JSJitGetterCallArgs(&temp))) {\n'
|
||||
|
@ -1333,6 +1333,9 @@ class IDLType(IDLObject):
|
||||
# Should only call this on float types
|
||||
assert self.isFloat()
|
||||
|
||||
def isSerializable(self):
|
||||
return False
|
||||
|
||||
def tag(self):
|
||||
assert False # Override me!
|
||||
|
||||
@ -1468,6 +1471,9 @@ class IDLNullableType(IDLType):
|
||||
def isUnion(self):
|
||||
return self.inner.isUnion()
|
||||
|
||||
def isSerializable(self):
|
||||
return self.inner.isSerializable()
|
||||
|
||||
def tag(self):
|
||||
return self.inner.tag()
|
||||
|
||||
@ -1553,6 +1559,9 @@ class IDLSequenceType(IDLType):
|
||||
def isEnum(self):
|
||||
return False
|
||||
|
||||
def isSerializable(self):
|
||||
return self.inner.isSerializable()
|
||||
|
||||
def includesRestrictedFloat(self):
|
||||
return self.inner.includesRestrictedFloat()
|
||||
|
||||
@ -1602,6 +1611,9 @@ class IDLUnionType(IDLType):
|
||||
def isUnion(self):
|
||||
return True
|
||||
|
||||
def isSerializable(self):
|
||||
return all(m.isSerializable() for m in self.memberTypes)
|
||||
|
||||
def includesRestrictedFloat(self):
|
||||
return any(t.includesRestrictedFloat() for t in self.memberTypes)
|
||||
|
||||
@ -1932,6 +1944,19 @@ class IDLWrapperType(IDLType):
|
||||
def isEnum(self):
|
||||
return isinstance(self.inner, IDLEnum)
|
||||
|
||||
def isSerializable(self):
|
||||
if self.isInterface():
|
||||
if self.inner.isExternal():
|
||||
return False
|
||||
return any(m.isMethod() and m.isJsonifier() for m in self.inner.members)
|
||||
elif self.isEnum():
|
||||
return True
|
||||
elif self.isDictionary():
|
||||
return all(m.isSerializable() for m in self.inner.members)
|
||||
else:
|
||||
raise WebIDLError("IDLWrapperType wraps type %s that we don't know if "
|
||||
"is serializable" % type(self.inner), [self.location])
|
||||
|
||||
def resolveType(self, parentScope):
|
||||
assert isinstance(parentScope, IDLScope)
|
||||
self.inner.resolve(parentScope)
|
||||
@ -2130,6 +2155,9 @@ class IDLBuiltinType(IDLType):
|
||||
return self._typeTag == IDLBuiltinType.Types.unrestricted_float or \
|
||||
self._typeTag == IDLBuiltinType.Types.unrestricted_double
|
||||
|
||||
def isSerializable(self):
|
||||
return self.isPrimitive() or self.isDOMString() or self.isDate()
|
||||
|
||||
def includesRestrictedFloat(self):
|
||||
return self.isFloat() and not self.isUnrestricted()
|
||||
|
||||
|
@ -608,6 +608,12 @@ public:
|
||||
TestInterface* PutForwardsAttr();
|
||||
TestInterface* PutForwardsAttr2();
|
||||
TestInterface* PutForwardsAttr3();
|
||||
JS::Value JsonifierShouldSkipThis(JSContext*);
|
||||
void SetJsonifierShouldSkipThis(JSContext*, JS::Rooted<JS::Value>&);
|
||||
TestParentInterface* JsonifierShouldSkipThis2();
|
||||
void SetJsonifierShouldSkipThis2(TestParentInterface&);
|
||||
TestCallbackInterface* JsonifierShouldSkipThis3();
|
||||
void SetJsonifierShouldSkipThis3(TestCallbackInterface&);
|
||||
void ThrowingMethod(ErrorResult& aRv);
|
||||
bool GetThrowingAttr(ErrorResult& aRv) const;
|
||||
void SetThrowingAttr(bool arg, ErrorResult& aRv);
|
||||
|
@ -583,6 +583,10 @@ interface TestInterface {
|
||||
optional TestInterface? arg2 = null,
|
||||
optional Dict arg3, optional double arg4 = 5.0,
|
||||
optional float arg5);
|
||||
|
||||
attribute any jsonifierShouldSkipThis;
|
||||
attribute TestParentInterface jsonifierShouldSkipThis2;
|
||||
attribute TestCallbackInterface jsonifierShouldSkipThis3;
|
||||
jsonifier;
|
||||
|
||||
// If you add things here, add them to TestExampleGen and TestJSImplGen as well
|
||||
|
@ -480,6 +480,9 @@ interface TestExampleInterface {
|
||||
optional TestInterface? arg2 = null,
|
||||
optional Dict arg3, optional double arg4 = 5.0,
|
||||
optional float arg5);
|
||||
attribute any jsonifierShouldSkipThis;
|
||||
attribute TestParentInterface jsonifierShouldSkipThis2;
|
||||
attribute TestCallbackInterface jsonifierShouldSkipThis3;
|
||||
jsonifier;
|
||||
|
||||
// If you add things here, add them to TestCodeGen and TestJSImplGen as well
|
||||
|
@ -472,6 +472,9 @@ interface TestJSImplInterface {
|
||||
optional TestInterface? arg2 = null,
|
||||
optional Dict arg3, optional double arg4 = 5.0,
|
||||
optional float arg5);
|
||||
attribute any jsonifierShouldSkipThis;
|
||||
attribute TestParentInterface jsonifierShouldSkipThis2;
|
||||
attribute TestCallbackInterface jsonifierShouldSkipThis3;
|
||||
jsonifier;
|
||||
|
||||
// If you add things here, add them to TestCodeGen as well
|
||||
|
@ -69,7 +69,7 @@ class MochitestServer:
|
||||
env["ASAN_OPTIONS"] = "quarantine_size=1:redzone=32"
|
||||
|
||||
if mozinfo.isWin:
|
||||
env["PATH"] = env["PATH"] + ";" + self._xrePath
|
||||
env["PATH"] = env["PATH"] + ";" + str(self._xrePath)
|
||||
|
||||
args = ["-g", self._xrePath,
|
||||
"-v", "170",
|
||||
|
@ -2545,6 +2545,13 @@
|
||||
"extended_statistics_ok": true,
|
||||
"description": "Session restore: Time to make a backup copy of the session file (ms)"
|
||||
},
|
||||
"FX_SESSION_RESTORE_RESTORE_WINDOW_MS": {
|
||||
"kind": "exponential",
|
||||
"high": "3000",
|
||||
"n_buckets": 10,
|
||||
"extended_statistics_ok": true,
|
||||
"description": "Session restore: Time spent blocking the main thread while restoring a window state (ms)"
|
||||
},
|
||||
"INNERWINDOWS_WITH_MUTATION_LISTENERS": {
|
||||
"kind": "boolean",
|
||||
"description": "Deleted or to-be-reused innerwindow which has had mutation event listeners."
|
||||
|
@ -1765,27 +1765,6 @@ moz_gtk_treeview_expander_paint(GdkDrawable* drawable, GdkRectangle* rect,
|
||||
return MOZ_GTK_SUCCESS;
|
||||
}
|
||||
|
||||
static gint
|
||||
moz_gtk_expander_paint(GdkDrawable* drawable, GdkRectangle* rect,
|
||||
GdkRectangle* cliprect, GtkWidgetState* state,
|
||||
GtkExpanderStyle expander_state,
|
||||
GtkTextDirection direction)
|
||||
{
|
||||
GtkStyle *style;
|
||||
GtkStateType state_type = ConvertGtkState(state);
|
||||
|
||||
ensure_expander_widget();
|
||||
gtk_widget_set_direction(gExpanderWidget, direction);
|
||||
|
||||
style = gExpanderWidget->style;
|
||||
|
||||
TSOffsetStyleGCs(style, rect->x, rect->y);
|
||||
gtk_paint_expander(style, drawable, state_type, cliprect, gExpanderWidget, "expander",
|
||||
rect->x + rect->width / 2, rect->y + rect->height / 2, expander_state);
|
||||
|
||||
return MOZ_GTK_SUCCESS;
|
||||
}
|
||||
|
||||
static gint
|
||||
moz_gtk_combo_box_paint(GdkDrawable* drawable, GdkRectangle* rect,
|
||||
GdkRectangle* cliprect, GtkWidgetState* state,
|
||||
@ -2969,7 +2948,6 @@ moz_gtk_get_widget_border(GtkThemeWidgetType widget, gint* left, gint* top,
|
||||
case MOZ_GTK_PROGRESS_CHUNK:
|
||||
case MOZ_GTK_PROGRESS_CHUNK_INDETERMINATE:
|
||||
case MOZ_GTK_PROGRESS_CHUNK_VERTICAL_INDETERMINATE:
|
||||
case MOZ_GTK_EXPANDER:
|
||||
case MOZ_GTK_TREEVIEW_EXPANDER:
|
||||
case MOZ_GTK_TOOLBAR_SEPARATOR:
|
||||
case MOZ_GTK_MENUSEPARATOR:
|
||||
@ -3256,10 +3234,6 @@ moz_gtk_widget_paint(GtkThemeWidgetType widget, GdkDrawable* drawable,
|
||||
return moz_gtk_treeview_expander_paint(drawable, rect, cliprect, state,
|
||||
(GtkExpanderStyle) flags, direction);
|
||||
break;
|
||||
case MOZ_GTK_EXPANDER:
|
||||
return moz_gtk_expander_paint(drawable, rect, cliprect, state,
|
||||
(GtkExpanderStyle) flags, direction);
|
||||
break;
|
||||
case MOZ_GTK_ENTRY:
|
||||
ensure_entry_widget();
|
||||
return moz_gtk_entry_paint(drawable, rect, cliprect, state,
|
||||
|
@ -1570,6 +1570,8 @@ moz_gtk_tree_header_sort_arrow_paint(cairo_t *cr, GdkRectangle* rect,
|
||||
return MOZ_GTK_SUCCESS;
|
||||
}
|
||||
|
||||
/* See gtk_expander_paint() for reference.
|
||||
*/
|
||||
static gint
|
||||
moz_gtk_treeview_expander_paint(cairo_t *cr, GdkRectangle* rect,
|
||||
GtkWidgetState* state,
|
||||
@ -1577,6 +1579,7 @@ moz_gtk_treeview_expander_paint(cairo_t *cr, GdkRectangle* rect,
|
||||
GtkTextDirection direction)
|
||||
{
|
||||
GtkStyleContext *style;
|
||||
GtkStateFlags state_flags;
|
||||
|
||||
ensure_tree_view_widget();
|
||||
gtk_widget_set_direction(gTreeViewWidget, direction);
|
||||
@ -1584,34 +1587,25 @@ moz_gtk_treeview_expander_paint(cairo_t *cr, GdkRectangle* rect,
|
||||
style = gtk_widget_get_style_context(gTreeViewWidget);
|
||||
gtk_style_context_save(style);
|
||||
gtk_style_context_add_class(style, GTK_STYLE_CLASS_EXPANDER);
|
||||
/* Because the frame we get is of the entire treeview, we can't get the precise
|
||||
* event state of one expander, thus rendering hover and active feedback useless. */
|
||||
gtk_style_context_set_state(style, GetStateFlagsFromGtkWidgetState(state));
|
||||
|
||||
state_flags = GetStateFlagsFromGtkWidgetState(state);
|
||||
|
||||
/* GTK_STATE_FLAG_ACTIVE controls expanded/colapsed state rendering
|
||||
* in gtk_render_expander()
|
||||
*/
|
||||
if (expander_state == GTK_EXPANDER_EXPANDED)
|
||||
state_flags |= GTK_STATE_FLAG_ACTIVE;
|
||||
else
|
||||
state_flags &= ~(GTK_STATE_FLAG_ACTIVE);
|
||||
|
||||
gtk_style_context_set_state(style, state_flags);
|
||||
|
||||
gtk_render_expander(style, cr,
|
||||
rect->x + rect->width / 2, rect->y + rect->height / 2,
|
||||
rect->width, rect->height);
|
||||
gtk_style_context_restore(style);
|
||||
return MOZ_GTK_SUCCESS;
|
||||
}
|
||||
rect->x,
|
||||
rect->y,
|
||||
rect->width,
|
||||
rect->height);
|
||||
|
||||
static gint
|
||||
moz_gtk_expander_paint(cairo_t *cr, GdkRectangle* rect,
|
||||
GtkWidgetState* state,
|
||||
GtkExpanderStyle expander_state,
|
||||
GtkTextDirection direction)
|
||||
{
|
||||
GtkStyleContext *style;
|
||||
|
||||
ensure_expander_widget();
|
||||
gtk_widget_set_direction(gExpanderWidget, direction);
|
||||
|
||||
style = gtk_widget_get_style_context(gExpanderWidget);
|
||||
gtk_style_context_save(style);
|
||||
gtk_style_context_add_class(style, GTK_STYLE_CLASS_EXPANDER);
|
||||
gtk_style_context_set_state(style, GetStateFlagsFromGtkWidgetState(state));
|
||||
gtk_render_expander(style, cr,
|
||||
rect->x + rect->width / 2, rect->y + rect->height / 2,
|
||||
rect->width, rect->height);
|
||||
gtk_style_context_restore(style);
|
||||
return MOZ_GTK_SUCCESS;
|
||||
}
|
||||
@ -2828,7 +2822,6 @@ moz_gtk_get_widget_border(GtkThemeWidgetType widget, gint* left, gint* top,
|
||||
case MOZ_GTK_PROGRESS_CHUNK:
|
||||
case MOZ_GTK_PROGRESS_CHUNK_INDETERMINATE:
|
||||
case MOZ_GTK_PROGRESS_CHUNK_VERTICAL_INDETERMINATE:
|
||||
case MOZ_GTK_EXPANDER:
|
||||
case MOZ_GTK_TREEVIEW_EXPANDER:
|
||||
case MOZ_GTK_TOOLBAR_SEPARATOR:
|
||||
case MOZ_GTK_MENUSEPARATOR:
|
||||
@ -3134,10 +3127,6 @@ moz_gtk_widget_paint(GtkThemeWidgetType widget, cairo_t *cr,
|
||||
return moz_gtk_treeview_expander_paint(cr, rect, state,
|
||||
(GtkExpanderStyle) flags, direction);
|
||||
break;
|
||||
case MOZ_GTK_EXPANDER:
|
||||
return moz_gtk_expander_paint(cr, rect, state,
|
||||
(GtkExpanderStyle) flags, direction);
|
||||
break;
|
||||
case MOZ_GTK_ENTRY:
|
||||
ensure_entry_widget();
|
||||
return moz_gtk_entry_paint(cr, rect, state,
|
||||
|
@ -161,8 +161,6 @@ typedef enum {
|
||||
MOZ_GTK_TREE_HEADER_SORTARROW,
|
||||
/* Paints an expander for a GtkTreeView */
|
||||
MOZ_GTK_TREEVIEW_EXPANDER,
|
||||
/* Paints a GtkExpander */
|
||||
MOZ_GTK_EXPANDER,
|
||||
/* Paints the background of the menu bar. */
|
||||
MOZ_GTK_MENUBAR,
|
||||
/* Paints the background of menus, context menus. */
|
||||
|
Loading…
Reference in New Issue
Block a user