Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
tails
thunderbird
Commits
0b1d9f92
Commit
0b1d9f92
authored
Sep 05, 2021
by
Carsten Schoenert
Browse files
New upstream version 91.1.0
parent
a5efefd4
Changes
1000
Hide whitespace changes
Inline
Side-by-side
Too many changes to show.
To preserve performance only
20 of 1000+
files are displayed.
Plain diff
Email patch
Cargo.lock
View file @
0b1d9f92
...
...
@@ -864,9 +864,9 @@ dependencies = [
[[package]]
name = "crossbeam-deque"
version = "0.7.
3
"
version = "0.7.
4
"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "
9f02af974daeee82218205558e51ec8768b48cf524bd01d550abe5573a608285
"
checksum = "
c20ff29ded3204c5106278a81a38f4b482636ed4fa1e6cfbeef193291beb29ed
"
dependencies = [
"crossbeam-epoch",
"crossbeam-utils 0.7.2",
...
...
accessible/ipc/win/handler/HandlerData.idl
View file @
0b1d9f92
...
...
@@ -6,6 +6,7 @@
#
include
"mozilla-config.h"
#
include
"AccessibleHandler.h"
#
include
"HandlerDataUUID.h"
import
"ocidl.idl"
;
import
"servprov.idl"
;
...
...
@@ -65,65 +66,6 @@ typedef struct _DynamicIA2Data
interface
IGeckoBackChannel
;
//
We
define
different
CLSIDs
and
IIDs
depending
on
channel
and
officiality
.
//
This
prevents
handlers
from
installing
overtop
one
another
when
multiple
//
channels
are
present
.
Note
that
we
do
not
do
this
for
all
UUIDs
in
this
IDL
,
//
just
the
ones
that
are
written
to
the
registry
(
coclass
and
interfaces
that
//
have
the
[
object
]
annotation
)
#
if
defined
(
USE_LOCAL_UUID
)
#
if
defined
(
DEBUG
)
//
Local
debug
builds
#
define
HANDLER_CLSID
398
ffd8d
-
5382
-
48
f7
-
9
e3b
-
19012762
d39a
#
define
IHANDLERCONTROL_IID
a218497e
-
8b10
-
460b
-
b668
-
a92b7ee39ff2
#
define
ASYNCIHANDLERCONTROL_IID
ca18b9ab
-
04b6
-
41b
e
-
87
f7
-
d99913d6a2e8
#
define
IGECKOBACKCHANNEL_IID
231
c4946
-
4479
-
4
c8e
-
aadc
-
8
a0e48fc4c51
#
else
//
Local
non
-
debug
builds
#
define
HANDLER_CLSID
ce573faf
-
7815
-
4
fc2
-
a031
-
b092268ace9e
#
define
IHANDLERCONTROL_IID
2b715
cce
-
1790
-
4
fe1
-
aef5
-
48b
b5acdf3a1
#
define
ASYNCIHANDLERCONTROL_IID
8
e089670
-
4
f57
-
41
a7
-
89
c0
-
37
f17482fa6f
#
define
IGECKOBACKCHANNEL_IID
18
e2488d
-
310
f
-
400
f
-
8339
-
0
e50b513e801
#
endif
#
elif
defined
(
NIGHTLY_BUILD
)
//
Nightly
Builds
#
define
IHANDLERCONTROL_IID
c57343fc
-
e011
-
40
c2
-
b748
-
da82eabf0f1f
#
define
ASYNCIHANDLERCONTROL_IID
648
c92a1
-
ea35
-
46
da
-
a806
-
6b55
c6247373
#
define
HANDLER_CLSID
4629216b
-
8753
-
41b
f
-
9527
-
5b
ff51401671
#
define
IGECKOBACKCHANNEL_IID
e61e038d
-
40
dd
-
464
a
-
9
aba
-
66b206b6911b
#
elif
defined
(
USE_BETA_UUID
)
//
Beta
Builds
#
define
IHANDLERCONTROL_IID
119149
fa
-
d212
-
4
f22
-
9517
-
082
eecc1a084
#
define
ASYNCIHANDLERCONTROL_IID
4
e253d9b
-
59
cf
-
4b32
-
a973
-
38b
c85495d61
#
define
HANDLER_CLSID
21
e9f98d
-
a6c9
-
4
cb5
-
b288
-
ae2fd2a96c58
#
define
IGECKOBACKCHANNEL_IID
77b75
c7d
-
d1c2
-
4469
-864d-31
aaebb67cc6
#
elif
defined
(
RELEASE_OR_BETA
)
//
Release
Builds
#
define
IHANDLERCONTROL_IID
ce30f77e
-
8847
-
44
f0
-
a648
-
a9656bd89c0d
#
define
ASYNCIHANDLERCONTROL_IID
dca8d857
-
1
a63
-
4045
-
8
f36
-
8809
eb093d04
#
define
HANDLER_CLSID
1b
aa303d
-
b4b9
-
45
e5
-
9
ccb
-
e3fca3e274b6
#
define
IGECKOBACKCHANNEL_IID
b32983ff
-
ef84
-
4945
-
8
f86
-
fb7491b4f57b
#
else
//
Catch
-
all
#
define
IHANDLERCONTROL_IID
3316
ce35
-
f892
-
4832
-
97
c5
-
06
c52c03cdba
#
define
ASYNCIHANDLERCONTROL_IID
15b48b76
-
ad38
-
4
ad3
-
bd1a
-
d3c48a5a9947
#
define
HANDLER_CLSID
4
a195748
-
dca2
-
45
fb
-
9295
-
0
a139e76a9e7
#
define
IGECKOBACKCHANNEL_IID
dd2e4a89
-999e-4
d65
-
8b65
-
440
c923ddb61
#
endif
[
uuid
(
2b0
e83b3
-
fd1a
-
443
f
-
9
ed6
-
c00d39055b58
)
]
interface
HandlerData
{
...
...
accessible/ipc/win/handler/HandlerDataUUID.h.in
0 → 100644
View file @
0b1d9f92
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
// We use different CLSIDs and IIDs depending on channel and officiality.
// This prevents handlers from installing overtop one another when multiple
// channels are present. Note that we only do this for the UUIDs that are
// written to the registry.
// The specific UUIDs are defined in branding configuration.
#define HANDLER_CLSID @MOZ_HANDLER_CLSID@
#define IHANDLERCONTROL_IID @MOZ_IHANDLERCONTROL_IID@
#define ASYNCIHANDLERCONTROL_IID @MOZ_ASYNCIHANDLERCONTROL_IID@
#define IGECKOBACKCHANNEL_IID @MOZ_IGECKOBACKCHANNEL_IID@
accessible/ipc/win/handler/moz.build
View file @
0b1d9f92
...
...
@@ -18,13 +18,11 @@ LOCAL_INCLUDES += [
# We want to generate distinct UUIDs on a per-channel basis, so we need
# finer granularity than the standard preprocessor definitions offer.
# These defines allow us to separate local builds from automated builds,
# as well as separate beta from release.
# This generated include allow us to separate local builds from automated
# builds, separate beta from release, and use different UUIDs in downstream
# projects such as Thunderbird.
CONFIGURE_SUBST_FILES
+=
[
"HandlerDataUUID.h"
]
flags
=
[]
if
CONFIG
[
"MOZ_UPDATE_CHANNEL"
]
==
"default"
:
flags
+=
[
"-DUSE_LOCAL_UUID"
]
elif
CONFIG
[
"MOZ_UPDATE_CHANNEL"
]
==
"beta"
:
flags
+=
[
"-DUSE_BETA_UUID"
]
GeneratedFile
(
"HandlerData.h"
,
...
...
@@ -46,6 +44,8 @@ GeneratedFile(
TOPSRCDIR
+
"/other-licenses/ia2"
,
"-I"
,
SRCDIR
,
"-I"
,
OBJDIR
,
"-acf"
,
SRCDIR
+
"/HandlerData.acf"
,
"-dlldata"
,
...
...
@@ -68,6 +68,7 @@ SOURCES += [
EXPORTS
+=
[
"!HandlerData.h"
,
"!HandlerData_i.c"
,
"!HandlerDataUUID.h"
,
]
# Give some symbols a unique name in each translation unit, to avoid
...
...
accessible/tests/browser/telemetry/browser_HCM_telemetry.js
View file @
0b1d9f92
...
...
@@ -95,11 +95,11 @@ async function setBackgroundColor(color) {
add_task
(
async
function
testInit
()
{
const
dialogWin
=
await
openColorsDialog
();
const
menulistHCM
=
dialogWin
.
document
.
getElementById
(
"
useDocumentColors
"
);
if
(
AppConstants
.
platform
==
"
win
"
||
AppConstants
.
platform
==
"
macosx
"
)
{
if
(
AppConstants
.
platform
==
"
win
"
)
{
is
(
menulistHCM
.
value
,
"
0
"
,
"
HCM menulist should be set to only with HCM theme on startup for windows
and mac
"
"
HCM menulist should be set to only with HCM theme on startup for windows
"
);
// Verify correct default value
...
...
@@ -113,7 +113,7 @@ add_task(async function testInit() {
is
(
menulistHCM
.
value
,
"
1
"
,
"
HCM menulist should be set to never on startup for
other
platforms
"
"
HCM menulist should be set to never on startup for
non-windows
platforms
"
);
// Verify correct default value
...
...
accessible/xul/XULTreeGridAccessible.cpp
View file @
0b1d9f92
...
...
@@ -174,7 +174,7 @@ void XULTreeGridAccessible::UnselectRow(uint32_t aRowIdx) {
// XULTreeGridAccessible: LocalAccessible implementation
role
XULTreeGridAccessible
::
NativeRole
()
const
{
RefPtr
<
nsTreeColumns
>
treeColumns
=
mTree
->
GetColumns
();
RefPtr
<
nsTreeColumns
>
treeColumns
=
mTree
->
GetColumns
(
FlushType
::
None
);
if
(
!
treeColumns
)
{
NS_ERROR
(
"No treecolumns object for tree!"
);
return
roles
::
NOTHING
;
...
...
@@ -316,7 +316,7 @@ XULTreeGridCellAccessible* XULTreeGridRowAccessible::GetCellAccessible(
void
XULTreeGridRowAccessible
::
RowInvalidated
(
int32_t
aStartColIdx
,
int32_t
aEndColIdx
)
{
RefPtr
<
nsTreeColumns
>
treeColumns
=
mTree
->
GetColumns
();
RefPtr
<
nsTreeColumns
>
treeColumns
=
mTree
->
GetColumns
(
FlushType
::
None
);
if
(
!
treeColumns
)
return
;
bool
nameChanged
=
false
;
...
...
browser/actors/AboutReaderChild.jsm
View file @
0b1d9f92
...
...
@@ -223,7 +223,10 @@ class AboutReaderChild extends JSWindowActorChild {
// Only send updates when there are articles; there's no point updating with
// |false| all the time.
if (Readerable.isProbablyReaderable(document)) {
if (
Readerable.shouldCheckUri(document.baseURIObject, true) &&
Readerable.isProbablyReaderable(document)
) {
this.sendAsyncMessage("Reader:UpdateReaderButton", {
isArticle: true,
});
...
...
browser/actors/ContentSearchParent.jsm
View file @
0b1d9f92
...
...
@@ -352,9 +352,11 @@ let ContentSearch = {
}
if (window) {
state.isPrivate
Window
= PrivateBrowsingUtils.isContentWindowPrivate(
state.is
In
Private
BrowsingMode
= PrivateBrowsingUtils.isContentWindowPrivate(
window
);
state.isAboutPrivateBrowsing =
window.gBrowser.currentURI.spec == "about:privatebrowsing";
}
return state;
...
...
@@ -422,8 +424,9 @@ let ContentSearch = {
_onMessageGetEngine({ actor, browser }) {
return this.currentStateObj(browser.ownerGlobal).then(state => {
this._reply(actor, "Engine", {
isPrivateWindow: state.isPrivateWindow,
engine: state.isPrivateWindow
isPrivateEngine: state.isInPrivateBrowsingMode,
isAboutPrivateBrowsing: state.isAboutPrivateBrowsing,
engine: state.isInPrivateBrowsingMode
? state.currentPrivateEngine
: state.currentEngine,
});
...
...
browser/base/content/browser.js
View file @
0b1d9f92
...
...
@@ -1299,13 +1299,6 @@ var gKeywordURIFixup = {
let
hostName
=
fixedURI
.
displayHost
;
// and the ascii-only host for the pref:
let
asciiHost
=
fixedURI
.
asciiHost
;
// Normalize out a single trailing dot - NB: not using endsWith/lastIndexOf
// because we need to be sure this last dot is the *only* dot, too.
// More generally, this is used for the pref and should stay in sync with
// the code in URIFixup::KeywordURIFixup .
if
(
asciiHost
.
indexOf
(
"
.
"
)
==
asciiHost
.
length
-
1
)
{
asciiHost
=
asciiHost
.
slice
(
0
,
-
1
);
}
let
isIPv4Address
=
host
=>
{
let
parts
=
host
.
split
(
"
.
"
);
...
...
@@ -1371,7 +1364,15 @@ var gKeywordURIFixup = {
callback
()
{
// Do not set this preference while in private browsing.
if
(
!
PrivateBrowsingUtils
.
isWindowPrivate
(
window
))
{
let
pref
=
"
browser.fixup.domainwhitelist.
"
+
asciiHost
;
let
prefHost
=
asciiHost
;
// Normalize out a single trailing dot - NB: not using endsWith/lastIndexOf
// because we need to be sure this last dot is the *only* dot, too.
// More generally, this is used for the pref and should stay in sync with
// the code in URIFixup::KeywordURIFixup .
if
(
prefHost
.
indexOf
(
"
.
"
)
==
prefHost
.
length
-
1
)
{
prefHost
=
prefHost
.
slice
(
0
,
-
1
);
}
let
pref
=
"
browser.fixup.domainwhitelist.
"
+
prefHost
;
Services
.
prefs
.
setBoolPref
(
pref
,
true
);
}
openTrustedLinkIn
(
fixedURI
.
spec
,
"
current
"
);
...
...
@@ -1389,9 +1390,19 @@ var gKeywordURIFixup = {
},
};
// For dotless hostnames, we want to ensure this ends with a '.' but don't
// want the . showing up in the UI if we end up notifying the user, so we
// use a separate variable.
let
lookupName
=
hostName
;
if
(
UrlbarPrefs
.
get
(
"
dnsResolveFullyQualifiedNames
"
)
&&
!
lookupName
.
includes
(
"
.
"
)
)
{
lookupName
+=
"
.
"
;
}
try
{
gDNSService
.
asyncResolve
(
host
Name
,
lookup
Name
,
Ci
.
nsIDNSService
.
RESOLVE_TYPE_DEFAULT
,
0
,
null
,
...
...
@@ -4556,8 +4567,10 @@ function FillHistoryMenu(aParent) {
}
}
// If session history in parent is available, use it. Otherwise, get the session history
// from session store.
let
sessionHistory
=
gBrowser
.
selectedBrowser
.
browsingContext
.
sessionHistory
;
if
(
sessionHistory
)
{
if
(
sessionHistory
?.
count
)
{
// Don't show the context menu if there is only one item.
if
(
sessionHistory
.
count
<=
1
)
{
return
false
;
...
...
@@ -6651,6 +6664,7 @@ const nodeToTooltipMap = {
"
appMenu-zoomReset-button2
"
:
"
zoomReset-button.tooltip
"
,
"
appMenu-zoomReduce-button
"
:
"
zoomReduce-button.tooltip
"
,
"
appMenu-zoomReduce-button2
"
:
"
zoomReduce-button.tooltip
"
,
"
reader-mode-button
"
:
"
reader-mode-button.tooltip
"
,
"
reader-mode-button-icon
"
:
"
reader-mode-button.tooltip
"
,
"
print-button
"
:
"
printButton.tooltip
"
,
};
...
...
@@ -6677,6 +6691,7 @@ const nodeToShortcutMap = {
"
appMenu-zoomReset-button2
"
:
"
key_fullZoomReset
"
,
"
appMenu-zoomReduce-button
"
:
"
key_fullZoomReduce
"
,
"
appMenu-zoomReduce-button2
"
:
"
key_fullZoomReduce
"
,
"
reader-mode-button
"
:
"
key_toggleReaderMode
"
,
"
reader-mode-button-icon
"
:
"
key_toggleReaderMode
"
,
"
print-button
"
:
"
printKb
"
,
};
...
...
browser/base/content/test/backforward/browser_history_menu.js
View file @
0b1d9f92
...
...
@@ -12,6 +12,35 @@ add_task(async function contextmenu_back() {
await
testBackForwardMenu
(
true
);
});
async
function
openHistoryMenu
(
useContextMenu
)
{
let
backButton
=
document
.
getElementById
(
"
back-button
"
);
let
rect
=
backButton
.
getBoundingClientRect
();
info
(
"
waiting for the history menu to open
"
);
let
popupShownPromise
=
BrowserTestUtils
.
waitForEvent
(
useContextMenu
?
document
.
getElementById
(
"
backForwardMenu
"
)
:
backButton
,
"
popupshown
"
);
if
(
useContextMenu
)
{
EventUtils
.
synthesizeMouseAtCenter
(
backButton
,
{
type
:
"
contextmenu
"
,
button
:
2
,
});
}
else
{
EventUtils
.
synthesizeMouseAtCenter
(
backButton
,
{
type
:
"
mousedown
"
});
}
EventUtils
.
synthesizeMouse
(
backButton
,
rect
.
width
/
2
,
rect
.
height
,
{
type
:
"
mouseup
"
,
});
let
popupEvent
=
await
popupShownPromise
;
ok
(
true
,
"
history menu opened
"
);
return
popupEvent
;
}
async
function
testBackForwardMenu
(
useContextMenu
)
{
let
tab
=
await
BrowserTestUtils
.
openNewForegroundTab
(
gBrowser
,
...
...
@@ -40,30 +69,7 @@ async function testBackForwardMenu(useContextMenu) {
SessionStore
.
getSessionHistory
(
gBrowser
.
selectedTab
,
resolve
)
);
let
backButton
=
document
.
getElementById
(
"
back-button
"
);
let
rect
=
backButton
.
getBoundingClientRect
();
info
(
"
waiting for the history menu to open
"
);
let
popupShownPromise
=
BrowserTestUtils
.
waitForEvent
(
useContextMenu
?
document
.
getElementById
(
"
backForwardMenu
"
)
:
backButton
,
"
popupshown
"
);
if
(
useContextMenu
)
{
EventUtils
.
synthesizeMouseAtCenter
(
backButton
,
{
type
:
"
contextmenu
"
,
button
:
2
,
});
}
else
{
EventUtils
.
synthesizeMouseAtCenter
(
backButton
,
{
type
:
"
mousedown
"
});
}
EventUtils
.
synthesizeMouse
(
backButton
,
rect
.
width
/
2
,
rect
.
height
,
{
type
:
"
mouseup
"
,
});
let
popupEvent
=
await
popupShownPromise
;
ok
(
true
,
"
history menu opened
"
);
let
popupEvent
=
await
openHistoryMenu
(
useContextMenu
);
// Wait for the session data to be flushed before continuing the test
await
new
Promise
(
resolve
=>
...
...
@@ -133,3 +139,25 @@ async function testBackForwardMenu(useContextMenu) {
gBrowser
.
removeTab
(
tab
);
}
// Make sure that the history popup appears after navigating around in a preferences page.
add_task
(
async
function
test_preferences_page
()
{
let
tab
=
await
BrowserTestUtils
.
openNewForegroundTab
(
gBrowser
,
"
about:preferences
"
);
openPreferences
(
"
search
"
);
let
popupEvent
=
await
openHistoryMenu
(
true
);
is
(
popupEvent
.
target
.
children
.
length
,
2
,
"
Correct number of history items
"
);
let
popupHiddenPromise
=
BrowserTestUtils
.
waitForEvent
(
popupEvent
.
target
,
"
popuphidden
"
);
popupEvent
.
target
.
hidePopup
();
await
popupHiddenPromise
;
gBrowser
.
removeTab
(
tab
);
});
browser/base/content/test/performance/browser_startup_syncIPC.js
View file @
0b1d9f92
...
...
@@ -31,7 +31,7 @@ const startupPhases = {
"
before first paint
"
:
[
{
name
:
"
PLayerTransaction::Msg_GetTextureFactoryIdentifier
"
,
condition
:
(
MAC
&&
!
WEBRENDER
)
||
LINUX
,
condition
:
(
MAC
||
LINUX
)
&&
!
WEBRENDER
,
maxCount
:
1
,
},
{
...
...
@@ -46,7 +46,7 @@ const startupPhases = {
},
{
name
:
"
PWebRenderBridge::Msg_EnsureConnected
"
,
condition
:
MAC
&&
WEBRENDER
,
condition
:
(
MAC
||
LINUX
)
&&
WEBRENDER
,
maxCount
:
1
,
},
{
...
...
@@ -242,7 +242,7 @@ const startupPhases = {
},
{
name
:
"
PWebRenderBridge::Msg_EnsureConnected
"
,
condition
:
WIN
&&
WEBRENDER
,
condition
:
(
WIN
||
LINUX
)
&&
WEBRENDER
,
ignoreIfUnused
:
true
,
maxCount
:
1
,
},
...
...
browser/branding/aurora/configure.sh
View file @
0b1d9f92
...
...
@@ -5,3 +5,9 @@
MOZ_APP_DISPLAYNAME
=
"Firefox Developer Edition"
MOZ_APP_REMOTINGNAME
=
firefox-dev
MOZ_DEV_EDITION
=
1
# Devedition builds - use same as release channel
MOZ_HANDLER_CLSID
=
"1baa303d-b4b9-45e5-9ccb-e3fca3e274b6"
MOZ_IHANDLERCONTROL_IID
=
"ce30f77e-8847-44f0-a648-a9656bd89c0d"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"dca8d857-1a63-4045-8f36-8809eb093d04"
MOZ_IGECKOBACKCHANNEL_IID
=
"b32983ff-ef84-4945-8f86-fb7491b4f57b"
browser/branding/nightly/configure.sh
View file @
0b1d9f92
...
...
@@ -4,3 +4,8 @@
MOZ_APP_DISPLAYNAME
=
"Firefox Nightly"
MOZ_MACBUNDLE_ID
=
nightly
MOZ_HANDLER_CLSID
=
"4629216b-8753-41bf-9527-5bff51401671"
MOZ_IHANDLERCONTROL_IID
=
"c57343fc-e011-40c2-b748-da82eabf0f1f"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"648c92a1-ea35-46da-a806-6b55c6247373"
MOZ_IGECKOBACKCHANNEL_IID
=
"e61e038d-40dd-464a-9aba-66b206b6911b"
browser/branding/official/configure.sh
View file @
0b1d9f92
...
...
@@ -3,3 +3,17 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
MOZ_APP_DISPLAYNAME
=
Firefox
if
test
"
$MOZ_UPDATE_CHANNEL
"
=
"beta"
;
then
# Official beta builds
MOZ_HANDLER_CLSID
=
"21e9f98d-a6c9-4cb5-b288-ae2fd2a96c58"
MOZ_IHANDLERCONTROL_IID
=
"119149fa-d212-4f22-9517-082eecc1a084"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"4e253d9b-59cf-4b32-a973-38bc85495d61"
MOZ_IGECKOBACKCHANNEL_IID
=
"77b75c7d-d1c2-4469-864d-31aaebb67cc6"
else
# Official release/esr builds
MOZ_HANDLER_CLSID
=
"1baa303d-b4b9-45e5-9ccb-e3fca3e274b6"
MOZ_IHANDLERCONTROL_IID
=
"ce30f77e-8847-44f0-a648-a9656bd89c0d"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"dca8d857-1a63-4045-8f36-8809eb093d04"
MOZ_IGECKOBACKCHANNEL_IID
=
"b32983ff-ef84-4945-8f86-fb7491b4f57b"
fi
browser/branding/unofficial/configure.sh
View file @
0b1d9f92
...
...
@@ -3,3 +3,19 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
MOZ_APP_DISPLAYNAME
=
Nightly
if
test
"
$DEVELOPER_OPTIONS
"
;
then
if
test
"
$MOZ_DEBUG
"
;
then
# Local debug builds
MOZ_HANDLER_CLSID
=
"398ffd8d-5382-48f7-9e3b-19012762d39a"
MOZ_IHANDLERCONTROL_IID
=
"a218497e-8b10-460b-b668-a92b7ee39ff2"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"ca18b9ab-04b6-41be-87f7-d99913d6a2e8"
MOZ_IGECKOBACKCHANNEL_IID
=
"231c4946-4479-4c8e-aadc-8a0e48fc4c51"
else
# Local non-debug builds
MOZ_HANDLER_CLSID
=
"ce573faf-7815-4fc2-a031-b092268ace9e"
MOZ_IHANDLERCONTROL_IID
=
"2b715cce-1790-4fe1-aef5-48bb5acdf3a1"
MOZ_ASYNCIHANDLERCONTROL_IID
=
"8e089670-4f57-41a7-89c0-37f17482fa6f"
MOZ_IGECKOBACKCHANNEL_IID
=
"18e2488d-310f-400f-8339-0e50b513e801"
fi
fi
browser/components/enterprisepolicies/Policies.jsm
View file @
0b1d9f92
...
...
@@ -2423,6 +2423,14 @@ function installAddonFromURL(url, extensionID, addon) {
log
.
debug
(
`Installation succeeded - ${url}`
);
},
};
// If it's a local file install, onDownloadEnded is never called.
// So we call it manually, to handle some error cases.
if
(
url
.
startsWith
(
"file:"
))
{
listener
.
onDownloadEnded
(
install
);
if
(
install
.
state
==
AddonManager
.
STATE_CANCELLED
)
{
return
;
}
}
install
.
addListener
(
listener
);
install
.
install
();
});
...
...
browser/components/enterprisepolicies/tests/xpcshell/test_addon_update.js
View file @
0b1d9f92
...
...
@@ -45,7 +45,7 @@ add_task(async function test_local_addon_update() {
setupPolicyEngineWithJson
({
policies
:
{
ExtensionSettings
:
{
"
updatable@test
"
:
{
"
updatable
1
@test
"
:
{
installation_mode
:
"
force_installed
"
,
install_url
:
Services
.
io
.
newFileURI
(
tmpDir
).
spec
+
"
/
"
+
TEST_NAME
,
},
...
...
@@ -74,7 +74,7 @@ add_task(async function test_local_addon_update() {
setupPolicyEngineWithJson
({
policies
:
{
ExtensionSettings
:
{
"
updatable@test
"
:
{
"
updatable
1
@test
"
:
{
installation_mode
:
"
force_installed
"
,
install_url
:
Services
.
io
.
newFileURI
(
tmpDir
).
spec
+
"
/
"
+
TEST_NAME
,
},
...
...
browser/components/enterprisepolicies/tests/xpcshell/test_extensionsettings.js
View file @
0b1d9f92
...
...
@@ -19,6 +19,8 @@ const BASE_URL = `http://example.com/data`;
let
addonID
=
"
policytest2@mozilla.com
"
;
let
themeID
=
"
policytheme@mozilla.com
"
;
let
fileURL
;
add_task
(
async
function
setup
()
{
await
AddonTestUtils
.
promiseStartupManager
();
...
...
@@ -33,6 +35,9 @@ add_task(async function setup() {
});
server
.
registerFile
(
"
/data/policy_test.xpi
"
,
webExtensionFile
);
fileURL
=
Services
.
io
.
newFileURI
(
webExtensionFile
)
.
QueryInterface
(
Ci
.
nsIFileURL
);
});
add_task
(
async
function
test_extensionsettings
()
{
...
...
@@ -253,3 +258,34 @@ add_task(async function test_theme() {
let
addon
=
await
AddonManager
.
getAddonByID
(
themeID
);
await
addon
.
uninstall
();
});
add_task
(
async
function
test_addon_normalinstalled_file
()
{
await
Promise
.
all
([
AddonTestUtils
.
promiseInstallEvent
(
"
onInstallEnded
"
),
setupPolicyEngineWithJson
({
policies
:
{
ExtensionSettings
:
{
"
policytest2@mozilla.com
"
:
{
installation_mode
:
"
normal_installed
"
,
install_url
:
fileURL
.
spec
,
},
},
},
}),
]);
let
addon
=
await
AddonManager
.
getAddonByID
(
addonID
);
notEqual
(
addon
,
null
,
"
Addon should not be null
"
);
equal
(
addon
.
appDisabled
,
false
,
"
Addon should not be disabled
"
);
equal
(
addon
.
permissions
&
AddonManager
.
PERM_CAN_UNINSTALL
,
0
,
"
Addon should not be able to be uninstalled.
"
);
notEqual
(
addon
.
permissions
&
AddonManager
.
PERM_CAN_DISABLE
,
0
,
"
Addon should be able to be disabled.
"
);
await
addon
.
uninstall
();
});
browser/components/extensions/test/browser/browser.ini
View file @
0b1d9f92
...
...
@@ -45,7 +45,7 @@ support-files =
../../../../../toolkit/components/reader/test/readerModeNonArticle.html
../../../../../toolkit/components/reader/test/readerModeArticle.html
skip-if
=
fission
&&
os
=
= "linux" && asan # Bug 1713895 - new Fission platform triage
os
=
= "linux" && asan # Bug 1713895 - new Fission platform triage
os
=
= "win" && os_version == "6.1" && webrender # Bug 1717249
[browser_ExtensionControlledPopup.js]
...
...
browser/components/newtab/test/unit/asrouter/ASRouterTargeting.test.js
View file @
0b1d9f92
...
...
@@ -346,19 +346,17 @@ describe("#mainPingSubmissions", () => {
);
});
it
(
"
should allow for pings < 24hrs apart but on different days
"
,
async
()
=>
{
let
startTime
=
new
Date
(
"
2020-02-20
"
).
g
et
Time
(
);
let
oneDay
=
86400000
;
let
startTime
=
new
Date
().
s
et
Hours
(
0
);
let
previousDay
=
new
Date
(
startTime
-
60
*
60
*
1000
).
getTime
()
;
promiseArchivedPingList
=
sandbox
.
stub
().
resolves
([
{
id
:
"
5c8c786b-eca5-734b-a755-7ec0f022aaaa
"
,
// Using oneDay / 2 because timezone of browser running the test
// affects the calculation
timestampCreated
:
startTime
-
oneDay
/
2
,
timestampCreated
:
startTime
,
type
:
"
main
"
,
},
{
id
:
"
5c8c786b-eca5-734b-a755-7ec0f022aaac
"
,