Compare commits
No commits in common. "main" and "12.1" have entirely different histories.
|
|
@ -187,28 +187,6 @@ devtools/client/framework/test/code_ugly*
|
|||
devtools/server/tests/unit/babel_and_browserify_script_with_source_map.js
|
||||
devtools/server/tests/unit/setBreakpoint*
|
||||
|
||||
# mobile/android/ exclusions
|
||||
mobile/android/tests/
|
||||
|
||||
# Uses `#filter substitution`
|
||||
mobile/android/b2gdroid/app/b2gdroid.js
|
||||
mobile/android/app/mobile.js
|
||||
mobile/android/chrome/content/healthreport-prefs.js
|
||||
|
||||
# Uses `#expand`
|
||||
mobile/android/chrome/content/about.js
|
||||
|
||||
# Not much JS to lint and non-standard at that
|
||||
mobile/android/installer/
|
||||
mobile/android/locales/
|
||||
|
||||
# Non-standard `(catch ex if ...)`
|
||||
mobile/android/chrome/content/browser.js
|
||||
mobile/android/components/Snippets.js
|
||||
|
||||
# Bug 1178739: Ignore this file as a quick fix for "Illegal yield expression"
|
||||
mobile/android/modules/HomeProvider.jsm
|
||||
|
||||
# services/ exclusions
|
||||
|
||||
# Uses `#filter substitution`
|
||||
|
|
|
|||
4
.gitignore
vendored
|
|
@ -32,7 +32,6 @@ ID
|
|||
|
||||
obj-x86_64-pc-mingw32/
|
||||
obj-i686-pc-mingw32/
|
||||
autom4te.cache/
|
||||
|
||||
# Empty marker file that's generated when we check out NSS
|
||||
security/manager/.nss.checkout
|
||||
|
|
@ -95,9 +94,6 @@ GPATH
|
|||
# Git clone directory for updating web-platform-tests
|
||||
testing/web-platform/sync/
|
||||
|
||||
# Android Gradle artifacts.
|
||||
mobile/android/gradle/.gradle
|
||||
|
||||
# XCode project cruft
|
||||
embedding/ios/GoannaEmbed/GoannaEmbed.xcodeproj/project.xcworkspace/xcuserdata
|
||||
embedding/ios/GoannaEmbed/GoannaEmbed.xcodeproj/xcuserdata
|
||||
|
|
|
|||
15
.vscode/settings.json
vendored
|
|
@ -1,15 +0,0 @@
|
|||
{
|
||||
"git.ignoreLimitWarning": true,
|
||||
"chat.tools.terminal.autoApprove": {
|
||||
"ForEach-Object": true,
|
||||
"Get-Item": true,
|
||||
"Test-Path": true,
|
||||
"mkdir": true,
|
||||
"cp": true,
|
||||
"hdiutil": true,
|
||||
"&": true
|
||||
},
|
||||
"files.associations": {
|
||||
"limits.h": "c"
|
||||
}
|
||||
}
|
||||
41
README.md
|
|
@ -1,41 +1,22 @@
|
|||
<img src="browser/branding/unofficial/content/about-wordmark.svg" alt="Dactyloidae web browser" height="60">
|
||||
<br>
|
||||
<img src="application/basilisk/branding/unofficial/content/about-wordmark.svg">
|
||||
<h2>Dactyloidae web browser</h2>
|
||||
<a href="https://discord.gg/ecx">Official Discord server</a>
|
||||
<br><br>
|
||||
<img src="https://dactyloidae.xyz/demo.jpg" height="500">
|
||||
<img src="readme/newtab.png">
|
||||
|
||||
Dactyloidae is a heavily modified fork of Eclipse Hydra (fork of roytam1's Serpent, which is a fork of Basilisk, which is a fork of Firefox).
|
||||
Dactyloidae is a fork of Eclipse Lun3r (fork of Pale Moon made for Windows XP).
|
||||
|
||||
Some advantages over upstream, roytam1's Serpent, Eclipse Hydra and Firefox are:
|
||||
- More optimizations (SSE2, with additional boosts for future CPUs coming soon)
|
||||
- Better interoperability with upstream (using SQL storage instead of DBM)
|
||||
Some advantages over upstream, roytam1's New Moon and Lun3r are:
|
||||
- More optimzations
|
||||
- Better interoperability with upstream. (using SQL storage intead of DBM)
|
||||
- More modern theme
|
||||
- Better e10s support
|
||||
- Support for extensions in the Chrome and Edge Web Store (soon)
|
||||
- Support for extensions released for both Pale Moon, Basilisk and Firefox
|
||||
- WebExtensions support comparable to Firefox ESR 78
|
||||
- Literally being the fastest XUL browser (33.7 in Speedometer 2.1 compared to 22.4 in Pale Moon 34.2 AVX2)
|
||||
- Re-add support for iOS, Android, Windows 2000 and later, NetBSD (soon OpenBSD)
|
||||
|
||||
## Interested in running Dactyloidae in Win9x?
|
||||
We (as in I) reccomend using Palefill to potentially fix any browser issues:
|
||||
<a href="https://github.com/martok/palefill/releases">Download it here</a>
|
||||
|
||||
Get DactJump alongside Dactyloidae if you want to use it on 9x.
|
||||
|
||||
<a href="https://repo.dactyloidae.xyz/Dactyloidae/DactJump/">Get it here.</a>
|
||||
## Credits
|
||||
@Eclipse-Community for original code
|
||||
|
||||
If I've forgotten to put your name here, please let me know and I'll add it.
|
||||
|
||||
- [Feodor2](https://github.com/Feodor2) - Portable mode, theme fixes, and more from Mypal and Mypal68.
|
||||
- [Librewolf Developers](https://codeberg.org/librewolf) - Privacy tweaks from Librewolf. (Has not been implemented yet)
|
||||
- [BlueySoft (goober)](https://blueyheeler.xyz/) - Branding visuals, icons and fancy text.
|
||||
- [White Star](https://github.com/dbsoft/White-Star) - Helping with porting platform to Darwin PowerPC.
|
||||
|
||||
Major core browser engine contributions:
|
||||
- [Stossy11](https://www.github.com/stossy11) - Helping to develop and fix the macOS build.
|
||||
- [Eclipse Community](https://www.github.com/Eclipse-Community/UXP) - For creating Hydra and Lun3r, the bases of this fork.
|
||||
- [Loongson Hobbists' community](https://loongfans.cn/en/) - Providing a LoongArch VM and general assistance in porting to LoongArch64
|
||||
- [Basilisk-Dev](https://repo.palemoon.org/Basilisk-Dev) - For supporting and maintaining Basilisk, aswell as general advice for developing this browser.
|
||||
- [roytam1](https://github.com/roytam1) - Windows XP support code, e10s, WebExtensions, and more for UXP.
|
||||
- [Moonchild Productions](https://repo.palemoon.org/MoonchildProductions) - For creating the Unified XUL Platform and Basilisk, the core of this project.
|
||||
- [Mozilla Developers](https://github.com/mozilla-firefox) - Firefox ESR 52 browser base.
|
||||
@SoftBluey for logo seen in README and About
|
||||
|
|
|
|||
|
|
@ -4,8 +4,7 @@
|
|||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
if CONFIG['COMPILE_ENVIRONMENT']:
|
||||
if CONFIG['CC_TYPE'] == 'msvc':
|
||||
DIRS += ['typelib']
|
||||
DIRS += ['typelib']
|
||||
|
||||
# With --disable-accessibility, we need to compile PDocAccessible.ipdl (which
|
||||
# also depends on COMPtrTypes.h), but not the C++.
|
||||
|
|
|
|||
|
|
@ -3,11 +3,10 @@
|
|||
# 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/.
|
||||
|
||||
if CONFIG['CC_TYPE'] == 'msvc':
|
||||
FINAL_TARGET_FILES += [
|
||||
'!Accessible.tlb',
|
||||
]
|
||||
FINAL_TARGET_FILES += [
|
||||
'!Accessible.tlb',
|
||||
]
|
||||
|
||||
GENERATED_FILES += [
|
||||
'Accessible.tlb',
|
||||
]
|
||||
GENERATED_FILES += [
|
||||
'Accessible.tlb',
|
||||
]
|
||||
|
|
|
|||
|
|
@ -64,9 +64,7 @@ this.AccessFu = { // jshint ignore:line
|
|||
if (this._enabled) {
|
||||
this._disable();
|
||||
}
|
||||
if (Utils.MozBuildApp === 'mobile/android') {
|
||||
Services.obs.removeObserver(this, 'Accessibility:Settings');
|
||||
} else if (Utils.win.navigator.mozSettings) {
|
||||
if (Utils.win.navigator.mozSettings) {
|
||||
Utils.win.navigator.mozSettings.removeObserver(
|
||||
SCREENREADER_SETTING, this.handleEvent);
|
||||
}
|
||||
|
|
@ -585,11 +583,7 @@ var Output = {
|
|||
|
||||
get androidBridge() {
|
||||
delete this.androidBridge;
|
||||
if (Utils.MozBuildApp === 'mobile/android') {
|
||||
this.androidBridge = Services.androidBridge;
|
||||
} else {
|
||||
this.androidBridge = null;
|
||||
}
|
||||
this.androidBridge = null;
|
||||
return this.androidBridge;
|
||||
},
|
||||
|
||||
|
|
@ -815,12 +809,6 @@ var Input = {
|
|||
target.blur();
|
||||
}
|
||||
}
|
||||
|
||||
if (Utils.MozBuildApp == 'mobile/android') {
|
||||
// Return focus to native Android browser chrome.
|
||||
Services.androidBridge.handleGeckoMessage(
|
||||
{ type: 'ToggleChrome:Focus' });
|
||||
}
|
||||
break;
|
||||
case aEvent.DOM_VK_RETURN:
|
||||
if (this.editState.editing) {
|
||||
|
|
@ -837,18 +825,9 @@ var Input = {
|
|||
},
|
||||
|
||||
moveToPoint: function moveToPoint(aRule, aX, aY) {
|
||||
// XXX: Bug 1013408 - There is no alignment between the chrome window's
|
||||
// viewport size and the content viewport size in Android. This makes
|
||||
// sending mouse events beyond its bounds impossible.
|
||||
if (Utils.MozBuildApp === 'mobile/android') {
|
||||
let mm = Utils.getMessageManager(Utils.CurrentBrowser);
|
||||
mm.sendAsyncMessage('AccessFu:MoveToPoint',
|
||||
{rule: aRule, x: aX, y: aY, origin: 'top'});
|
||||
} else {
|
||||
let win = Utils.win;
|
||||
Utils.winUtils.sendMouseEvent('mousemove',
|
||||
aX - win.mozInnerScreenX, aY - win.mozInnerScreenY, 0, 0, 0);
|
||||
}
|
||||
let win = Utils.win;
|
||||
Utils.winUtils.sendMouseEvent('mousemove',
|
||||
aX - win.mozInnerScreenX, aY - win.mozInnerScreenY, 0, 0, 0);
|
||||
},
|
||||
|
||||
moveCursor: function moveCursor(aAction, aRule, aInputType, aAdjustRange) {
|
||||
|
|
|
|||
|
|
@ -76,8 +76,6 @@ const EDGE = 0.1;
|
|||
const TIMEOUT_MULTIPLIER = 1;
|
||||
// A single pointer down/up sequence periodically precedes the tripple swipe
|
||||
// gesture on Android. This delay acounts for that.
|
||||
const IS_ANDROID = Utils.MozBuildApp === 'mobile/android' &&
|
||||
Utils.AndroidSdkVersion >= 14;
|
||||
|
||||
/**
|
||||
* A point object containing distance travelled data.
|
||||
|
|
@ -206,7 +204,7 @@ this.GestureTracker = { // jshint ignore:line
|
|||
if (aDetail.type !== 'pointerdown') {
|
||||
return;
|
||||
}
|
||||
let GestureConstructor = aGesture || (IS_ANDROID ? DoubleTap : Tap);
|
||||
let GestureConstructor = aGesture || Tap;
|
||||
this._create(GestureConstructor);
|
||||
this._update(aDetail, aTimeStamp);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -680,7 +680,6 @@ this.Presentation = { // jshint ignore:line
|
|||
get presenters() {
|
||||
delete this.presenters;
|
||||
let presenterMap = {
|
||||
'mobile/android': [VisualPresenter, AndroidPresenter],
|
||||
'b2g': [VisualPresenter, B2GPresenter],
|
||||
'browser': [VisualPresenter, B2GPresenter, AndroidPresenter]
|
||||
};
|
||||
|
|
|
|||
|
|
@ -33,9 +33,7 @@ this.Utils = { // jshint ignore:line
|
|||
_buildAppMap: {
|
||||
'{3c2e2abc-06d4-11e1-ac3b-374f68613e61}': 'b2g',
|
||||
'{d1bfe7d9-c01e-4237-998b-7b5f960a4314}': 'graphene',
|
||||
'{ec8030f7-c20a-464f-9b0e-13a3a9e97384}': 'browser',
|
||||
'{aa3c5121-dab2-40e2-81ca-7ea25febc110}': 'mobile/android',
|
||||
'{a23983c0-fd0e-11dc-95ff-0800200c9a66}': 'mobile/xul'
|
||||
'{ec8030f7-c20a-464f-9b0e-13a3a9e97384}': 'browser'
|
||||
},
|
||||
|
||||
init: function Utils_init(aWindow) {
|
||||
|
|
|
|||
14
application/basilisk/app.mozbuild
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
# 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/.
|
||||
|
||||
include('/toolkit/toolkit.mozbuild')
|
||||
|
||||
if CONFIG['MOZ_EXTENSIONS']:
|
||||
DIRS += ['/extensions']
|
||||
|
||||
DIRS += ['/%s' % CONFIG['MOZ_BRANDING_DIRECTORY']]
|
||||
|
||||
# Never add dirs after the browser root because they apparently won't
|
||||
# get packaged properly on Mac.
|
||||
DIRS += ['/application/basilisk']
|
||||
|
|
@ -25,7 +25,7 @@ RemotingName=@MOZ_APP_REMOTINGNAME@
|
|||
#ifdef MOZ_APP_DISPLAYNAME
|
||||
CodeName=@MOZ_APP_DISPLAYNAME@
|
||||
#endif
|
||||
Version=52.9.0
|
||||
Version=52.11.0
|
||||
#ifdef MOZ_APP_PROFILE
|
||||
Profile=@MOZ_APP_PROFILE@
|
||||
#endif
|
||||
44
application/basilisk/app/hydra.exe.manifest
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity
|
||||
version="1.0.0.0"
|
||||
processorArchitecture="*"
|
||||
name="Eclipse Hydra"
|
||||
type="win32"
|
||||
/>
|
||||
<description>Eclipse Hydra</description>
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Microsoft.Windows.Common-Controls"
|
||||
version="6.0.0.0"
|
||||
processorArchitecture="*"
|
||||
publicKeyToken="6595b64144ccf1df"
|
||||
language="*"
|
||||
/>
|
||||
</dependentAssembly>
|
||||
</dependency>
|
||||
<ms_asmv3:trustInfo xmlns:ms_asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<ms_asmv3:security>
|
||||
<ms_asmv3:requestedPrivileges>
|
||||
<ms_asmv3:requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||
</ms_asmv3:requestedPrivileges>
|
||||
</ms_asmv3:security>
|
||||
</ms_asmv3:trustInfo>
|
||||
<ms_asmv3:application xmlns:ms_asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<ms_asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
|
||||
<dpiAware>True/PM</dpiAware>
|
||||
<dpiAwareness xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">PerMonitorV2,PerMonitor</dpiAwareness>
|
||||
</ms_asmv3:windowsSettings>
|
||||
</ms_asmv3:application>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
|
||||
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
|
||||
</application>
|
||||
</compatibility>
|
||||
</assembly>
|
||||
8
application/basilisk/app/module.ver
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
WIN32_MODULE_COMPANYNAME=@MOZ_APP_VENDOR@
|
||||
WIN32_MODULE_COPYRIGHT=©Eclipse Community, Basilisk and Mozilla Developers; available under the MPL 2 license.
|
||||
WIN32_MODULE_PRODUCTVERSION=@MOZ_APP_WINVERSION@
|
||||
WIN32_MODULE_PRODUCTVERSION_STRING=@MOZ_APP_VERSION@
|
||||
WIN32_MODULE_TRADEMARKS=The Hydra logo and project names are trademarks of Eclipse Community.
|
||||
WIN32_MODULE_DESCRIPTION=@MOZ_APP_DISPLAYNAME@ web browser
|
||||
WIN32_MODULE_PRODUCTNAME=@MOZ_APP_DISPLAYNAME@
|
||||
WIN32_MODULE_NAME=@MOZ_APP_DISPLAYNAME@
|
||||
|
|
@ -7,9 +7,9 @@
|
|||
#include "mozilla/AppData.h"
|
||||
#include "application.ini.h"
|
||||
#include "nsXPCOMGlue.h"
|
||||
#include <stdlib.h>
|
||||
#if defined(XP_WIN)
|
||||
#include <windows.h>
|
||||
#include <stdlib.h>
|
||||
#elif defined(XP_UNIX)
|
||||
#include <sys/resource.h>
|
||||
#include <unistd.h>
|
||||
|
|
@ -446,15 +446,6 @@ pref("browser.ghostbuster.enabled", true);
|
|||
// misbehave. Should also avoid spurious GCs during ghostbusting.
|
||||
pref("javascript.options.gc_on_memory_pressure", false);
|
||||
|
||||
pref("javascript.options.baselinejit.unsafe_eager_compilation", false);
|
||||
pref("javascript.options.ion.unsafe_eager_compilation", false);
|
||||
pref("javascript.options.baselinejit.threshold", 4);
|
||||
pref("javascript.options.ion.threshold", 25);
|
||||
pref("javascript.options.mem.high_water_mark", 256);
|
||||
pref("javascript.options.mem.gc_incremental", false);
|
||||
pref("javascript.options.mem.gc_compacting", false);
|
||||
pref("javascript.options.mem.gc_incremental_slice_ms", 40);
|
||||
|
||||
// This is the pref to control the location bar, change this to true to
|
||||
// force this - this makes the origin of popup windows more obvious to avoid
|
||||
// spoofing. We would rather not do it by default because it affects UE for web
|
||||
|
|
@ -595,7 +586,6 @@ pref("mousewheel.with_win.action", 1);
|
|||
|
||||
pref("browser.xul.error_pages.enabled", true);
|
||||
pref("browser.xul.error_pages.expert_bad_cert", false);
|
||||
pref("browser.theme.mode", "system");
|
||||
|
||||
// Enable captive portal detection.
|
||||
pref("network.captive-portal-service.enabled", true);
|
||||
|
|
@ -683,7 +673,11 @@ pref("browser.download.hide_plugins_without_extensions", true);
|
|||
// 0 goes Back/Forward
|
||||
// 1 act like PgUp/PgDown
|
||||
// 2 and other values, nothing
|
||||
#ifdef UNIX_BUT_NOT_MAC
|
||||
pref("browser.backspace_action", 2);
|
||||
#else
|
||||
pref("browser.backspace_action", 0);
|
||||
#endif
|
||||
|
||||
// this will automatically enable inline spellchecking (if it is available) for
|
||||
// editable elements in HTML
|
||||
|
|
@ -918,14 +912,8 @@ pref("browser.flash-protected-mode-flip.done", false);
|
|||
pref("dom.ipc.shims.enabledWarnings", false);
|
||||
|
||||
// Start the browser in e10s mode
|
||||
pref("browser.tabs.remote.autostart", true);
|
||||
pref("browser.tabs.remote.force-enable", true);
|
||||
pref("browser.tabs.remote.force-disable", false);
|
||||
pref("browser.tabs.remote.autostart", false);
|
||||
pref("browser.tabs.remote.desktopbehavior", true);
|
||||
pref("browser.tabs.remote.ignoreBlockPolicy", true);
|
||||
// Number of web content processes used by e10s.
|
||||
// Keep this at a fixed value in this tree; automatic -1 mode is not supported.
|
||||
pref("dom.ipc.processCount", 4);
|
||||
|
||||
// This pref governs whether we attempt to work around problems caused by
|
||||
// plugins using OS calls to manipulate the cursor while running out-of-
|
||||
|
|
@ -1225,11 +1213,6 @@ pref("browser.cache.frecency_experiment", -1);
|
|||
// Enable GMP support in the addon manager.
|
||||
pref("media.gmp-provider.enabled", true);
|
||||
|
||||
// On MacOS 10.6 and earlier, enable the window resize grip
|
||||
#ifdef XP_MACOSX
|
||||
pref("ui.mouse.resize_grip", true);
|
||||
#endif
|
||||
|
||||
// Enable Contextual Identity Containers
|
||||
#ifdef NIGHTLY_BUILD
|
||||
pref("privacy.userContext.enabled", true);
|
||||
|
|
@ -1253,8 +1236,10 @@ pref("browser.tabs.remote.autostart.2", true);
|
|||
pref("extensions.interposition.enabled", true);
|
||||
pref("extensions.interposition.prefetching", true);
|
||||
|
||||
// Keep e10s enabled even when legacy add-ons are present.
|
||||
pref("extensions.e10sBlocksEnabling", false);
|
||||
// Enable blocking of e10s for add-on users on beta/release.
|
||||
#ifdef RELEASE_OR_BETA
|
||||
pref("extensions.e10sBlocksEnabling", true);
|
||||
#endif
|
||||
|
||||
// How often to check for CPOW timeouts. CPOWs are only timed out by
|
||||
// the hang monitor.
|
||||
44
application/basilisk/app/serpent.exe.manifest
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity
|
||||
version="1.0.0.0"
|
||||
processorArchitecture="*"
|
||||
name="Serpent"
|
||||
type="win32"
|
||||
/>
|
||||
<description>Serpent</description>
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Microsoft.Windows.Common-Controls"
|
||||
version="6.0.0.0"
|
||||
processorArchitecture="*"
|
||||
publicKeyToken="6595b64144ccf1df"
|
||||
language="*"
|
||||
/>
|
||||
</dependentAssembly>
|
||||
</dependency>
|
||||
<ms_asmv3:trustInfo xmlns:ms_asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<ms_asmv3:security>
|
||||
<ms_asmv3:requestedPrivileges>
|
||||
<ms_asmv3:requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||
</ms_asmv3:requestedPrivileges>
|
||||
</ms_asmv3:security>
|
||||
</ms_asmv3:trustInfo>
|
||||
<ms_asmv3:application xmlns:ms_asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<ms_asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
|
||||
<dpiAware>True/PM</dpiAware>
|
||||
<dpiAwareness xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">PerMonitorV2,PerMonitor</dpiAwareness>
|
||||
</ms_asmv3:windowsSettings>
|
||||
</ms_asmv3:application>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
|
||||
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
|
||||
</application>
|
||||
</compatibility>
|
||||
</assembly>
|
||||
97
application/basilisk/base/content/aboutDialog.css
Normal file
|
|
@ -0,0 +1,97 @@
|
|||
/* 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/. */
|
||||
|
||||
#aboutDialog {
|
||||
width: 620px;
|
||||
/* Set an explicit line-height to avoid discrepancies in 'auto' spacing
|
||||
across screens with different device DPI, which may cause font metrics
|
||||
to round differently. */
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
#rightBox {
|
||||
background-image: url("chrome://branding/content/about-wordmark.svg");
|
||||
background-repeat: no-repeat;
|
||||
/* padding-top creates room for the wordmark */
|
||||
padding-top: 38px;
|
||||
margin-top:20px;
|
||||
}
|
||||
|
||||
#rightBox:-moz-locale-dir(rtl) {
|
||||
background-position: 100% 0;
|
||||
}
|
||||
|
||||
#bottomBox {
|
||||
padding: 15px 10px 0;
|
||||
}
|
||||
|
||||
#version {
|
||||
font-weight: bold;
|
||||
margin-top: 10px;
|
||||
margin-left: 0;
|
||||
-moz-user-select: text;
|
||||
-moz-user-focus: normal;
|
||||
cursor: text;
|
||||
}
|
||||
|
||||
#version:-moz-locale-dir(rtl) {
|
||||
direction: ltr;
|
||||
text-align: right;
|
||||
margin-left: 5px;
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
#releasenotes {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
#distribution,
|
||||
#distributionId {
|
||||
display: none;
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.text-blurb {
|
||||
margin-bottom: 10px;
|
||||
margin-inline-start: 0;
|
||||
padding-inline-start: 0;
|
||||
}
|
||||
|
||||
#updateButton,
|
||||
#updateDeck > hbox > label {
|
||||
margin-inline-start: 0;
|
||||
padding-inline-start: 0;
|
||||
}
|
||||
|
||||
.update-throbber {
|
||||
width: 16px;
|
||||
min-height: 16px;
|
||||
margin-inline-end: 3px;
|
||||
list-style-image: url("chrome://global/skin/icons/loading.png");
|
||||
}
|
||||
|
||||
@media (min-resolution: 1.1dppx) {
|
||||
.update-throbber {
|
||||
list-style-image: url("chrome://global/skin/icons/loading@2x.png");
|
||||
}
|
||||
}
|
||||
|
||||
description > .text-link,
|
||||
description > .text-link:focus {
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
.bottom-link,
|
||||
.bottom-link:focus {
|
||||
text-align: center;
|
||||
margin: 0 40px;
|
||||
}
|
||||
|
||||
#currentChannel {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
|
@ -42,13 +42,16 @@
|
|||
#endif
|
||||
<vbox id="aboutDialogContainer">
|
||||
<hbox id="clientBox">
|
||||
<vbox id="leftBox" collapsed="true"/>
|
||||
<vbox id="rightBox" flex="1" align="center">
|
||||
<hbox align="baseline" pack="center">
|
||||
<vbox id="leftBox" flex="1"/>
|
||||
<vbox id="rightBox" flex="1">
|
||||
<hbox align="baseline">
|
||||
#ifdef HAVE_64BIT_BUILD
|
||||
#expand <label id="version">__MOZ_APP_VERSION_DISPLAY__ (64-bit)</label>
|
||||
#else
|
||||
#expand <label id="version">__MOZ_APP_VERSION_DISPLAY__ (32-bit)</label>
|
||||
#endif
|
||||
#ifndef NIGHTLY_BUILD
|
||||
<label id="releasenotes" class="text-link">&releaseNotes.link;</label>
|
||||
#endif
|
||||
</hbox>
|
||||
|
||||
|
|
@ -138,19 +141,13 @@
|
|||
#endif
|
||||
#else
|
||||
<description class="text-blurb" id="communityDesc">
|
||||
Dactyloidae is released by <label class="text-link" href="https://eclipse.cx">Eclipse Community</label>.
|
||||
</description>
|
||||
|
||||
<description class="text-blurb">
|
||||
Dactyloidae is based on the work of the UXP team, aswell as the work of the Mozilla developers.
|
||||
</description>
|
||||
|
||||
<description class="text-blurb">
|
||||
Learn <label class="text-link" useoriginprincipal="true" href="about:credits">who contributed</label> to this software.
|
||||
</description>
|
||||
|
||||
Dactyloidae is a custom browser, based on the best of Firefox.
|
||||
Dactyloidae is designed and maintained by multiple open-source contributors (OwnedByWuigi, Eclipse Community, RT1), working together to make better software around the globe.
|
||||
</description>
|
||||
|
||||
<description class="text-blurb" id="contributeDesc">
|
||||
If you wish to contribute, please consider helping out by getting involved in our development by tackling some of the issues found in our <label class="text-link" href="https://github.com/Eclipse-Community/Dactyloidae/">GitHub issue tracker</label>.
|
||||
If you wish to contribute, please consider helping out by getting involved in our development by tackling some of the issues found in our <label class="text-link" href="https://github.com/OwnedByWuigi/UXP/">GitHub issue tracker</label>.
|
||||
</description>
|
||||
#endif
|
||||
</vbox>
|
||||
|
Before Width: | Height: | Size: 9.6 KiB After Width: | Height: | Size: 9.6 KiB |
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.2 KiB |
|
|
@ -120,7 +120,6 @@ a {
|
|||
transition-property: background-color, border-color, box-shadow;
|
||||
transition-duration: 150ms;
|
||||
width: 50px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#searchSubmit:dir(rtl) {
|
||||
|
|
@ -400,45 +399,3 @@ body[narrow] #restorePreviousSession::before {
|
|||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
html {
|
||||
background-color: #1f2328;
|
||||
color: #f1f4f7;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #75bbff;
|
||||
}
|
||||
|
||||
#topSection h1 {
|
||||
color: #f1f4f7;
|
||||
}
|
||||
|
||||
#searchIcon {
|
||||
filter: invert(100%) brightness(1.05);
|
||||
}
|
||||
|
||||
#searchText {
|
||||
background: #2b3037 padding-box;
|
||||
border-color: #4b535d;
|
||||
color: #f1f4f7;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
#searchText[keepfocus],
|
||||
#searchText:focus,
|
||||
#searchText[autofocus] {
|
||||
border-color: #4aa3ff;
|
||||
}
|
||||
|
||||
#searchSubmit {
|
||||
background: url("chrome://browser/skin/search-arrow-go.svg#search-arrow-go-inverted") center center no-repeat, linear-gradient(#3e454f, #30363d) padding-box;
|
||||
border-color: #4b535d;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
#searchSubmit:dir(rtl) {
|
||||
background-image: url("chrome://browser/skin/search-arrow-go.svg#search-arrow-go-rtl-inverted"), linear-gradient(#3e454f, #30363d);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -27,10 +27,7 @@ window.addEventListener("pageshow", function () {
|
|||
// Delay search engine setup, cause browser.js::BrowserOnAboutPageLoad runs
|
||||
// later and may use asynchronous getters.
|
||||
window.gObserver.observe(document.documentElement, { attributes: true });
|
||||
let launcher = document.getElementById("launcher");
|
||||
if (launcher) {
|
||||
window.gObserver.observe(launcher, { attributes: true });
|
||||
}
|
||||
window.gObserver.observe(document.getElementById("launcher"), { attributes: true });
|
||||
fitToWidth();
|
||||
setupSearch();
|
||||
window.addEventListener("resize", fitToWidth);
|
||||
|
|
@ -75,22 +72,7 @@ window.addEventListener("keypress", ev => {
|
|||
|
||||
function onSearchSubmit(aEvent)
|
||||
{
|
||||
if (aEvent instanceof MouseEvent && gContentSearchController &&
|
||||
gContentSearchController.defaultEngine) {
|
||||
gContentSearchController.search(aEvent);
|
||||
return;
|
||||
}
|
||||
|
||||
// Fallback path for builds where ContentSearch mediation fails.
|
||||
let terms = searchText && searchText.value ? searchText.value.trim() : "";
|
||||
if (!terms) {
|
||||
return;
|
||||
}
|
||||
|
||||
document.dispatchEvent(new CustomEvent("AboutHomeSearch", {
|
||||
bubbles: true,
|
||||
detail: { searchString: terms },
|
||||
}));
|
||||
gContentSearchController.search(aEvent);
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -98,13 +80,10 @@ var gContentSearchController;
|
|||
|
||||
function setupSearch()
|
||||
{
|
||||
let searchSubmit = document.getElementById("searchSubmit");
|
||||
|
||||
// Set submit button label for when CSS background are disabled (e.g.
|
||||
// high contrast mode).
|
||||
searchSubmit.value =
|
||||
document.getElementById("searchSubmit").value =
|
||||
document.body.getAttribute("dir") == "ltr" ? "\u25B6" : "\u25C0";
|
||||
searchSubmit.addEventListener("click", onSearchSubmit, true);
|
||||
|
||||
// The "autofocus" attribute doesn't focus the form element
|
||||
// immediately when the element is first drawn, so the
|
||||
|
|
@ -120,14 +99,6 @@ function setupSearch()
|
|||
new ContentSearchUIController(searchText, searchText.parentNode,
|
||||
"abouthome", "homepage");
|
||||
}
|
||||
|
||||
searchText.addEventListener("keypress", function(event) {
|
||||
if (event.keyCode == event.DOM_VK_RETURN) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
onSearchSubmit(event);
|
||||
}
|
||||
}, true);
|
||||
}
|
||||
|
||||
/**
|
||||
51
application/basilisk/base/content/abouthome/aboutHome.xhtml
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<!-- 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/. -->
|
||||
|
||||
<!DOCTYPE html [
|
||||
<!ENTITY % htmlDTD
|
||||
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"DTD/xhtml1-strict.dtd">
|
||||
%htmlDTD;
|
||||
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
|
||||
%globalDTD;
|
||||
<!ENTITY % aboutHomeDTD SYSTEM "chrome://browser/locale/aboutHome.dtd">
|
||||
%aboutHomeDTD;
|
||||
<!ENTITY % browserDTD SYSTEM "chrome://browser/locale/browser.dtd" >
|
||||
%browserDTD;
|
||||
]>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>&abouthome.pageTitle;</title>
|
||||
|
||||
<link rel="icon" type="image/png" id="favicon"
|
||||
href="chrome://branding/content/icon32.png"/>
|
||||
<link rel="stylesheet" type="text/css" media="all"
|
||||
href="chrome://browser/content/contentSearchUI.css"/>
|
||||
<link rel="stylesheet" type="text/css" media="all" defer="defer"
|
||||
href="chrome://browser/content/abouthome/aboutHome.css"/>
|
||||
|
||||
<script type="text/javascript;version=1.8"
|
||||
src="chrome://browser/content/abouthome/aboutHome.js"/>
|
||||
<script type="text/javascript;version=1.8"
|
||||
src="chrome://browser/content/contentSearchUI.js"/>
|
||||
</head>
|
||||
|
||||
<body dir="&locale.dir;">
|
||||
<div class="spacer"/>
|
||||
<div id="topSection">
|
||||
<h1>Where to next?</h1>
|
||||
<div id="searchIconAndTextContainer">
|
||||
<div id="searchIcon"/>
|
||||
<input type="text" name="q" value="" id="searchText" maxlength="256"
|
||||
aria-label="&contentSearchInput.label;" autofocus="autofocus"/>
|
||||
<input id="searchSubmit" type="button" onclick="onSearchSubmit(event)"
|
||||
title="&contentSearchSubmit.tooltip;"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 3.7 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 898 B After Width: | Height: | Size: 898 B |
|
Before Width: | Height: | Size: 2 KiB After Width: | Height: | Size: 2 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 5.5 KiB After Width: | Height: | Size: 5.5 KiB |
|
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
|
Before Width: | Height: | Size: 7.1 KiB After Width: | Height: | Size: 7.1 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 4.7 KiB |
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 3.7 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 4.5 KiB |
|
|
@ -334,29 +334,6 @@ const gXPInstallObserver = {
|
|||
|
||||
messageString = gNavigatorBundle.getFormattedString(error, args);
|
||||
|
||||
if (install.error == AddonManager.ERROR_CORRUPT_FILE) {
|
||||
let detail = null;
|
||||
if (install.errorDetail !== undefined && install.errorDetail !== null) {
|
||||
detail = install.errorDetail;
|
||||
if (typeof detail != "string") {
|
||||
if (detail && typeof detail.message == "string" && detail.message) {
|
||||
detail = detail.message;
|
||||
} else {
|
||||
detail = String(detail);
|
||||
}
|
||||
}
|
||||
detail = detail.replace(/[\r\n\t]+/g, " ").trim();
|
||||
}
|
||||
|
||||
let detailString;
|
||||
if (detail) {
|
||||
detailString = gNavigatorBundle.getFormattedString("addonInstallErrorDetail", [detail]);
|
||||
} else {
|
||||
detailString = gNavigatorBundle.getFormattedString("addonInstallErrorDetailCode", [String(install.error)]);
|
||||
}
|
||||
messageString += " " + detailString;
|
||||
}
|
||||
|
||||
PopupNotifications.show(browser, notificationID, messageString, anchorID,
|
||||
action, null, options);
|
||||
|
||||
|
|
@ -17,12 +17,6 @@ var gGestureSupport = {
|
|||
_currentRotation: 0,
|
||||
_lastRotateDelta: 0,
|
||||
_rotateMomentumThreshold: .75,
|
||||
_magnifierOverlay: null,
|
||||
_magnifierCanvas: null,
|
||||
_magnifierZoom: 1,
|
||||
_magnifierCenterX: 0,
|
||||
_magnifierCenterY: 0,
|
||||
_magnifierSourceBrowser: null,
|
||||
|
||||
/**
|
||||
* Add or remove mouse gesture event listeners
|
||||
|
|
@ -90,7 +84,7 @@ var gGestureSupport = {
|
|||
let pinchPref = AppConstants.platform == "win"
|
||||
? def(25, 0)
|
||||
: def(150, 1);
|
||||
this._setupPinchGesture(aEvent, pinchPref);
|
||||
this._setupGesture(aEvent, "pinch", pinchPref, "out", "in");
|
||||
break;
|
||||
case "MozRotateGestureStart":
|
||||
aEvent.preventDefault();
|
||||
|
|
@ -105,10 +99,6 @@ var gGestureSupport = {
|
|||
aEvent.preventDefault();
|
||||
this._doAction(aEvent, ["tap"]);
|
||||
break;
|
||||
case "MozMagnifyGesture":
|
||||
aEvent.preventDefault();
|
||||
this._destroyMagnifierOverlay();
|
||||
break;
|
||||
case "MozRotateGesture":
|
||||
aEvent.preventDefault();
|
||||
this._doAction(aEvent, ["twist", "end"]);
|
||||
|
|
@ -278,174 +268,6 @@ var gGestureSupport = {
|
|||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Setup pinch gesture with full-screen magnifier overlay.
|
||||
*
|
||||
* @param aEvent
|
||||
* The magnify gesture start event
|
||||
* @param aPref
|
||||
* Preference object with threshold and latched settings
|
||||
*/
|
||||
_setupPinchGesture: function(aEvent, aPref) {
|
||||
let browser = gBrowser.selectedBrowser;
|
||||
if (!browser || !browser.contentWindow) {
|
||||
return this._setupGesture(aEvent, "pinch", aPref, "out", "in");
|
||||
}
|
||||
|
||||
this._magnifierSourceBrowser = browser;
|
||||
this._magnifierCenterX = aEvent.clientX || 0;
|
||||
this._magnifierCenterY = aEvent.clientY || 0;
|
||||
this._magnifierZoom = 1;
|
||||
this._createMagnifierOverlay();
|
||||
|
||||
// Setup the gesture with magnifier handler
|
||||
for (let [pref, def] of Object.entries(aPref))
|
||||
aPref[pref] = this._getPref("pinch." + pref, def);
|
||||
|
||||
let offset = 0;
|
||||
let latchDir = aEvent.delta > 0 ? 1 : -1;
|
||||
let isLatched = false;
|
||||
|
||||
this._doUpdate = (aEvent) => {
|
||||
offset += aEvent.delta;
|
||||
if (Math.abs(offset) > aPref["threshold"]) {
|
||||
let sameDir = (latchDir ^ offset) >= 0;
|
||||
if (!aPref["latched"] || (isLatched ^ sameDir)) {
|
||||
this._updateMagnifier(offset > 0 ? 1.2 : 0.833);
|
||||
isLatched = !isLatched;
|
||||
}
|
||||
offset = 0;
|
||||
}
|
||||
};
|
||||
|
||||
this._doUpdate(aEvent);
|
||||
},
|
||||
|
||||
/**
|
||||
* Create full-screen magnifier overlay.
|
||||
*/
|
||||
_createMagnifierOverlay: function() {
|
||||
if (this._magnifierOverlay)
|
||||
return;
|
||||
|
||||
try {
|
||||
let overlay = document.createElement("div");
|
||||
overlay.id = "gGestureSupport-magnifier-overlay";
|
||||
overlay.style.cssText = `
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #000;
|
||||
z-index: 2147483647;
|
||||
overflow: hidden;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
`;
|
||||
|
||||
let canvas = document.createElement("canvas");
|
||||
canvas.id = "gGestureSupport-magnifier-canvas";
|
||||
canvas.width = window.innerWidth;
|
||||
canvas.height = window.innerHeight;
|
||||
canvas.style.cssText = `
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
display: block;
|
||||
`;
|
||||
|
||||
overlay.appendChild(canvas);
|
||||
document.documentElement.appendChild(overlay);
|
||||
|
||||
this._magnifierOverlay = overlay;
|
||||
this._magnifierCanvas = canvas;
|
||||
this._drawMagnifier();
|
||||
} catch (e) {
|
||||
Cu.reportError("Magnifier overlay creation failed: " + e);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Update magnifier zoom level and redraw.
|
||||
*
|
||||
* @param aZoomMultiplier
|
||||
* Factor to multiply current zoom by (e.g., 1.2 for zoom in, 0.833 for zoom out)
|
||||
*/
|
||||
_updateMagnifier: function(aZoomMultiplier) {
|
||||
let minZoom = 1;
|
||||
let maxZoom = 5;
|
||||
this._magnifierZoom = Math.max(minZoom, Math.min(maxZoom, this._magnifierZoom * aZoomMultiplier));
|
||||
this._drawMagnifier();
|
||||
},
|
||||
|
||||
/**
|
||||
* Draw magnified content to canvas.
|
||||
*/
|
||||
_drawMagnifier: function() {
|
||||
if (!this._magnifierOverlay || !this._magnifierCanvas || !this._magnifierSourceBrowser)
|
||||
return;
|
||||
|
||||
try {
|
||||
let browser = this._magnifierSourceBrowser;
|
||||
let canvas = this._magnifierCanvas;
|
||||
|
||||
let ctx = canvas.getContext("2d");
|
||||
if (!ctx) return;
|
||||
|
||||
// Fill background black
|
||||
ctx.fillStyle = "#000000";
|
||||
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
||||
|
||||
// Save context state
|
||||
ctx.save();
|
||||
|
||||
// Calculate zoom magnification
|
||||
let zoomLevel = this._magnifierZoom;
|
||||
let centerX = this._magnifierCenterX;
|
||||
let centerY = this._magnifierCenterY;
|
||||
|
||||
// Apply magnification transform centered on gesture point
|
||||
ctx.translate(canvas.width / 2, canvas.height / 2);
|
||||
ctx.scale(zoomLevel, zoomLevel);
|
||||
ctx.translate(-centerX, -centerY);
|
||||
|
||||
// Try to draw the window content
|
||||
try {
|
||||
let viewer = browser.markupDocumentViewer;
|
||||
let pageZoom = viewer ? (viewer.fullZoom || 1) : 1;
|
||||
ctx.scale(pageZoom, pageZoom);
|
||||
|
||||
ctx.drawWindow(
|
||||
browser.contentWindow,
|
||||
0, 0,
|
||||
browser.contentWindow.innerWidth,
|
||||
browser.contentWindow.innerHeight,
|
||||
"rgb(0,0,0)",
|
||||
ctx.DRAWWINDOW_DO_NOT_FLUSH | ctx.DRAWWINDOW_DRAW_VIEW | ctx.DRAWWINDOW_USE_WIDGET_LAYERS
|
||||
);
|
||||
} catch (e) {
|
||||
// drawWindow may fail, just show black background
|
||||
Cu.reportError("drawWindow failed: " + e);
|
||||
}
|
||||
|
||||
ctx.restore();
|
||||
} catch (e) {
|
||||
Cu.reportError("_drawMagnifier error: " + e);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Hide and destroy magnifier overlay.
|
||||
*/
|
||||
_destroyMagnifierOverlay: function() {
|
||||
if (this._magnifierOverlay && this._magnifierOverlay.parentNode)
|
||||
this._magnifierOverlay.parentNode.removeChild(this._magnifierOverlay);
|
||||
this._magnifierOverlay = null;
|
||||
this._magnifierCanvas = null;
|
||||
this._magnifierSourceBrowser = null;
|
||||
},
|
||||
|
||||
/**
|
||||
* Determine what action to do for the gesture based on which keys are
|
||||
* pressed and which commands are set, and execute the command.
|
||||
|
|
@ -255,8 +255,8 @@
|
|||
<key id="key_delete" keycode="VK_DELETE" command="cmd_delete"/>
|
||||
<key id="key_selectAll" key="&selectAllCmd.key;" modifiers="accel"/>
|
||||
|
||||
<key id="key_handleBackspace" keycode="VK_BACK" command="cmd_handleBackspace"/>
|
||||
<key id="key_handleShiftBackspace" keycode="VK_BACK" command="cmd_handleShiftBackspace" modifiers="shift"/>
|
||||
<key keycode="VK_BACK" command="cmd_handleBackspace"/>
|
||||
<key keycode="VK_BACK" command="cmd_handleShiftBackspace" modifiers="shift"/>
|
||||
#ifndef XP_MACOSX
|
||||
<key id="goBackKb" keycode="VK_LEFT" command="Browser:Back" modifiers="alt"/>
|
||||
<key id="goForwardKb" keycode="VK_RIGHT" command="Browser:Forward" modifiers="alt"/>
|
||||