mirror of
https://github.com/zen-browser/desktop.git
synced 2025-10-05 09:26:34 +00:00
Started checking for themes updates
This commit is contained in:
2
l10n
2
l10n
Submodule l10n updated: c92099b2d1...bfcfcf1aab
17
scripts/copy-language-pack.sh
Normal file
17
scripts/copy-language-pack.sh
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
browser_locales=engine/browser/locales
|
||||||
|
|
||||||
|
copy_browser_locales() {
|
||||||
|
langId=$1
|
||||||
|
mkdir -p $browser_locales/$langId
|
||||||
|
if [ "$langId" = "en-US" ]; then
|
||||||
|
find $browser_locales/$langId -type f -name "zen*" -delete
|
||||||
|
rsync -av --exclude=.git ./l10n/en-US/browser/ $browser_locales/$langId/
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
rm -rf $browser_locales/$langId/
|
||||||
|
rsync -av --exclude=.git ./l10n/$langId/ $browser_locales/$langId/
|
||||||
|
}
|
||||||
|
|
||||||
|
LANG=$1
|
||||||
|
echo "Copying language pack for $LANG"
|
||||||
|
copy_browser_locales $LANG
|
@@ -39,24 +39,14 @@ done
|
|||||||
cd $CURRENT_DIR
|
cd $CURRENT_DIR
|
||||||
|
|
||||||
# Move all the files to the correct location
|
# Move all the files to the correct location
|
||||||
browser_locales=engine/browser/locales
|
|
||||||
copy_browser_locales() {
|
|
||||||
langId=$1
|
|
||||||
only_en=$2
|
|
||||||
mkdir -p $browser_locales/$langId
|
|
||||||
if [ "$only_en" = true ]; then
|
|
||||||
rsync -av --exclude=.git ./l10n/en-US/browser/ $browser_locales/$langId/
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
rm -rf $browser_locales/$langId/
|
|
||||||
rsync -av --exclude=.git ./l10n/$langId/ $browser_locales/$langId/
|
|
||||||
}
|
|
||||||
|
|
||||||
copy_browser_locales en-US true
|
sh scripts/copy-language-pack.sh en-US
|
||||||
for lang in $(cat ./l10n/supported-languages); do
|
for lang in $(cat ./l10n/supported-languages); do
|
||||||
copy_browser_locales $lang false
|
sh scripts/copy-language-pack.sh $lang
|
||||||
done
|
done
|
||||||
|
|
||||||
|
wait
|
||||||
|
|
||||||
echo "Cleaning up"
|
echo "Cleaning up"
|
||||||
rm -rf ~/tools
|
rm -rf ~/tools
|
||||||
rm -rf ~/.git-cinnabar
|
rm -rf ~/.git-cinnabar
|
||||||
|
2
scripts/update-en-US-packs.sh
Normal file
2
scripts/update-en-US-packs.sh
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
|
||||||
|
sh ./scripts/copy-language-pack.sh en-US
|
Submodule src/browser/base/content/zen-components updated: 6bd08b136f...36306fd148
@@ -1,14 +1,15 @@
|
|||||||
diff --git a/browser/components/preferences/preferences.js b/browser/components/preferences/preferences.js
|
diff --git a/browser/components/preferences/preferences.js b/browser/components/preferences/preferences.js
|
||||||
index 7e21bab426b6eb52fe84876d817fddbdb1a35ffc..fb7c6f419c02701aecd148ef2fe271ed6f1a73c1 100644
|
index 7e21bab426b6eb52fe84876d817fddbdb1a35ffc..56b42e2d025e4a47ea0983cf33ae69ffafa0d576 100644
|
||||||
--- a/browser/components/preferences/preferences.js
|
--- a/browser/components/preferences/preferences.js
|
||||||
+++ b/browser/components/preferences/preferences.js
|
+++ b/browser/components/preferences/preferences.js
|
||||||
@@ -196,6 +196,9 @@ function init_all() {
|
@@ -196,6 +196,10 @@ function init_all() {
|
||||||
// the entire document.
|
// the entire document.
|
||||||
Preferences.queueUpdateOfAllElements();
|
Preferences.queueUpdateOfAllElements();
|
||||||
Services.telemetry.setEventRecordingEnabled("aboutpreferences", true);
|
Services.telemetry.setEventRecordingEnabled("aboutpreferences", true);
|
||||||
+ register_module("paneZenLooks", gZenLooksAndFeel);
|
+ register_module("paneZenLooks", gZenLooksAndFeel);
|
||||||
+ register_module("paneZenWorkspaces", gZenWorkspacesSettings);
|
+ register_module("paneZenWorkspaces", gZenWorkspacesSettings);
|
||||||
+ register_module("paneZenCKS", gZenCKSSettings);
|
+ register_module("paneZenCKS", gZenCKSSettings);
|
||||||
|
+ register_module("paneZenMarketplace", gZenMarketplaceManager);
|
||||||
|
|
||||||
register_module("paneGeneral", gMainPane);
|
register_module("paneGeneral", gMainPane);
|
||||||
register_module("paneHome", gHomePane);
|
register_module("paneHome", gHomePane);
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
diff --git a/browser/components/preferences/preferences.xhtml b/browser/components/preferences/preferences.xhtml
|
diff --git a/browser/components/preferences/preferences.xhtml b/browser/components/preferences/preferences.xhtml
|
||||||
index 3affb19d1a243da4a5782c9a4a5588d165b4119f..6fdc0c4447d2d43ee5f4563c725b6eca1cf7acc5 100644
|
index 3affb19d1a243da4a5782c9a4a5588d165b4119f..837f078ff1f3a65a40877c1380c6d050a8415bab 100644
|
||||||
--- a/browser/components/preferences/preferences.xhtml
|
--- a/browser/components/preferences/preferences.xhtml
|
||||||
+++ b/browser/components/preferences/preferences.xhtml
|
+++ b/browser/components/preferences/preferences.xhtml
|
||||||
@@ -43,6 +43,8 @@
|
@@ -43,6 +43,8 @@
|
||||||
@@ -24,7 +24,7 @@ index 3affb19d1a243da4a5782c9a4a5588d165b4119f..6fdc0c4447d2d43ee5f4563c725b6eca
|
|||||||
<!-- category list -->
|
<!-- category list -->
|
||||||
<richlistbox id="categories" data-l10n-id="category-list" data-l10n-attrs="aria-label">
|
<richlistbox id="categories" data-l10n-id="category-list" data-l10n-attrs="aria-label">
|
||||||
<richlistitem id="category-general"
|
<richlistitem id="category-general"
|
||||||
@@ -110,6 +118,39 @@
|
@@ -110,6 +118,50 @@
|
||||||
<label class="category-name" flex="1" data-l10n-id="pane-general-title"></label>
|
<label class="category-name" flex="1" data-l10n-id="pane-general-title"></label>
|
||||||
</richlistitem>
|
</richlistitem>
|
||||||
|
|
||||||
@@ -60,11 +60,22 @@ index 3affb19d1a243da4a5782c9a4a5588d165b4119f..6fdc0c4447d2d43ee5f4563c725b6eca
|
|||||||
+ <image class="category-icon"/>
|
+ <image class="category-icon"/>
|
||||||
+ <label class="category-name" flex="1" data-l10n-id="pane-zen-CKS-title"></label>
|
+ <label class="category-name" flex="1" data-l10n-id="pane-zen-CKS-title"></label>
|
||||||
+ </richlistitem>
|
+ </richlistitem>
|
||||||
|
+
|
||||||
|
+ <richlistitem id="category-zen-marketplace"
|
||||||
|
+ class="category"
|
||||||
|
+ value="paneZenMarketplace"
|
||||||
|
+ helpTopic="prefs-main"
|
||||||
|
+ data-l10n-id="category-zen-marketplace"
|
||||||
|
+ data-l10n-attrs="tooltiptext"
|
||||||
|
+ align="center">
|
||||||
|
+ <image class="category-icon"/>
|
||||||
|
+ <label class="category-name" flex="1" data-l10n-id="pane-zen-marketplace-title"></label>
|
||||||
|
+ </richlistitem>
|
||||||
+
|
+
|
||||||
<richlistitem id="category-home"
|
<richlistitem id="category-home"
|
||||||
class="category"
|
class="category"
|
||||||
value="paneHome"
|
value="paneHome"
|
||||||
@@ -228,11 +269,13 @@
|
@@ -228,11 +280,13 @@
|
||||||
<html:a href="about:policies" target="_blank" data-l10n-id="managed-notice"/>
|
<html:a href="about:policies" target="_blank" data-l10n-id="managed-notice"/>
|
||||||
</hbox>
|
</hbox>
|
||||||
</hbox>
|
</hbox>
|
||||||
@@ -78,13 +89,14 @@ index 3affb19d1a243da4a5782c9a4a5588d165b4119f..6fdc0c4447d2d43ee5f4563c725b6eca
|
|||||||
</hbox>
|
</hbox>
|
||||||
</hbox>
|
</hbox>
|
||||||
<vbox id="mainPrefPane">
|
<vbox id="mainPrefPane">
|
||||||
@@ -246,6 +289,9 @@
|
@@ -246,6 +300,10 @@
|
||||||
#include sync.inc.xhtml
|
#include sync.inc.xhtml
|
||||||
#include experimental.inc.xhtml
|
#include experimental.inc.xhtml
|
||||||
#include moreFromMozilla.inc.xhtml
|
#include moreFromMozilla.inc.xhtml
|
||||||
+#include zenLooksAndFeel.inc.xhtml
|
+#include zenLooksAndFeel.inc.xhtml
|
||||||
+#include zenKeyboardShortcuts.inc.xhtml
|
+#include zenKeyboardShortcuts.inc.xhtml
|
||||||
+#include zenWorkspaces.inc.xhtml
|
+#include zenWorkspaces.inc.xhtml
|
||||||
|
+#include zenMarketplace.inc.xhtml
|
||||||
</vbox>
|
</vbox>
|
||||||
</vbox>
|
</vbox>
|
||||||
</vbox>
|
</vbox>
|
||||||
|
@@ -23,8 +23,18 @@ const kZenOSToSmallName = {
|
|||||||
|
|
||||||
var gZenMarketplaceManager = {
|
var gZenMarketplaceManager = {
|
||||||
init() {
|
init() {
|
||||||
this._buildThemesList();
|
|
||||||
Services.prefs.addObserver(this.updatePref, this._buildThemesList.bind(this));
|
Services.prefs.addObserver(this.updatePref, this._buildThemesList.bind(this));
|
||||||
|
this._buildThemesList();
|
||||||
|
document.getElementById("zenThemeMarketplaceCheckForUpdates").addEventListener("click", (event) => {
|
||||||
|
this._checkForThemeUpdates(event);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
_checkForThemeUpdates(event) {
|
||||||
|
// Send a message to the child to check for theme updates.
|
||||||
|
event.target.disabled = true;
|
||||||
|
// send an event that will be listened by the child process.
|
||||||
|
document.dispatchEvent(new CustomEvent("ZenCheckForThemeUpdates"));
|
||||||
},
|
},
|
||||||
|
|
||||||
get updatePref() {
|
get updatePref() {
|
||||||
|
@@ -42,14 +42,6 @@
|
|||||||
</hbox>
|
</hbox>
|
||||||
|
|
||||||
<groupbox id="zenThemeGroup" data-category="paneZenLooks" hidden="true" class="highlighting-group">
|
<groupbox id="zenThemeGroup" data-category="paneZenLooks" hidden="true" class="highlighting-group">
|
||||||
<label><html:h2 data-l10n-id="zen-theme-marketplace-header"/></label>
|
|
||||||
<description class="description-deemphasized" data-l10n-id="zen-theme-marketplace-description" />
|
|
||||||
<hbox class="indent">
|
|
||||||
<html:a id="zenThemeMarketplaceLink" href="https://zen-browser.app/themes" target="_blank" data-l10n-id="zen-theme-marketplace-link" />
|
|
||||||
</hbox>
|
|
||||||
|
|
||||||
<vbox id="zenThemeMarketplaceList"></vbox>
|
|
||||||
|
|
||||||
<label><html:h2 data-l10n-id="zen-look-and-feel-buttons-header"/></label>
|
<label><html:h2 data-l10n-id="zen-look-and-feel-buttons-header"/></label>
|
||||||
<description class="description-deemphasized" data-l10n-id="zen-look-and-feel-buttons-description" />
|
<description class="description-deemphasized" data-l10n-id="zen-look-and-feel-buttons-description" />
|
||||||
|
|
||||||
|
20
src/browser/components/preferences/zenMarketplace.inc.xhtml
Normal file
20
src/browser/components/preferences/zenMarketplace.inc.xhtml
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
<html:template id="template-paneZenMarketplace">
|
||||||
|
<hbox id="ZenMarketplaceCategory"
|
||||||
|
class="subcategory"
|
||||||
|
hidden="true"
|
||||||
|
data-category="paneZenMarketplace">
|
||||||
|
<html:h1 data-l10n-id="pane-zen-marketplace-title"/>
|
||||||
|
</hbox>
|
||||||
|
|
||||||
|
<groupbox id="zenMarketplaceGroup" data-category="paneZenMarketplace" hidden="true" class="highlighting-group">
|
||||||
|
<label><html:h2 data-l10n-id="zen-theme-marketplace-header"/></label>
|
||||||
|
<description class="description-deemphasized" data-l10n-id="zen-theme-marketplace-description" />
|
||||||
|
<hbox class="indent">
|
||||||
|
<html:a id="zenThemeMarketplaceLink" href="https://zen-browser.app/themes" target="_blank" data-l10n-id="zen-theme-marketplace-link" />
|
||||||
|
<button id="zenThemeMarketplaceCheckForUpdates" data-l10n-id="zen-theme-marketplace-check-for-updates-button" />
|
||||||
|
</hbox>
|
||||||
|
|
||||||
|
<vbox id="zenThemeMarketplaceList"></vbox>
|
||||||
|
</groupbox>
|
||||||
|
|
||||||
|
</html:template>
|
@@ -314,6 +314,10 @@ groupbox h2 {
|
|||||||
|
|
||||||
/* THemes marketplace */
|
/* THemes marketplace */
|
||||||
|
|
||||||
|
#category-zen-marketplace > .category-icon {
|
||||||
|
list-style-image: url("chrome://mozapps/skin/extensions/category-themes.svg");
|
||||||
|
}
|
||||||
|
|
||||||
.zenThemeMarketplaceItem {
|
.zenThemeMarketplaceItem {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
||||||
@@ -342,6 +346,10 @@ groupbox h2 {
|
|||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#zenThemeMarketplaceCheckForUpdates {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
/* Disable mozilla's settings */
|
/* Disable mozilla's settings */
|
||||||
|
|
||||||
#dataCollectionCategory,
|
#dataCollectionCategory,
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
diff --git a/toolkit/modules/ActorManagerParent.sys.mjs b/toolkit/modules/ActorManagerParent.sys.mjs
|
diff --git a/toolkit/modules/ActorManagerParent.sys.mjs b/toolkit/modules/ActorManagerParent.sys.mjs
|
||||||
index 71409e58271802fc506999712519df63eff3b1a6..a136eb21a8abf1697b820ae4ab85224c56b725ec 100644
|
index 71409e58271802fc506999712519df63eff3b1a6..684c9da0139db1dc0962fbb50304ca4f013950ca 100644
|
||||||
--- a/toolkit/modules/ActorManagerParent.sys.mjs
|
--- a/toolkit/modules/ActorManagerParent.sys.mjs
|
||||||
+++ b/toolkit/modules/ActorManagerParent.sys.mjs
|
+++ b/toolkit/modules/ActorManagerParent.sys.mjs
|
||||||
@@ -666,6 +666,20 @@ if (!Services.prefs.getBoolPref("browser.pagedata.enabled", false)) {
|
@@ -666,6 +666,20 @@ if (!Services.prefs.getBoolPref("browser.pagedata.enabled", false)) {
|
||||||
@@ -16,7 +16,7 @@ index 71409e58271802fc506999712519df63eff3b1a6..a136eb21a8abf1697b820ae4ab85224c
|
|||||||
+ DOMContentLoaded: {},
|
+ DOMContentLoaded: {},
|
||||||
+ },
|
+ },
|
||||||
+ },
|
+ },
|
||||||
+ matches: ["https://*.zen-browser.app/*"],
|
+ matches: ["https://*.zen-browser.app/*", "about:preferences"],
|
||||||
+ allFrames: true,
|
+ allFrames: true,
|
||||||
+};
|
+};
|
||||||
+
|
+
|
||||||
|
Reference in New Issue
Block a user