Update patches and scripts

This commit is contained in:
Laura Hausmann 2023-11-03 22:07:07 +01:00
parent 9ca264d545
commit 1912b90bbd
Signed by untrusted user: zotan
GPG key ID: D044E84C5BE01605
7 changed files with 83 additions and 32 deletions

View file

@ -1,2 +0,0 @@
pref("general.config.filename", "prefs.js");
pref("general.config.obscure_value", 0);

View file

@ -7,8 +7,3 @@ FINAL_TARGET_FILES.distribution += [
"userChrome.css", "userChrome.css",
"userContent.css", "userContent.css",
] ]
# local-settings does not yet end up being pacakged.
FINAL_TARGET_FILES.defaults.pref += [
"local-settings.js",
]

View file

@ -9,7 +9,7 @@ git clean -fd
# Prepare assets # Prepare assets
mkdir -p snowleopard mkdir -p snowleopard
cp ../assets/mozconfig mozconfig cp ../assets/mozconfig mozconfig
cp ../assets/{local-settings.js,prefs.js,policies.json,moz.build,userChrome.css,userContent.css} snowleopard/ cp ../assets/{prefs.js,policies.json,moz.build,userChrome.css,userContent.css} snowleopard/
# Prepare patches # Prepare patches
for patch in ../patches/*.patch; do for patch in ../patches/*.patch; do

View file

@ -9,7 +9,7 @@ git clean -fd
# Prepare assets # Prepare assets
mkdir -p snowleopard mkdir -p snowleopard
cp ../assets/mozconfig mozconfig cp ../assets/mozconfig mozconfig
cp ../assets/{local-settings.js,prefs.js,policies.json,moz.build,userChrome.css,userContent.css} snowleopard/ cp ../assets/{prefs.js,policies.json,moz.build,userChrome.css,userContent.css} snowleopard/
# Set up crossbuild # Set up crossbuild
echo "" >> mozconfig echo "" >> mozconfig

View file

@ -1,5 +1,5 @@
diff --git a/dom/base/nsGlobalWindowCommands.cpp b/dom/base/nsGlobalWindowCommands.cpp diff --git a/dom/base/nsGlobalWindowCommands.cpp b/dom/base/nsGlobalWindowCommands.cpp
index 5dd631d1e4545..2a547db71a193 100644 index 5dd631d1e4545..c154d5b33735d 100644
--- a/dom/base/nsGlobalWindowCommands.cpp --- a/dom/base/nsGlobalWindowCommands.cpp
+++ b/dom/base/nsGlobalWindowCommands.cpp +++ b/dom/base/nsGlobalWindowCommands.cpp
@@ -80,6 +80,11 @@ constexpr const char* sEndLineString = "cmd_endLine"; @@ -80,6 +80,11 @@ constexpr const char* sEndLineString = "cmd_endLine";
@ -27,16 +27,41 @@ index 5dd631d1e4545..2a547db71a193 100644
nsresult nsSelectMoveScrollCommand::DoCommand(const char* aCommandName, nsresult nsSelectMoveScrollCommand::DoCommand(const char* aCommandName,
nsISupports* aCommandContext) { nsISupports* aCommandContext) {
@@ -426,6 +435,8 @@ static const struct SelectCommand { @@ -420,18 +429,21 @@ nsresult nsPhysicalSelectMoveScrollCommand::DoCommand(
&nsISelectionController::WordMove}, static const struct SelectCommand {
{Command::SelectBeginLine, Command::SelectEndLine, Command reverse, forward;
&nsISelectionController::IntraLineMove}, nsresult (NS_STDCALL nsISelectionController::*select)(bool, bool);
+ {Command::SelectBeginParagraph, Command::SelectEndParagraph, -} selectCommands[] = {{Command::SelectCharPrevious, Command::SelectCharNext,
+ &nsISelectionController::IntraParagraphMove}, - &nsISelectionController::CharacterMove},
{Command::SelectLinePrevious, Command::SelectLineNext, - {Command::SelectWordPrevious, Command::SelectWordNext,
&nsISelectionController::LineMove}, - &nsISelectionController::WordMove},
{Command::SelectPageUp, Command::SelectPageDown, - {Command::SelectBeginLine, Command::SelectEndLine,
@@ -1099,6 +1110,8 @@ nsresult nsWindowCommandRegistration::RegisterWindowCommands( - &nsISelectionController::IntraLineMove},
- {Command::SelectLinePrevious, Command::SelectLineNext,
- &nsISelectionController::LineMove},
- {Command::SelectPageUp, Command::SelectPageDown,
- &nsISelectionController::PageMove},
- {Command::SelectTop, Command::SelectBottom,
- &nsISelectionController::CompleteMove}};
+} selectCommands[] = {
+ {Command::SelectCharPrevious, Command::SelectCharNext,
+ &nsISelectionController::CharacterMove},
+ {Command::SelectWordPrevious, Command::SelectWordNext,
+ &nsISelectionController::WordMove},
+ {Command::SelectBeginLine, Command::SelectEndLine,
+ &nsISelectionController::IntraLineMove},
+ {Command::SelectBeginParagraph, Command::SelectEndParagraph,
+ &nsISelectionController::IntraParagraphMove},
+ {Command::SelectLinePrevious, Command::SelectLineNext,
+ &nsISelectionController::LineMove},
+ {Command::SelectPageUp, Command::SelectPageDown,
+ &nsISelectionController::PageMove},
+ {Command::SelectTop, Command::SelectBottom,
+ &nsISelectionController::CompleteMove}};
nsresult nsSelectCommand::DoCommand(const char* aCommandName,
nsISupports* aCommandContext) {
@@ -1099,6 +1111,8 @@ nsresult nsWindowCommandRegistration::RegisterWindowCommands(
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sWordNextString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sWordNextString);
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sBeginLineString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sBeginLineString);
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sEndLineString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sEndLineString);
@ -45,7 +70,7 @@ index 5dd631d1e4545..2a547db71a193 100644
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sMovePageUpString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sMovePageUpString);
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sMovePageDownString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sMovePageDownString);
NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sLinePreviousString); NS_REGISTER_NEXT_COMMAND(nsSelectMoveScrollCommand, sLinePreviousString);
@@ -1122,6 +1135,8 @@ nsresult nsWindowCommandRegistration::RegisterWindowCommands( @@ -1122,6 +1136,8 @@ nsresult nsWindowCommandRegistration::RegisterWindowCommands(
NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectWordNextString); NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectWordNextString);
NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectBeginLineString); NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectBeginLineString);
NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectEndLineString); NS_REGISTER_NEXT_COMMAND(nsSelectCommand, sSelectEndLineString);
@ -104,15 +129,16 @@ index fb2f5e8dc2964..0e9cd9183cadb 100644
TextInputSelectionController::PageMove(bool aForward, bool aExtend) { TextInputSelectionController::PageMove(bool aForward, bool aExtend) {
// expected behavior for PageMove is to scroll AND move the caret // expected behavior for PageMove is to scroll AND move the caret
diff --git a/editor/libeditor/EditorCommands.cpp b/editor/libeditor/EditorCommands.cpp diff --git a/editor/libeditor/EditorCommands.cpp b/editor/libeditor/EditorCommands.cpp
index beb4f060adc0f..b870e363035c1 100644 index beb4f060adc0f..7b87bd1191df2 100644
--- a/editor/libeditor/EditorCommands.cpp --- a/editor/libeditor/EditorCommands.cpp
+++ b/editor/libeditor/EditorCommands.cpp +++ b/editor/libeditor/EditorCommands.cpp
@@ -708,6 +708,8 @@ static const struct MoveCommand { @@ -708,6 +708,9 @@ static const struct MoveCommand {
Command::SelectWordNext, &nsISelectionController::WordMove}, Command::SelectWordNext, &nsISelectionController::WordMove},
{Command::BeginLine, Command::EndLine, Command::SelectBeginLine, {Command::BeginLine, Command::EndLine, Command::SelectBeginLine,
Command::SelectEndLine, &nsISelectionController::IntraLineMove}, Command::SelectEndLine, &nsISelectionController::IntraLineMove},
+ {Command::BeginParagraph, Command::EndParagraph, Command::SelectBeginParagraph, + {Command::BeginParagraph, Command::EndParagraph,
+ Command::SelectEndParagraph, &nsISelectionController::IntraParagraphMove}, + Command::SelectBeginParagraph, Command::SelectEndParagraph,
+ &nsISelectionController::IntraParagraphMove},
{Command::MovePageUp, Command::MovePageDown, Command::SelectPageUp, {Command::MovePageUp, Command::MovePageDown, Command::SelectPageUp,
Command::SelectPageDown, &nsISelectionController::PageMove}, Command::SelectPageDown, &nsISelectionController::PageMove},
{Command::MoveTop, Command::MoveBottom, Command::SelectTop, {Command::MoveTop, Command::MoveBottom, Command::SelectTop,
@ -226,7 +252,7 @@ index 1125ccdefaf1d..669cf4b8c2580 100644
case eSelectLine: case eSelectLine:
return false; return false;
diff --git a/layout/generic/nsIFrame.cpp b/layout/generic/nsIFrame.cpp diff --git a/layout/generic/nsIFrame.cpp b/layout/generic/nsIFrame.cpp
index 3a336b25278ae..c031d2ff1dcb5 100644 index 3a336b25278ae..bd6435a18d05e 100644
--- a/layout/generic/nsIFrame.cpp --- a/layout/generic/nsIFrame.cpp
+++ b/layout/generic/nsIFrame.cpp +++ b/layout/generic/nsIFrame.cpp
@@ -8879,6 +8879,60 @@ nsresult nsIFrame::PeekOffsetForParagraph(PeekOffsetStruct* aPos) { @@ -8879,6 +8879,60 @@ nsresult nsIFrame::PeekOffsetForParagraph(PeekOffsetStruct* aPos) {
@ -290,7 +316,7 @@ index 3a336b25278ae..c031d2ff1dcb5 100644
// Determine movement direction relative to frame // Determine movement direction relative to frame
static bool IsMovingInFrameDirection(const nsIFrame* frame, static bool IsMovingInFrameDirection(const nsIFrame* frame,
nsDirection aDirection, bool aVisual) { nsDirection aDirection, bool aVisual) {
@@ -9317,6 +9371,14 @@ nsresult nsIFrame::PeekOffset(PeekOffsetStruct* aPos) { @@ -9317,6 +9371,13 @@ nsresult nsIFrame::PeekOffset(PeekOffsetStruct* aPos) {
case eSelectBeginLine: case eSelectBeginLine:
case eSelectEndLine: case eSelectEndLine:
return PeekOffsetForLineEdge(aPos); return PeekOffsetForLineEdge(aPos);
@ -298,22 +324,23 @@ index 3a336b25278ae..c031d2ff1dcb5 100644
+ case eSelectEndParagraph: + case eSelectEndParagraph:
+ if (StaticPrefs::dom_input_textarea_caret_paragraph_movement()) { + if (StaticPrefs::dom_input_textarea_caret_paragraph_movement()) {
+ return PeekOffsetForParagraphEdge(aPos); + return PeekOffsetForParagraphEdge(aPos);
+ } + } else {
+ else {
+ return PeekOffsetForLineEdge(aPos); + return PeekOffsetForLineEdge(aPos);
+ } + }
case eSelectParagraph: case eSelectParagraph:
return PeekOffsetForParagraph(aPos); return PeekOffsetForParagraph(aPos);
default: { default: {
diff --git a/layout/generic/nsIFrame.h b/layout/generic/nsIFrame.h diff --git a/layout/generic/nsIFrame.h b/layout/generic/nsIFrame.h
index bbf3db4f70a3f..9608382c7f7fe 100644 index bbf3db4f70a3f..ca0dc2cd9c54c 100644
--- a/layout/generic/nsIFrame.h --- a/layout/generic/nsIFrame.h
+++ b/layout/generic/nsIFrame.h +++ b/layout/generic/nsIFrame.h
@@ -195,7 +195,9 @@ enum nsSelectionAmount { @@ -194,8 +194,10 @@ enum nsSelectionAmount {
eSelectBeginLine = 5, eSelectBeginLine = 5,
eSelectEndLine = 6, eSelectEndLine = 6,
eSelectNoAmount = 7, // just bounce back current offset. - eSelectNoAmount = 7, // just bounce back current offset.
- eSelectParagraph = 8 // select a "paragraph" - eSelectParagraph = 8 // select a "paragraph"
+ eSelectNoAmount = 7, // just bounce back current offset.
+ eSelectParagraph = 8, // select a "paragraph" + eSelectParagraph = 8, // select a "paragraph"
+ eSelectBeginParagraph = 9, + eSelectBeginParagraph = 9,
+ eSelectEndParagraph = 10 + eSelectEndParagraph = 10

View file

@ -0,0 +1,15 @@
diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in
index b3213b8c4498b..155d5cfbf8a12 100644
--- a/browser/installer/package-manifest.in
+++ b/browser/installer/package-manifest.in
@@ -265,6 +265,10 @@
; gre location for now.
@RESPATH@/defaults/pref/channel-prefs.js
+; Snowleopard specific
+@RESPATH@/distribution
+@RESPATH@/prefs.js
+
; Background tasks-specific preferences.
; These are in the GRE location since they apply to all tasks at this time.
#ifdef MOZ_BACKGROUNDTASKS

View file

@ -0,0 +1,16 @@
diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js
index 3fce1d2ecf152..5ff02ba2ec2d1 100644
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -75,7 +75,10 @@ pref("security.crash_tracking.js_load_1.maxCrashes", 1);
pref("general.useragent.compatMode.firefox", false);
-pref("general.config.obscure_value", 13); // for MCD .cfg files
+pref("general.config.filename", "prefs.js");
+pref("general.config.obscure_value", 0);
+lockPref("general.config.filename", "prefs.js");
+lockPref("general.config.obscure_value", 0);
#ifndef MOZ_BUILD_APP_IS_BROWSER
pref("general.warnOnAboutConfig", true);