This commit was manufactured by cvs2svn to create branch
'CAMINO_1_0_BRANCH'. git-svn-id: svn://10.0.0.236/branches/CAMINO_1_0_BRANCH@188740 18797224-902f-48f8-a5cc-f745e15eee43
@@ -1,18 +0,0 @@
|
||||
FOR TRANSLATIONS OF THIS LICENSE INTO SELECTED LANGUAGES, PLEASE VISIT WWW.MOZILLA.ORG/LICENSING.
|
||||
|
||||
MOZILLA FIREFOX END-USER SOFTWARE LICENSE AGREEMENT
|
||||
Version 1.1
|
||||
|
||||
A SOURCE CODE VERSION OF CERTAIN FIREFOX BROWSER FUNCTIONALITY THAT YOU MAY USE, MODIFY AND DISTRIBUTE IS AVAILABLE TO YOU FREE-OF-CHARGE FROM WWW.MOZILLA.ORG UNDER THE MOZILLA PUBLIC LICENSE and other open source software licenses.
|
||||
The accompanying executable code version of Mozilla Firefox and related documentation (the "Product") is made available to you under the terms of this MOZILLA FIREFOX END-USER SOFTWARE LICENSE AGREEMENT (THE "AGREEMENT"). BY CLICKING THE "ACCEPT" BUTTON, OR BY INSTALLING OR USING THE MOZILLA FIREFOX BROWSER, YOU ARE CONSENTING TO BE BOUND BY THE AGREEMENT. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT, DO NOT CLICK THE "ACCEPT" BUTTON, AND DO NOT INSTALL OR USE ANY PART OF THE MOZILLA FIREFOX BROWSER.
|
||||
DURING THE MOZILLA FIREFOX INSTALLATION PROCESS, AND AT LATER TIMES, YOU MAY BE GIVEN THE OPTION OF INSTALLING ADDITIONAL COMPONENTS FROM THIRD-PARTY SOFTWARE PROVIDERS. THE INSTALLATION AND USE OF THOSE THIRD-PARTY COMPONENTS MAY BE GOVERNED BY ADDITIONAL LICENSE AGREEMENTS.
|
||||
1. LICENSE GRANT. The Mozilla Corporation grants you a non-exclusive license to use the executable code version of the Product. This Agreement will also govern any software upgrades provided by Mozilla that replace and/or supplement the original Product, unless such upgrades are accompanied by a separate license, in which case the terms of that license will govern.
|
||||
2. TERMINATION. If you breach this Agreement your right to use the Product will terminate immediately and without notice, but all provisions of this Agreement except the License Grant (Paragraph 1) will survive termination and continue in effect. Upon termination, you must destroy all copies of the Product.
|
||||
3. PROPRIETARY RIGHTS. Portions of the Product are available in source code form under the terms of the Mozilla Public License and other open source licenses (collectively, "Open Source Licenses") at http://www.mozilla.org. Nothing in this Agreement will be construed to limit any rights granted under the Open Source Licenses. Subject to the foregoing, Mozilla, for itself and on behalf of its licensors, hereby reserves all intellectual property rights in the Product, except for the rights expressly granted in this Agreement. You may not remove or alter any trademark, logo, copyright or other proprietary notice in or on the Product. This license does not grant you any right to use the trademarks, service marks or logos of Mozilla or its licensors.
|
||||
4. DISCLAIMER OF WARRANTY. THE PRODUCT IS PROVIDED "AS IS" WITH ALL FAULTS. TO THE EXTENT PERMITTED BY LAW, MOZILLA AND MOZILLA'S DISTRIBUTORS, LICENSORS HEREBY DISCLAIM ALL WARRANTIES, WHETHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES THAT THE PRODUCT IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE AND NON-INFRINGING. YOU BEAR ENTIRE RISK AS TO SELECTING THE PRODUCT FOR YOUR PURPOSES AND AS TO THE QUALITY AND PERFORMANCE OF THE PRODUCT. THIS LIMITATION WILL APPLY NOTWITHSTANDING THE FAILURE OF ESSENTIAL PURPOSE OF ANY REMEDY. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF IMPLIED WARRANTIES, SO THIS DISCLAIMER MAY NOT APPLY TO YOU.
|
||||
5. LIMITATION OF LIABILITY. EXCEPT AS REQUIRED BY LAW, MOZILLA AND ITS DISTRIBUTORS, DIRECTORS, LICENSORS, CONTRIBUTORS AND AGENTS (COLLECTIVELY, THE "MOZILLA GROUP") WILL NOT BE LIABLE FOR ANY INDIRECT, SPECIAL, INCIDENTAL, CONSEQUENTIAL OR EXEMPLARY DAMAGES ARISING OUT OF OR IN ANY WAY RELATING TO THIS AGREEMENT OR THE USE OF OR INABILITY TO USE THE PRODUCT, INCLUDING WITHOUT LIMITATION DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, LOST PROFITS, LOSS OF DATA, AND COMPUTER FAILURE OR MALFUNCTION, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES AND REGARDLESS OF THE THEORY (CONTRACT, TORT OR OTHERWISE) UPON WHICH SUCH CLAIM IS BASED. THE MOZILLA GROUP'S COLLECTIVE LIABILITY UNDER THIS AGREEMENT WILL NOT EXCEED THE GREATER OF $500 (FIVE HUNDRED DOLLARS) AND THE FEES PAID BY YOU UNDER THIS LICENSE (IF ANY). SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL, CONSEQUENTIAL OR SPECIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU.
|
||||
6. EXPORT CONTROLS. This license is subject to all applicable export restrictions. You must comply with all export and import laws and restrictions and regulations of any United States or foreign agency or authority relating to the Product and its use.
|
||||
7. U.S. GOVERNMENT END-USERS. The Product is a "commercial item," as that term is defined in 48 C.F.R. 2.101, consisting of "commercial computer software" and "commercial computer software documentation," as such terms are used in 48 C.F.R. 12.212 (Sept. 1995) and 48 C.F.R. 227.7202 (June 1995). Consistent with 48 C.F.R. 12.212, 48 C.F.R. 27.405(b)(2) (June 1998) and 48 C.F.R. 227.7202, all U.S. Government End Users acquire the Product with only those rights as set forth herein.
|
||||
8. MISCELLANEOUS. (a) This Agreement constitutes the entire agreement between Mozilla and you concerning the subject matter hereof, and it may only be modified by a written amendment signed by an authorized executive of Mozilla. (b) Except to the extent applicable law, if any, provides otherwise, this Agreement will be governed by the laws of the state of California, U.S.A., excluding its conflict of law provisions. (c) This Agreement will not be governed by the United Nations Convention on Contracts for the International Sale of Goods. (d) If any part of this Agreement is held invalid or unenforceable, that part will be construed to reflect the parties' original intent, and the remaining portions will remain in full force and effect. (e) A waiver by either party of any term or condition of this Agreement or any breach thereof, in any one instance, will not waive such term or condition or any subsequent breach thereof. (f) Except as required by law, the controlling language of this Agreement is English. (g) You may assign your rights under this Agreement to any party that consents to, and agrees to be bound by, its terms; the Mozilla Corporation may assign its rights under this Agreement without condition. (h) This Agreement will be binding upon and will inure to the benefit of the parties, their successors and permitted assigns.
|
||||
|
||||
|
||||
@@ -1,571 +0,0 @@
|
||||
You are not granted rights or licenses to the trademarks of the
|
||||
Mozilla Foundation or any party, including without limitation the
|
||||
Firefox name or logo.
|
||||
|
||||
MOZILLA PUBLIC LICENSE
|
||||
Version 1.1
|
||||
|
||||
---------------
|
||||
|
||||
1. Definitions.
|
||||
|
||||
1.0.1. "Commercial Use" means distribution or otherwise making the
|
||||
Covered Code available to a third party.
|
||||
|
||||
1.1. "Contributor" means each entity that creates or contributes to
|
||||
the creation of Modifications.
|
||||
|
||||
1.2. "Contributor Version" means the combination of the Original
|
||||
Code, prior Modifications used by a Contributor, and the Modifications
|
||||
made by that particular Contributor.
|
||||
|
||||
1.3. "Covered Code" means the Original Code or Modifications or the
|
||||
combination of the Original Code and Modifications, in each case
|
||||
including portions thereof.
|
||||
|
||||
1.4. "Electronic Distribution Mechanism" means a mechanism generally
|
||||
accepted in the software development community for the electronic
|
||||
transfer of data.
|
||||
|
||||
1.5. "Executable" means Covered Code in any form other than Source
|
||||
Code.
|
||||
|
||||
1.6. "Initial Developer" means the individual or entity identified
|
||||
as the Initial Developer in the Source Code notice required by Exhibit
|
||||
A.
|
||||
|
||||
1.7. "Larger Work" means a work which combines Covered Code or
|
||||
portions thereof with code not governed by the terms of this License.
|
||||
|
||||
1.8. "License" means this document.
|
||||
|
||||
1.8.1. "Licensable" means having the right to grant, to the maximum
|
||||
extent possible, whether at the time of the initial grant or
|
||||
subsequently acquired, any and all of the rights conveyed herein.
|
||||
|
||||
1.9. "Modifications" means any addition to or deletion from the
|
||||
substance or structure of either the Original Code or any previous
|
||||
Modifications. When Covered Code is released as a series of files, a
|
||||
Modification is:
|
||||
A. Any addition to or deletion from the contents of a file
|
||||
containing Original Code or previous Modifications.
|
||||
|
||||
B. Any new file that contains any part of the Original Code or
|
||||
previous Modifications.
|
||||
|
||||
1.10. "Original Code" means Source Code of computer software code
|
||||
which is described in the Source Code notice required by Exhibit A as
|
||||
Original Code, and which, at the time of its release under this
|
||||
License is not already Covered Code governed by this License.
|
||||
|
||||
1.10.1. "Patent Claims" means any patent claim(s), now owned or
|
||||
hereafter acquired, including without limitation, method, process,
|
||||
and apparatus claims, in any patent Licensable by grantor.
|
||||
|
||||
1.11. "Source Code" means the preferred form of the Covered Code for
|
||||
making modifications to it, including all modules it contains, plus
|
||||
any associated interface definition files, scripts used to control
|
||||
compilation and installation of an Executable, or source code
|
||||
differential comparisons against either the Original Code or another
|
||||
well known, available Covered Code of the Contributor's choice. The
|
||||
Source Code can be in a compressed or archival form, provided the
|
||||
appropriate decompression or de-archiving software is widely available
|
||||
for no charge.
|
||||
|
||||
1.12. "You" (or "Your") means an individual or a legal entity
|
||||
exercising rights under, and complying with all of the terms of, this
|
||||
License or a future version of this License issued under Section 6.1.
|
||||
For legal entities, "You" includes any entity which controls, is
|
||||
controlled by, or is under common control with You. For purposes of
|
||||
this definition, "control" means (a) the power, direct or indirect,
|
||||
to cause the direction or management of such entity, whether by
|
||||
contract or otherwise, or (b) ownership of more than fifty percent
|
||||
(50%) of the outstanding shares or beneficial ownership of such
|
||||
entity.
|
||||
|
||||
2. Source Code License.
|
||||
|
||||
2.1. The Initial Developer Grant.
|
||||
The Initial Developer hereby grants You a world-wide, royalty-free,
|
||||
non-exclusive license, subject to third party intellectual property
|
||||
claims:
|
||||
(a) under intellectual property rights (other than patent or
|
||||
trademark) Licensable by Initial Developer to use, reproduce,
|
||||
modify, display, perform, sublicense and distribute the Original
|
||||
Code (or portions thereof) with or without Modifications, and/or
|
||||
as part of a Larger Work; and
|
||||
|
||||
(b) under Patents Claims infringed by the making, using or
|
||||
selling of Original Code, to make, have made, use, practice,
|
||||
sell, and offer for sale, and/or otherwise dispose of the
|
||||
Original Code (or portions thereof).
|
||||
|
||||
(c) the licenses granted in this Section 2.1(a) and (b) are
|
||||
effective on the date Initial Developer first distributes
|
||||
Original Code under the terms of this License.
|
||||
|
||||
(d) Notwithstanding Section 2.1(b) above, no patent license is
|
||||
granted: 1) for code that You delete from the Original Code; 2)
|
||||
separate from the Original Code; or 3) for infringements caused
|
||||
by: i) the modification of the Original Code or ii) the
|
||||
combination of the Original Code with other software or devices.
|
||||
|
||||
2.2. Contributor Grant.
|
||||
Subject to third party intellectual property claims, each Contributor
|
||||
hereby grants You a world-wide, royalty-free, non-exclusive license
|
||||
|
||||
(a) under intellectual property rights (other than patent or
|
||||
trademark) Licensable by Contributor, to use, reproduce, modify,
|
||||
display, perform, sublicense and distribute the Modifications
|
||||
created by such Contributor (or portions thereof) either on an
|
||||
unmodified basis, with other Modifications, as Covered Code
|
||||
and/or as part of a Larger Work; and
|
||||
|
||||
(b) under Patent Claims infringed by the making, using, or
|
||||
selling of Modifications made by that Contributor either alone
|
||||
and/or in combination with its Contributor Version (or portions
|
||||
of such combination), to make, use, sell, offer for sale, have
|
||||
made, and/or otherwise dispose of: 1) Modifications made by that
|
||||
Contributor (or portions thereof); and 2) the combination of
|
||||
Modifications made by that Contributor with its Contributor
|
||||
Version (or portions of such combination).
|
||||
|
||||
(c) the licenses granted in Sections 2.2(a) and 2.2(b) are
|
||||
effective on the date Contributor first makes Commercial Use of
|
||||
the Covered Code.
|
||||
|
||||
(d) Notwithstanding Section 2.2(b) above, no patent license is
|
||||
granted: 1) for any code that Contributor has deleted from the
|
||||
Contributor Version; 2) separate from the Contributor Version;
|
||||
3) for infringements caused by: i) third party modifications of
|
||||
Contributor Version or ii) the combination of Modifications made
|
||||
by that Contributor with other software (except as part of the
|
||||
Contributor Version) or other devices; or 4) under Patent Claims
|
||||
infringed by Covered Code in the absence of Modifications made by
|
||||
that Contributor.
|
||||
|
||||
3. Distribution Obligations.
|
||||
|
||||
3.1. Application of License.
|
||||
The Modifications which You create or to which You contribute are
|
||||
governed by the terms of this License, including without limitation
|
||||
Section 2.2. The Source Code version of Covered Code may be
|
||||
distributed only under the terms of this License or a future version
|
||||
of this License released under Section 6.1, and You must include a
|
||||
copy of this License with every copy of the Source Code You
|
||||
distribute. You may not offer or impose any terms on any Source Code
|
||||
version that alters or restricts the applicable version of this
|
||||
License or the recipients' rights hereunder. However, You may include
|
||||
an additional document offering the additional rights described in
|
||||
Section 3.5.
|
||||
|
||||
3.2. Availability of Source Code.
|
||||
Any Modification which You create or to which You contribute must be
|
||||
made available in Source Code form under the terms of this License
|
||||
either on the same media as an Executable version or via an accepted
|
||||
Electronic Distribution Mechanism to anyone to whom you made an
|
||||
Executable version available; and if made available via Electronic
|
||||
Distribution Mechanism, must remain available for at least twelve (12)
|
||||
months after the date it initially became available, or at least six
|
||||
(6) months after a subsequent version of that particular Modification
|
||||
has been made available to such recipients. You are responsible for
|
||||
ensuring that the Source Code version remains available even if the
|
||||
Electronic Distribution Mechanism is maintained by a third party.
|
||||
|
||||
3.3. Description of Modifications.
|
||||
You must cause all Covered Code to which You contribute to contain a
|
||||
file documenting the changes You made to create that Covered Code and
|
||||
the date of any change. You must include a prominent statement that
|
||||
the Modification is derived, directly or indirectly, from Original
|
||||
Code provided by the Initial Developer and including the name of the
|
||||
Initial Developer in (a) the Source Code, and (b) in any notice in an
|
||||
Executable version or related documentation in which You describe the
|
||||
origin or ownership of the Covered Code.
|
||||
|
||||
3.4. Intellectual Property Matters
|
||||
(a) Third Party Claims.
|
||||
If Contributor has knowledge that a license under a third party's
|
||||
intellectual property rights is required to exercise the rights
|
||||
granted by such Contributor under Sections 2.1 or 2.2,
|
||||
Contributor must include a text file with the Source Code
|
||||
distribution titled "LEGAL" which describes the claim and the
|
||||
party making the claim in sufficient detail that a recipient will
|
||||
know whom to contact. If Contributor obtains such knowledge after
|
||||
the Modification is made available as described in Section 3.2,
|
||||
Contributor shall promptly modify the LEGAL file in all copies
|
||||
Contributor makes available thereafter and shall take other steps
|
||||
(such as notifying appropriate mailing lists or newsgroups)
|
||||
reasonably calculated to inform those who received the Covered
|
||||
Code that new knowledge has been obtained.
|
||||
|
||||
(b) Contributor APIs.
|
||||
If Contributor's Modifications include an application programming
|
||||
interface and Contributor has knowledge of patent licenses which
|
||||
are reasonably necessary to implement that API, Contributor must
|
||||
also include this information in the LEGAL file.
|
||||
|
||||
(c) Representations.
|
||||
Contributor represents that, except as disclosed pursuant to
|
||||
Section 3.4(a) above, Contributor believes that Contributor's
|
||||
Modifications are Contributor's original creation(s) and/or
|
||||
Contributor has sufficient rights to grant the rights conveyed by
|
||||
this License.
|
||||
|
||||
3.5. Required Notices.
|
||||
You must duplicate the notice in Exhibit A in each file of the Source
|
||||
Code. If it is not possible to put such notice in a particular Source
|
||||
Code file due to its structure, then You must include such notice in a
|
||||
location (such as a relevant directory) where a user would be likely
|
||||
to look for such a notice. If You created one or more Modification(s)
|
||||
You may add your name as a Contributor to the notice described in
|
||||
Exhibit A. You must also duplicate this License in any documentation
|
||||
for the Source Code where You describe recipients' rights or ownership
|
||||
rights relating to Covered Code. You may choose to offer, and to
|
||||
charge a fee for, warranty, support, indemnity or liability
|
||||
obligations to one or more recipients of Covered Code. However, You
|
||||
may do so only on Your own behalf, and not on behalf of the Initial
|
||||
Developer or any Contributor. You must make it absolutely clear than
|
||||
any such warranty, support, indemnity or liability obligation is
|
||||
offered by You alone, and You hereby agree to indemnify the Initial
|
||||
Developer and every Contributor for any liability incurred by the
|
||||
Initial Developer or such Contributor as a result of warranty,
|
||||
support, indemnity or liability terms You offer.
|
||||
|
||||
3.6. Distribution of Executable Versions.
|
||||
You may distribute Covered Code in Executable form only if the
|
||||
requirements of Section 3.1-3.5 have been met for that Covered Code,
|
||||
and if You include a notice stating that the Source Code version of
|
||||
the Covered Code is available under the terms of this License,
|
||||
including a description of how and where You have fulfilled the
|
||||
obligations of Section 3.2. The notice must be conspicuously included
|
||||
in any notice in an Executable version, related documentation or
|
||||
collateral in which You describe recipients' rights relating to the
|
||||
Covered Code. You may distribute the Executable version of Covered
|
||||
Code or ownership rights under a license of Your choice, which may
|
||||
contain terms different from this License, provided that You are in
|
||||
compliance with the terms of this License and that the license for the
|
||||
Executable version does not attempt to limit or alter the recipient's
|
||||
rights in the Source Code version from the rights set forth in this
|
||||
License. If You distribute the Executable version under a different
|
||||
license You must make it absolutely clear that any terms which differ
|
||||
from this License are offered by You alone, not by the Initial
|
||||
Developer or any Contributor. You hereby agree to indemnify the
|
||||
Initial Developer and every Contributor for any liability incurred by
|
||||
the Initial Developer or such Contributor as a result of any such
|
||||
terms You offer.
|
||||
|
||||
3.7. Larger Works.
|
||||
You may create a Larger Work by combining Covered Code with other code
|
||||
not governed by the terms of this License and distribute the Larger
|
||||
Work as a single product. In such a case, You must make sure the
|
||||
requirements of this License are fulfilled for the Covered Code.
|
||||
|
||||
4. Inability to Comply Due to Statute or Regulation.
|
||||
|
||||
If it is impossible for You to comply with any of the terms of this
|
||||
License with respect to some or all of the Covered Code due to
|
||||
statute, judicial order, or regulation then You must: (a) comply with
|
||||
the terms of this License to the maximum extent possible; and (b)
|
||||
describe the limitations and the code they affect. Such description
|
||||
must be included in the LEGAL file described in Section 3.4 and must
|
||||
be included with all distributions of the Source Code. Except to the
|
||||
extent prohibited by statute or regulation, such description must be
|
||||
sufficiently detailed for a recipient of ordinary skill to be able to
|
||||
understand it.
|
||||
|
||||
5. Application of this License.
|
||||
|
||||
This License applies to code to which the Initial Developer has
|
||||
attached the notice in Exhibit A and to related Covered Code.
|
||||
|
||||
6. Versions of the License.
|
||||
|
||||
6.1. New Versions.
|
||||
Netscape Communications Corporation ("Netscape") may publish revised
|
||||
and/or new versions of the License from time to time. Each version
|
||||
will be given a distinguishing version number.
|
||||
|
||||
6.2. Effect of New Versions.
|
||||
Once Covered Code has been published under a particular version of the
|
||||
License, You may always continue to use it under the terms of that
|
||||
version. You may also choose to use such Covered Code under the terms
|
||||
of any subsequent version of the License published by Netscape. No one
|
||||
other than Netscape has the right to modify the terms applicable to
|
||||
Covered Code created under this License.
|
||||
|
||||
6.3. Derivative Works.
|
||||
If You create or use a modified version of this License (which you may
|
||||
only do in order to apply it to code which is not already Covered Code
|
||||
governed by this License), You must (a) rename Your license so that
|
||||
the phrases "Mozilla", "MOZILLAPL", "MOZPL", "Netscape",
|
||||
"MPL", "NPL" or any confusingly similar phrase do not appear in your
|
||||
license (except to note that your license differs from this License)
|
||||
and (b) otherwise make it clear that Your version of the license
|
||||
contains terms which differ from the Mozilla Public License and
|
||||
Netscape Public License. (Filling in the name of the Initial
|
||||
Developer, Original Code or Contributor in the notice described in
|
||||
Exhibit A shall not of themselves be deemed to be modifications of
|
||||
this License.)
|
||||
|
||||
7. DISCLAIMER OF WARRANTY.
|
||||
|
||||
COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
|
||||
WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF
|
||||
DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING.
|
||||
THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED CODE
|
||||
IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN ANY RESPECT,
|
||||
YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE
|
||||
COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER
|
||||
OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF
|
||||
ANY COVERED CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER.
|
||||
|
||||
8. TERMINATION.
|
||||
|
||||
8.1. This License and the rights granted hereunder will terminate
|
||||
automatically if You fail to comply with terms herein and fail to cure
|
||||
such breach within 30 days of becoming aware of the breach. All
|
||||
sublicenses to the Covered Code which are properly granted shall
|
||||
survive any termination of this License. Provisions which, by their
|
||||
nature, must remain in effect beyond the termination of this License
|
||||
shall survive.
|
||||
|
||||
8.2. If You initiate litigation by asserting a patent infringement
|
||||
claim (excluding declatory judgment actions) against Initial Developer
|
||||
or a Contributor (the Initial Developer or Contributor against whom
|
||||
You file such action is referred to as "Participant") alleging that:
|
||||
|
||||
(a) such Participant's Contributor Version directly or indirectly
|
||||
infringes any patent, then any and all rights granted by such
|
||||
Participant to You under Sections 2.1 and/or 2.2 of this License
|
||||
shall, upon 60 days notice from Participant terminate prospectively,
|
||||
unless if within 60 days after receipt of notice You either: (i)
|
||||
agree in writing to pay Participant a mutually agreeable reasonable
|
||||
royalty for Your past and future use of Modifications made by such
|
||||
Participant, or (ii) withdraw Your litigation claim with respect to
|
||||
the Contributor Version against such Participant. If within 60 days
|
||||
of notice, a reasonable royalty and payment arrangement are not
|
||||
mutually agreed upon in writing by the parties or the litigation claim
|
||||
is not withdrawn, the rights granted by Participant to You under
|
||||
Sections 2.1 and/or 2.2 automatically terminate at the expiration of
|
||||
the 60 day notice period specified above.
|
||||
|
||||
(b) any software, hardware, or device, other than such Participant's
|
||||
Contributor Version, directly or indirectly infringes any patent, then
|
||||
any rights granted to You by such Participant under Sections 2.1(b)
|
||||
and 2.2(b) are revoked effective as of the date You first made, used,
|
||||
sold, distributed, or had made, Modifications made by that
|
||||
Participant.
|
||||
|
||||
8.3. If You assert a patent infringement claim against Participant
|
||||
alleging that such Participant's Contributor Version directly or
|
||||
indirectly infringes any patent where such claim is resolved (such as
|
||||
by license or settlement) prior to the initiation of patent
|
||||
infringement litigation, then the reasonable value of the licenses
|
||||
granted by such Participant under Sections 2.1 or 2.2 shall be taken
|
||||
into account in determining the amount or value of any payment or
|
||||
license.
|
||||
|
||||
8.4. In the event of termination under Sections 8.1 or 8.2 above,
|
||||
all end user license agreements (excluding distributors and resellers)
|
||||
which have been validly granted by You or any distributor hereunder
|
||||
prior to termination shall survive termination.
|
||||
|
||||
9. LIMITATION OF LIABILITY.
|
||||
|
||||
UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT
|
||||
(INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL
|
||||
DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED CODE,
|
||||
OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR
|
||||
ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY
|
||||
CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF GOODWILL,
|
||||
WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER
|
||||
COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN
|
||||
INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF
|
||||
LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY
|
||||
RESULTING FROM SUCH PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW
|
||||
PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE
|
||||
EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO
|
||||
THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU.
|
||||
|
||||
10. U.S. GOVERNMENT END USERS.
|
||||
|
||||
The Covered Code is a "commercial item," as that term is defined in
|
||||
48 C.F.R. 2.101 (Oct. 1995), consisting of "commercial computer
|
||||
software" and "commercial computer software documentation," as such
|
||||
terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48
|
||||
C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995),
|
||||
all U.S. Government End Users acquire Covered Code with only those
|
||||
rights set forth herein.
|
||||
|
||||
11. MISCELLANEOUS.
|
||||
|
||||
This License represents the complete agreement concerning subject
|
||||
matter hereof. If any provision of this License is held to be
|
||||
unenforceable, such provision shall be reformed only to the extent
|
||||
necessary to make it enforceable. This License shall be governed by
|
||||
California law provisions (except to the extent applicable law, if
|
||||
any, provides otherwise), excluding its conflict-of-law provisions.
|
||||
With respect to disputes in which at least one party is a citizen of,
|
||||
or an entity chartered or registered to do business in the United
|
||||
States of America, any litigation relating to this License shall be
|
||||
subject to the jurisdiction of the Federal Courts of the Northern
|
||||
District of California, with venue lying in Santa Clara County,
|
||||
California, with the losing party responsible for costs, including
|
||||
without limitation, court costs and reasonable attorneys' fees and
|
||||
expenses. The application of the United Nations Convention on
|
||||
Contracts for the International Sale of Goods is expressly excluded.
|
||||
Any law or regulation which provides that the language of a contract
|
||||
shall be construed against the drafter shall not apply to this
|
||||
License.
|
||||
|
||||
12. RESPONSIBILITY FOR CLAIMS.
|
||||
|
||||
As between Initial Developer and the Contributors, each party is
|
||||
responsible for claims and damages arising, directly or indirectly,
|
||||
out of its utilization of rights under this License and You agree to
|
||||
work with Initial Developer and Contributors to distribute such
|
||||
responsibility on an equitable basis. Nothing herein is intended or
|
||||
shall be deemed to constitute any admission of liability.
|
||||
|
||||
13. MULTIPLE-LICENSED CODE.
|
||||
|
||||
Initial Developer may designate portions of the Covered Code as
|
||||
"Multiple-Licensed". "Multiple-Licensed" means that the Initial
|
||||
Developer permits you to utilize portions of the Covered Code under
|
||||
Your choice of the NPL or the alternative licenses, if any, specified
|
||||
by the Initial Developer in the file described in Exhibit A.
|
||||
|
||||
EXHIBIT A -Mozilla Public License.
|
||||
|
||||
``The contents of this file are subject to the Mozilla Public License
|
||||
Version 1.1 (the "License"); you may not use this file except in
|
||||
compliance with the License. You may obtain a copy of the License at
|
||||
http://www.mozilla.org/MPL/
|
||||
|
||||
Software distributed under the License is distributed on an "AS IS"
|
||||
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
|
||||
License for the specific language governing rights and limitations
|
||||
under the License.
|
||||
|
||||
The Original Code is ______________________________________.
|
||||
|
||||
The Initial Developer of the Original Code is ________________________.
|
||||
Portions created by ______________________ are Copyright (C) ______
|
||||
_______________________. All Rights Reserved.
|
||||
|
||||
Contributor(s): ______________________________________.
|
||||
|
||||
Alternatively, the contents of this file may be used under the terms
|
||||
of the _____ license (the "[___] License"), in which case the
|
||||
provisions of [______] License are applicable instead of those
|
||||
above. If you wish to allow use of your version of this file only
|
||||
under the terms of the [____] License and not to allow others to use
|
||||
your version of this file under the MPL, indicate your decision by
|
||||
deleting the provisions above and replace them with the notice and
|
||||
other provisions required by the [___] License. If you do not delete
|
||||
the provisions above, a recipient may use your version of this file
|
||||
under either the MPL or the [___] License."
|
||||
|
||||
[NOTE: The text of this Exhibit A may differ slightly from the text of
|
||||
the notices in the Source Code files of the Original Code. You should
|
||||
use the text of this Exhibit A rather than the text found in the
|
||||
Original Code Source Code for Your Modifications.]
|
||||
|
||||
----------------------------------------------------------------------
|
||||
|
||||
AMENDMENTS
|
||||
|
||||
The Netscape Public License Version 1.1 ("NPL") consists of the
|
||||
Mozilla Public License Version 1.1 with the following Amendments,
|
||||
including Exhibit A-Netscape Public License. Files identified with
|
||||
"Exhibit A-Netscape Public License" are governed by the Netscape
|
||||
Public License Version 1.1.
|
||||
|
||||
Additional Terms applicable to the Netscape Public License.
|
||||
I. Effect.
|
||||
These additional terms described in this Netscape Public
|
||||
License -- Amendments shall apply to the Mozilla Communicator
|
||||
client code and to all Covered Code under this License.
|
||||
|
||||
II. "Netscape's Branded Code" means Covered Code that Netscape
|
||||
distributes and/or permits others to distribute under one or more
|
||||
trademark(s) which are controlled by Netscape but which are not
|
||||
licensed for use under this License.
|
||||
|
||||
III. Netscape and logo.
|
||||
This License does not grant any rights to use the trademarks
|
||||
"Netscape", the "Netscape N and horizon" logo or the "Netscape
|
||||
lighthouse" logo, "Netcenter", "Gecko", "Java" or "JavaScript",
|
||||
"Smart Browsing" even if such marks are included in the Original
|
||||
Code or Modifications.
|
||||
|
||||
IV. Inability to Comply Due to Contractual Obligation.
|
||||
Prior to licensing the Original Code under this License, Netscape
|
||||
has licensed third party code for use in Netscape's Branded Code.
|
||||
To the extent that Netscape is limited contractually from making
|
||||
such third party code available under this License, Netscape may
|
||||
choose to reintegrate such code into Covered Code without being
|
||||
required to distribute such code in Source Code form, even if
|
||||
such code would otherwise be considered "Modifications" under
|
||||
this License.
|
||||
|
||||
V. Use of Modifications and Covered Code by Initial Developer.
|
||||
V.1. In General.
|
||||
The obligations of Section 3 apply to Netscape, except to
|
||||
the extent specified in this Amendment, Section V.2 and V.3.
|
||||
|
||||
V.2. Other Products.
|
||||
Netscape may include Covered Code in products other than the
|
||||
Netscape's Branded Code which are released by Netscape
|
||||
during the two (2) years following the release date of the
|
||||
Original Code, without such additional products becoming
|
||||
subject to the terms of this License, and may license such
|
||||
additional products on different terms from those contained
|
||||
in this License.
|
||||
|
||||
V.3. Alternative Licensing.
|
||||
Netscape may license the Source Code of Netscape's Branded
|
||||
Code, including Modifications incorporated therein, without
|
||||
such Netscape Branded Code becoming subject to the terms of
|
||||
this License, and may license such Netscape Branded Code on
|
||||
different terms from those contained in this License.
|
||||
|
||||
VI. Litigation.
|
||||
Notwithstanding the limitations of Section 11 above, the
|
||||
provisions regarding litigation in Section 11(a), (b) and (c) of
|
||||
the License shall apply to all disputes relating to this License.
|
||||
|
||||
EXHIBIT A-Netscape Public License.
|
||||
|
||||
"The contents of this file are subject to the Netscape Public
|
||||
License Version 1.1 (the "License"); you may not use this file
|
||||
except in compliance with the License. You may obtain a copy of
|
||||
the License at http://www.mozilla.org/NPL/
|
||||
|
||||
Software distributed under the License is distributed on an "AS
|
||||
IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
||||
implied. See the License for the specific language governing
|
||||
rights and limitations under the License.
|
||||
|
||||
The Original Code is Mozilla Communicator client code, released
|
||||
March 31, 1998.
|
||||
|
||||
The Initial Developer of the Original Code is Netscape
|
||||
Communications Corporation. Portions created by Netscape are
|
||||
Copyright (C) 1998-1999 Netscape Communications Corporation. All
|
||||
Rights Reserved.
|
||||
|
||||
Contributor(s): ______________________________________.
|
||||
|
||||
Alternatively, the contents of this file may be used under the
|
||||
terms of the _____ license (the "[___] License"), in which case
|
||||
the provisions of [______] License are applicable instead of
|
||||
those above. If you wish to allow use of your version of this
|
||||
file only under the terms of the [____] License and not to allow
|
||||
others to use your version of this file under the NPL, indicate
|
||||
your decision by deleting the provisions above and replace them
|
||||
with the notice and other provisions required by the [___]
|
||||
License. If you do not delete the provisions above, a recipient
|
||||
may use your version of this file under either the NPL or the
|
||||
[___] License."
|
||||
@@ -1,53 +0,0 @@
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is the Mozilla Browser code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2002
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Brian Ryner <bryner@brianryner.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
DIRS = base components locales extensions themes app
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
ifdef MOZ_INSTALLER
|
||||
DIRS += installer/windows
|
||||
endif
|
||||
endif
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
@@ -1,344 +0,0 @@
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Brian Ryner <bryner@brianryner.com>
|
||||
# Jonathan Wilson <jonwil@tpgi.com.au>
|
||||
# Dan Mosedale <dmose@mozilla.org>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MOZILLA_INTERNAL_API = 1
|
||||
|
||||
DIRS = profile/extensions
|
||||
|
||||
PREF_JS_EXPORTS = $(srcdir)/profile/firefox.js \
|
||||
$(srcdir)/profile/channel-prefs.js \
|
||||
$(NULL)
|
||||
|
||||
# hardcode en-US for the moment
|
||||
AB_CD = en-US
|
||||
|
||||
DEFINES += -DAB_CD=$(AB_CD)
|
||||
|
||||
ifeq ($(USE_SHORT_LIBNAME), 1)
|
||||
PROGRAM = firefox$(BIN_SUFFIX)
|
||||
else
|
||||
PROGRAM = firefox-bin$(BIN_SUFFIX)
|
||||
endif
|
||||
|
||||
REQUIRES = \
|
||||
xpcom \
|
||||
$(NULL)
|
||||
|
||||
CPPSRCS = nsBrowserApp.cpp
|
||||
|
||||
LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre
|
||||
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
STATIC_COMPONENTS_LINKER_PATH = -L$(DIST)/lib/components
|
||||
endif
|
||||
|
||||
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
||||
TK_LIBS := -framework Cocoa $(TK_LIBS)
|
||||
endif
|
||||
|
||||
LIBS = \
|
||||
$(STATIC_COMPONENTS_LINKER_PATH) \
|
||||
$(EXTRA_DSO_LIBS) \
|
||||
$(DIST)/lib/$(LIB_PREFIX)xulapp_s.$(LIB_SUFFIX) \
|
||||
$(MOZ_JS_LIBS) \
|
||||
$(XPCOM_LIBS) \
|
||||
$(NSPR_LIBS) \
|
||||
$(TK_LIBS) \
|
||||
$(NULL)
|
||||
|
||||
# Add explicit X11 dependency when building against X11 toolkits
|
||||
ifneq (,$(filter gtk gtk2 xlib,$(MOZ_WIDGET_TOOLKIT)))
|
||||
LIBS += $(XLDFLAGS) $(XLIBS)
|
||||
endif
|
||||
|
||||
ifdef MOZ_JPROF
|
||||
LIBS += -ljprof
|
||||
endif
|
||||
|
||||
ifndef MOZ_WINCONSOLE
|
||||
ifdef MOZ_DEBUG
|
||||
MOZ_WINCONSOLE = 1
|
||||
else
|
||||
MOZ_WINCONSOLE = 0
|
||||
endif
|
||||
endif
|
||||
|
||||
NSDISTMODE = copy
|
||||
|
||||
include $(topsrcdir)/config/config.mk
|
||||
ifndef BUILD_STATIC_LIBS
|
||||
|
||||
ifdef NS_TRACE_MALLOC
|
||||
EXTRA_DSO_LIBS += tracemalloc
|
||||
endif
|
||||
|
||||
else
|
||||
include $(topsrcdir)/config/static-config.mk
|
||||
|
||||
EXTRA_DEPS += \
|
||||
$(STATIC_EXTRA_DEPS) \
|
||||
$(NULL)
|
||||
DEFINES += $(STATIC_DEFINES)
|
||||
CPPSRCS += $(STATIC_CPPSRCS)
|
||||
EXTRA_DSO_LIBS += $(STATIC_EXTRA_DSO_LIBS)
|
||||
REQUIRES += $(STATIC_REQUIRES)
|
||||
EXTRA_LIBS += $(STATIC_EXTRA_LIBS)
|
||||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
OS_LIBS += $(call EXPAND_LIBNAME,comctl32 comdlg32 uuid shell32 ole32 oleaut32 version winspool gdi32)
|
||||
RCINCLUDE = splash.rc
|
||||
ifndef GNU_CC
|
||||
RCFLAGS += -DMOZ_PHOENIX -I$(srcdir)
|
||||
else
|
||||
RCFLAGS += -DMOZ_PHOENIX --include-dir $(srcdir)
|
||||
endif
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
RCFLAGS += -DMOZ_STATIC_BUILD
|
||||
endif
|
||||
ifdef DEBUG
|
||||
RCFLAGS += -DDEBUG
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),BeOS)
|
||||
OS_LIBS += -ltracker
|
||||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),OS2)
|
||||
RESFILE=splashos2.res
|
||||
RCFLAGS += -DMOZ_PHOENIX
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
EXE_DEF_FILE = browser.def
|
||||
RCFLAGS += -DMOZ_STATIC_BUILD -i $(DIST)/include/widget
|
||||
endif
|
||||
ifdef DEBUG
|
||||
RCFLAGS += -DDEBUG
|
||||
endif
|
||||
RCFLAGS += -DFIREFOX_ICO=\"$(DIST)/branding/firefox.ico\" -DDOCUMENT_ICO=\"$(DIST)/branding/document.ico\"
|
||||
endif
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
DEFINES += -DFIREFOX_ICO=\"$(DIST)/branding/firefox.ico\" -DDOCUMENT_ICO=\"$(DIST)/branding/document.ico\"
|
||||
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
include $(topsrcdir)/config/static-rules.mk
|
||||
endif
|
||||
|
||||
APP_VERSION = $(shell cat $(srcdir)/../config/version.txt)
|
||||
DEFINES += -DAPP_VERSION="$(APP_VERSION)"
|
||||
|
||||
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
LIBS += -framework QuickTime -framework IOKit
|
||||
ifdef USE_PREBINDING
|
||||
BIN_FLAGS += -Wl,-headerpad -Wl,5a0c
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(MOZ_WIDGET_TOOLKIT),photon)
|
||||
LIBS += -lphexlib
|
||||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
#
|
||||
# Control the default heap size.
|
||||
# This is the heap returned by GetProcessHeap().
|
||||
# As we use the CRT heap, the default size is too large and wastes VM.
|
||||
#
|
||||
# The default heap size is 1MB on Win32.
|
||||
# The heap will grow if need be.
|
||||
#
|
||||
# Set it to 256k. See bug 127069.
|
||||
#
|
||||
ifndef GNU_CC
|
||||
LDFLAGS += /HEAP:0x40000
|
||||
endif
|
||||
endif
|
||||
|
||||
$(PROGRAM): $(DIST)/lib/$(LIB_PREFIX)xulapp_s.$(LIB_SUFFIX)
|
||||
|
||||
ifeq ($(OS_ARCH),OS2)
|
||||
ifdef BUILD_STATIC_LIBS
|
||||
$(EXE_DEF_FILE):
|
||||
rm -f $@
|
||||
@echo NAME mozilla >$(EXE_DEF_FILE)
|
||||
@echo IMPORTS >>$(EXE_DEF_FILE)
|
||||
@echo WinQueryProperty = PMMERGE.5450 >>$(EXE_DEF_FILE)
|
||||
@echo WinRemoveProperty = PMMERGE.5451 >>$(EXE_DEF_FILE)
|
||||
@echo WinSetProperty = PMMERGE.5452 >>$(EXE_DEF_FILE)
|
||||
|
||||
LDFLAGS += -Zlinker /NOE
|
||||
endif
|
||||
endif
|
||||
|
||||
ifneq (,$(filter-out OS2 WINNT,$(OS_ARCH)))
|
||||
|
||||
firefox:: mozilla.in Makefile.in Makefile $(DEPTH)/config/autoconf.mk
|
||||
cat $< | sed -e "s|%MOZAPPDIR%|$(mozappdir)|" \
|
||||
-e "s|%MOZ_USER_DIR%|.mozilla/firefox|" \
|
||||
-e "s|%MREDIR%|$(mredir)|" > $@
|
||||
chmod +x $@
|
||||
|
||||
libs:: firefox
|
||||
$(INSTALL) $< $(DIST)/bin
|
||||
|
||||
install:: firefox
|
||||
$(SYSINSTALL) $< $(DESTDIR)$(bindir)
|
||||
|
||||
GARBAGE += firefox
|
||||
GARBAGE += $(addprefix $(DIST)/bin/defaults/pref/, firefox.js)
|
||||
|
||||
endif
|
||||
|
||||
ifneq (,$(filter gtk gtk2,$(MOZ_WIDGET_TOOLKIT)))
|
||||
|
||||
ICON_FILES = \
|
||||
$(DIST)/branding/mozicon128.png \
|
||||
$(DIST)/branding/mozicon50.xpm \
|
||||
$(DIST)/branding/mozicon16.xpm \
|
||||
$(DIST)/branding/document.png \
|
||||
$(NULL)
|
||||
|
||||
libs:: $(ICON_FILES)
|
||||
$(INSTALL) $^ $(DIST)/bin/icons
|
||||
|
||||
install::
|
||||
$(SYSINSTALL) $(IFLAGS1) $(ICON_FILES) $(DESTDIR)$(mozappdir)/icons
|
||||
endif
|
||||
|
||||
ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2)
|
||||
libs::
|
||||
$(INSTALL) $(DIST)/branding/default.xpm $(DIST)/bin/chrome/icons/default
|
||||
|
||||
install::
|
||||
$(SYSINSTALL) $(IFLAGS1) $(DIST)/branding/default.xpm $(DESTDIR)$(mozappdir)/icons
|
||||
endif
|
||||
|
||||
export::
|
||||
ifndef MOZ_BRANDING_DIRECTORY
|
||||
$(NSINSTALL) -D $(DIST)/branding
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
cp $(srcdir)/firefox.ico $(DIST)/branding/firefox.ico
|
||||
cp $(srcdir)/firefox.ico $(DIST)/branding/app.ico
|
||||
cp $(srcdir)/document.ico $(DIST)/branding/document.ico
|
||||
endif
|
||||
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
||||
cp $(srcdir)/macbuild/firefox.icns $(DIST)/branding/firefox.icns
|
||||
cp $(srcdir)/macbuild/document.icns $(DIST)/branding/document.icns
|
||||
cp $(srcdir)/macbuild/dsstore $(DIST)/branding/dsstore
|
||||
cp $(srcdir)/macbuild/background.png $(DIST)/branding/background.png
|
||||
cp $(srcdir)/macbuild/disk.icns $(DIST)/branding/disk.icns
|
||||
cp $(srcdir)/macbuild/license.r $(DIST)/branding/license.r
|
||||
endif
|
||||
ifneq (,$(filter gtk gtk2,$(MOZ_WIDGET_TOOLKIT)))
|
||||
cp $(srcdir)/mozicon128.png $(DIST)/branding/mozicon128.png
|
||||
cp $(srcdir)/mozicon16.xpm $(DIST)/branding/mozicon16.xpm
|
||||
cp $(srcdir)/mozicon50.xpm $(DIST)/branding/mozicon50.xpm
|
||||
cp $(srcdir)/document.png $(DIST)/branding/document.png
|
||||
endif
|
||||
ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2)
|
||||
cp $(srcdir)/default.xpm $(DIST)/branding/default.xpm
|
||||
endif
|
||||
ifeq ($(OS_ARCH),OS2)
|
||||
cp $(srcdir)/firefox-os2.ico $(DIST)/branding/firefox.ico
|
||||
cp $(srcdir)/firefox-os2.ico $(DIST)/branding/app.ico
|
||||
cp $(srcdir)/document-os2.ico $(DIST)/branding/document.ico
|
||||
endif
|
||||
endif
|
||||
|
||||
libs::
|
||||
touch $(DIST)/bin/.autoreg
|
||||
|
||||
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
||||
|
||||
APP_NAME = $(MOZ_APP_DISPLAYNAME)
|
||||
|
||||
ifdef MOZ_DEBUG
|
||||
APP_NAME := $(APP_NAME)Debug
|
||||
endif
|
||||
|
||||
AB_CD = $(MOZ_UI_LOCALE)
|
||||
|
||||
AB := $(firstword $(subst -, ,$(AB_CD)))
|
||||
|
||||
clean clobber repackage::
|
||||
rm -rf $(DIST)/$(APP_NAME).app
|
||||
|
||||
libs repackage:: $(PROGRAM)
|
||||
mkdir -p $(DIST)/$(APP_NAME).app/Contents/MacOS
|
||||
rsync -a --exclude CVS --exclude "*.in" $(srcdir)/macbuild/Contents $(DIST)/$(APP_NAME).app --exclude English.lproj
|
||||
mkdir -p $(DIST)/$(APP_NAME).app/Contents/Resources/$(AB).lproj
|
||||
rsync -a --exclude CVS $(srcdir)/macbuild/Contents/Resources/English.lproj/ $(DIST)/$(APP_NAME).app/Contents/Resources/$(AB).lproj
|
||||
sed -e "s/APP_VERSION/$(APP_VERSION)/" -e "s/APP_NAME/$(APP_NAME)/" $(srcdir)/macbuild/Contents/Info.plist.in > $(DIST)/$(APP_NAME).app/Contents/Info.plist
|
||||
rsync -a $(DIST)/bin/ $(DIST)/$(APP_NAME).app/Contents/MacOS
|
||||
rm -f $(DIST)/$(APP_NAME).app/Contents/MacOS/$(PROGRAM) $(DIST)/$(APP_NAME).app/Contents/MacOS/mangle $(DIST)/$(APP_NAME).app/Contents/MacOS/shlibsign
|
||||
rsync -aL $(PROGRAM) $(DIST)/$(APP_NAME).app/Contents/MacOS
|
||||
mkdir -p $(DIST)/$(APP_NAME).app/Contents/Plug-Ins
|
||||
# Bug 297227: the next line only exists to repair broken depend builds, it can
|
||||
# go away once that bug has been closed for a while.
|
||||
rm -rf $(DIST)/$(APP_NAME).app/Contents/Plug-Ins/PrintPDE.plugin
|
||||
rsync -a --copy-unsafe-links $(DIST)/package/PrintPDE.plugin $(DIST)/$(APP_NAME).app/Contents/Plug-Ins
|
||||
-cp -L $(DIST)/bin/mangle $(DIST)/bin/shlibsign $(DIST)/$(APP_NAME).app/Contents/MacOS
|
||||
cp -RL $(DIST)/branding/firefox.icns $(DIST)/$(APP_NAME).app/Contents/Resources/firefox.icns
|
||||
cp -RL $(DIST)/branding/document.icns $(DIST)/$(APP_NAME).app/Contents/Resources/document.icns
|
||||
cp -RL $(DIST)/package/mozillaSuite.rsrc $(DIST)/$(APP_NAME).app/Contents/Resources/$(PROGRAM).rsrc
|
||||
echo -n APPLMOZB > $(DIST)/$(APP_NAME).app/Contents/PkgInfo
|
||||
# remove CVS dirs from packaged app
|
||||
find $(DIST)/$(APP_NAME).app -type d -name "CVS" -prune -exec rm -rf {} \;
|
||||
|
||||
endif
|
||||
|
||||
libs::
|
||||
$(INSTALL) $(topsrcdir)/LICENSE $(DIST)/bin
|
||||
|
||||
libs:: $(srcdir)/profile/prefs.js
|
||||
$(INSTALL) $^ $(DIST)/bin/defaults/profile
|
||||
|
||||
install:: $(srcdir)/profile/prefs.js
|
||||
$(SYSINSTALL) $(IFLAGS1) $^ $(DESTDIR)$(mozappdir)/defaults/profile
|
||||
@@ -1,4 +0,0 @@
|
||||
For information about installing, running and configuring Firefox
|
||||
including a list of known issues and troubleshooting information,
|
||||
refer to: http://getfirefox.com/releases/
|
||||
|
||||
|
Before Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 3.1 KiB |
@@ -1,22 +0,0 @@
|
||||
<?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="X86"
|
||||
name="Firefox"
|
||||
type="win32"
|
||||
/>
|
||||
<description>Firefox</description>
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Microsoft.Windows.Common-Controls"
|
||||
version="6.0.0.0"
|
||||
processorArchitecture="X86"
|
||||
publicKeyToken="6595b64144ccf1df"
|
||||
language="*"
|
||||
/>
|
||||
</dependentAssembly>
|
||||
</dependency>
|
||||
</assembly>
|
||||
|
Before Width: | Height: | Size: 22 KiB |
@@ -1,144 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>html</string>
|
||||
<string>htm</string>
|
||||
<string>shtml</string>
|
||||
<string>xht</string>
|
||||
<string>xhtml</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>document.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>HTML Document</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>HTML</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>text</string>
|
||||
<string>txt</string>
|
||||
<string>js</string>
|
||||
<string>log</string>
|
||||
<string>css</string>
|
||||
<string>xul</string>
|
||||
<string>rdf</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>document.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>Text Document</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>TEXT</string>
|
||||
<string>utxt</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>jpeg</string>
|
||||
<string>jpg</string>
|
||||
<string>png</string>
|
||||
<string>gif</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>fileBookmark.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>document.icns</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>GIFf</string>
|
||||
<string>JPEG</string>
|
||||
<string>PNGf</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>firefox-bin</string>
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>Firefox APP_VERSION, © 1998-2006 Contributors</string>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>firefox</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>org.mozilla.firefox</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>APP_NAME</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>APP_VERSION</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>MOZB</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleURLIconFile</key>
|
||||
<string>document.icns</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>http URL</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>http</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleURLIconFile</key>
|
||||
<string>document.icns</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>https URL</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>https</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>ftp URL</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>ftp</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>gopher URL</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>gopher</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>file URL</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>file</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>APP_VERSION</string>
|
||||
<key>NSAppleScriptEnabled</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
||||
|
Before Width: | Height: | Size: 1.1 KiB |
@@ -1,133 +0,0 @@
|
||||
// See /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Script.h for language IDs.
|
||||
data 'LPic' (5000) {
|
||||
// Default language ID, 0 = English
|
||||
$"0000"
|
||||
// Number of entries in list
|
||||
$"0001"
|
||||
|
||||
// Entry 1
|
||||
// Language ID, 0 = English
|
||||
$"0000"
|
||||
// Resource ID, 0 = STR#/TEXT/styl 5000
|
||||
$"0000"
|
||||
// Multibyte language, 0 = no
|
||||
$"0000"
|
||||
};
|
||||
|
||||
resource 'STR#' (5000, "English") {
|
||||
{
|
||||
// Language (unused?) = English
|
||||
"English",
|
||||
// Agree
|
||||
"Agree",
|
||||
// Disagree
|
||||
"Disagree",
|
||||
// Print, ellipsis is 0xC9
|
||||
"PrintÉ",
|
||||
// Save As, ellipsis is 0xC9
|
||||
"Save AsÉ",
|
||||
// Descriptive text, curly quotes are 0xD2 and 0xD3
|
||||
"You are about to install Deer Park.\n"
|
||||
"\n"
|
||||
"Please read the license agreement. If you agree to its terms and accept, click ÒAgreeÓ to access the software. Otherwise, click ÒDisagreeÓ to cancel."
|
||||
};
|
||||
};
|
||||
|
||||
// Beware of 1024(?) byte (character?) line length limitation. Split up long
|
||||
// lines.
|
||||
// If straight quotes are used ("), remember to escape them (\").
|
||||
// Newline is \n, to leave a blank line, use two of them.
|
||||
// 0xD2 and 0xD3 are curly double-quotes ("), 0xD4 and 0xD5 are curly
|
||||
// single quotes ('), 0xD5 is also the apostrophe.
|
||||
data 'TEXT' (5000, "English") {
|
||||
"FOR TRANSLATIONS OF THIS LICENSE INTO SELECTED LANGUAGES, PLEASE VISIT WWW.MOZILLA.ORG/LICENSING.\n"
|
||||
"\n"
|
||||
"MOZILLA FOUNDATION\n"
|
||||
"DEER PARK END-USER SOFTWARE LICENSE AGREEMENT\n"
|
||||
"\n"
|
||||
"A SOURCE CODE VERSION OF CERTAIN DEER PARK BROWSER FUNCTIONALITY THAT YOU MAY USE, MODIFY AND DISTRIBUTE IS AVAILABLE TO YOU FREE-OF-CHARGE FROM WWW.MOZILLA.ORG UNDER THE MOZILLA PUBLIC LICENSE and other open source software licenses.\n"
|
||||
"\n"
|
||||
"The accompanying executable code version of Deer Park and related documentation (the ÒProductÓ) is made available to you under the terms of this DEER PARK END-USER SOFTWARE LICENSE AGREEMENT (THE ÒAGREEMENTÓ). BY CLICKING THE ÒACCEPTÓ BUTTON, OR BY INSTALLING OR USING THE DEER PARK BROWSER, YOU ARE CONSENTING TO BE BOUND BY THE AGREEMENT. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT, DO NOT CLICK THE ÒACCEPTÓ BUTTON, AND DO NOT INSTALL OR USE ANY PART OF THE DEER PARK BROWSER.\n"
|
||||
"\n"
|
||||
"DURING THE DEER PARK INSTALLATION PROCESS, AND AT LATER TIMES, YOU MAY BE GIVEN THE OPTION OF INSTALLING ADDITIONAL COMPONENTS FROM THIRD-PARTY SOFTWARE PROVIDERS. THE INSTALLATION AND USE OF THOSE THIRD-PARTY COMPONENTS MAY BE GOVERNED BY ADDITIONAL LICENSE AGREEMENTS.\n"
|
||||
"\n"
|
||||
"1. LICENSE GRANT. The Mozilla Foundation grants you a non-exclusive license to use the executable code version of the Product. This Agreement will also govern any software upgrades provided by Mozilla that replace and/or supplement the original Product, unless such upgrades are accompanied by a separate license, in which case the terms of that license will govern.\n"
|
||||
"\n"
|
||||
"2. TERMINATION. If you breach this Agreement your right to use the Product will terminate immediately and without notice, but all provisions of this Agreement except the License Grant (Paragraph 1) will survive termination and continue in effect. Upon termination, you must destroy all copies of the Product.\n"
|
||||
"\n"
|
||||
"3. PROPRIETARY RIGHTS. Portions of the Product are available in source code form under the terms of the Mozilla Public License and other open source licenses (collectively, ÒOpen Source LicensesÓ) at http://www.mozilla.org. Nothing in this Agreement will be construed to limit any rights granted under the Open Source Licenses. Subject to the foregoing, Mozilla, for itself and on behalf of its licensors, hereby reserves all intellectual property rights in the Product, except for the rights expressly granted in this Agreement. You may not remove or alter any trademark, logo, copyright or other proprietary notice in or on the Product. This license does not grant you any right to use the trademarks, service marks or logos of Mozilla or its licensors.\n"
|
||||
"\n"
|
||||
"4. DISCLAIMER OF WARRANTY. THE PRODUCT IS PROVIDED ÒAS ISÓ WITH ALL FAULTS. TO THE EXTENT PERMITTED BY LAW, MOZILLA AND MOZILLAÕS LICENSORS HEREBY DISCLAIM ALL WARRANTIES, WHETHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES THAT THE PRODUCT IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE AND NON-INFRINGING. YOU BEAR ENTIRE RISK AS TO SELECTING THE PRODUCT FOR YOUR PURPOSES AND AS TO THE QUALITY AND PERFORMANCE OF THE PRODUCT. THIS LIMITATION WILL APPLY NOTWITHSTANDING THE FAILURE OF ESSENTIAL PURPOSE OF ANY REMEDY. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF IMPLIED WARRANTIES, SO THIS DISCLAIMER MAY NOT APPLY TO YOU.\n"
|
||||
"\n"
|
||||
"5. LIMITATION OF LIABILITY. EXCEPT AS REQUIRED BY LAW, MOZILLA AND ITS DIRECTORS, LICENSORS, CONTRIBUTORS AND AGENTS (COLLECTIVELY, THE ÒMOZILLA GROUPÓ) WILL NOT BE LIABLE FOR ANY INDIRECT, SPECIAL, INCIDENTAL, CONSEQUENTIAL OR EXEMPLARY DAMAGES ARISING OUT OF OR IN ANY WAY RELATING TO THIS AGREEMENT OR THE USE OF OR INABILITY TO USE THE PRODUCT, INCLUDING WITHOUT LIMITATION DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, LOST PROFITS, LOSS OF DATA, AND COMPUTER FAILURE OR MALFUNCTION, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES AND REGARDLESS OF THE THEORY (CONTRACT, TORT OR OTHERWISE) UPON WHICH SUCH CLAIM IS BASED. THE MOZILLA GROUPÕS COLLECTIVE LIABILITY UNDER THIS AGREEMENT WILL NOT EXCEED THE GREATER OF $500 (FIVE HUNDRED DOLLARS) AND THE FEES PAID BY YOU UNDER THIS LICENSE (IF ANY). SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL, CONSEQUENTIAL OR SPECIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU.\n"
|
||||
"\n"
|
||||
"6. EXPORT CONTROLS. This license is subject to all applicable export restrictions. You must comply with all export and import laws and restrictions and regulations of any United States or foreign agency or authority relating to the Product and its use.\n"
|
||||
"\n"
|
||||
"7. U.S. GOVERNMENT END-USERS. The Product is a Òcommercial item,Ó as that term is defined in 48 C.F.R. 2.101, consisting of Òcommercial computer softwareÓ and Òcommercial computer software documentation,Ó as such terms are used in 48 C.F.R. 12.212 (Sept. 1995) and 48 C.F.R. 227.7202 (June 1995). Consistent with 48 C.F.R. 12.212, 48 C.F.R. 27.405(b)(2) (June 1998) and 48 C.F.R. 227.7202, all U.S. Government End Users acquire the Product with only those rights as set forth herein.\n"
|
||||
"\n"
|
||||
"8. MISCELLANEOUS. (a) This Agreement constitutes the entire agreement between Mozilla and you concerning the subject matter hereof, and it may only be modified by a written amendment signed by an authorized executive of Mozilla. (b) Except to the extent applicable law, if any, provides otherwise, this Agreement will be governed by the laws of the state of California, U.S.A., excluding its conflict of law provisions. (c) This Agreement will not be governed by the United Nations Convention on Contracts for the International Sale of Goods. "
|
||||
"(d) If any part of this Agreement is held invalid or unenforceable, that part will be construed to reflect the partiesÕ original intent, and the remaining portions will remain in full force and effect. (e) A waiver by either party of any term or condition of this Agreement or any breach thereof, in any one instance, will not waive such term or condition or any subsequent breach thereof. (f) Except as required by law, the controlling language of this Agreement is English. "
|
||||
"(g) You may assign your rights under this Agreement to any party that consents to, and agrees to be bound by, its terms; the Mozilla Foundation may assign its rights under this Agreement without condition. (h) This Agreement will be binding upon and will inure to the benefit of the parties, their successors and permitted assigns."
|
||||
};
|
||||
|
||||
data 'styl' (5000, "English") {
|
||||
// Number of styles following = 3
|
||||
$"0003"
|
||||
|
||||
// Style 1. This is used to display the message about translations.
|
||||
// Start character = 0
|
||||
$"0000 0000"
|
||||
// Height = 16
|
||||
$"0010"
|
||||
// Ascent = 12
|
||||
$"000C"
|
||||
// Font family = 1024 (Lucida Grande)
|
||||
$"0400"
|
||||
// Style bitfield, 0x1=bold 0x2=italic 0x4=underline 0x8=outline
|
||||
// 0x10=shadow 0x20=condensed 0x40=extended
|
||||
$"00"
|
||||
// Style, unused?
|
||||
$"02"
|
||||
// Size = 12 point
|
||||
$"000C"
|
||||
// Color, RGB
|
||||
$"0000 0000 0000"
|
||||
|
||||
// Style 2. This is used to display the header lines in bold text.
|
||||
// Start character = 99
|
||||
$"0000 0063"
|
||||
// Height = 16
|
||||
$"0010"
|
||||
// Ascent = 12
|
||||
$"000C"
|
||||
// Font family = 1024 (Lucida Grande)
|
||||
$"0400"
|
||||
// Style bitfield, 0x1=bold 0x2=italic 0x4=underline 0x8=outline
|
||||
// 0x10=shadow 0x20=condensed 0x40=extended
|
||||
$"01"
|
||||
// Style, unused?
|
||||
$"02"
|
||||
// Size = 12 point
|
||||
$"000C"
|
||||
// Color, RGB
|
||||
$"0000 0000 0000"
|
||||
|
||||
// Style 3. This is used to display the body.
|
||||
// Start character = 164
|
||||
$"0000 00A4"
|
||||
// Height = 16
|
||||
$"0010"
|
||||
// Ascent = 12
|
||||
$"000C"
|
||||
// Font family = 1024 (Lucida Grande)
|
||||
$"0400"
|
||||
// Style bitfield, 0x1=bold 0x2=italic 0x4=underline 0x8=outline
|
||||
// 0x10=shadow 0x20=condensed 0x40=extended
|
||||
$"00"
|
||||
// Style, unused?
|
||||
$"02"
|
||||
// Size = 12 point
|
||||
$"000C"
|
||||
// Color, RGB
|
||||
$"0000 0000 0000"
|
||||
};
|
||||
@@ -1,8 +0,0 @@
|
||||
WIN32_MODULE_COMPANYNAME=Mozilla Corporation
|
||||
WIN32_MODULE_COPYRIGHT=©Firefox and Mozilla Developers, according to the MPL 1.1/GPL 2.0/LGPL 2.1 licenses, as applicable.
|
||||
WIN32_MODULE_PRODUCTVERSION=1,5,0,1
|
||||
WIN32_MODULE_PRODUCTVERSION_STRING=1.5.0.1
|
||||
WIN32_MODULE_TRADEMARKS=Firefox is a Trademark of The Mozilla Foundation.
|
||||
WIN32_MODULE_DESCRIPTION=Firefox
|
||||
WIN32_MODULE_PRODUCTNAME=Firefox
|
||||
WIN32_MODULE_NAME=Firefox
|
||||
|
Before Width: | Height: | Size: 16 KiB |
@@ -1,156 +0,0 @@
|
||||
/* XPM */
|
||||
static char * mozicon16_xpm[] = {
|
||||
"16 16 137 2",
|
||||
" c None",
|
||||
". c #388BBF",
|
||||
"+ c #59ADD6",
|
||||
"@ c #68CEEF",
|
||||
"# c #62CCEE",
|
||||
"$ c #45AAD7",
|
||||
"% c #3578AF",
|
||||
"& c #4A93C3",
|
||||
"* c #5EA9D2",
|
||||
"= c #72D1EF",
|
||||
"- c #6DCCEC",
|
||||
"; c #4B9FCE",
|
||||
"> c #3483BA",
|
||||
", c #1E67A5",
|
||||
"' c #1B6BA5",
|
||||
") c #2F7AB0",
|
||||
"! c #48B9E0",
|
||||
"~ c #5CC2E5",
|
||||
"{ c #6ED0EE",
|
||||
"] c #6FC9E9",
|
||||
"^ c #4994C5",
|
||||
"/ c #3783B9",
|
||||
"( c #1E5D9D",
|
||||
"_ c #1463A1",
|
||||
": c #028DC4",
|
||||
"< c #128DC3",
|
||||
"[ c #27ABD7",
|
||||
"} c #3CB8E0",
|
||||
"| c #4EC0E5",
|
||||
"1 c #5BC3E6",
|
||||
"2 c #50A2CE",
|
||||
"3 c #3B7EB5",
|
||||
"4 c #3C93C4",
|
||||
"5 c #2164A1",
|
||||
"6 c #145A9A",
|
||||
"7 c #0E8FC4",
|
||||
"8 c #007EBA",
|
||||
"9 c #0694C8",
|
||||
"0 c #1896C7",
|
||||
"a c #2B99C9",
|
||||
"b c #3CB7DE",
|
||||
"c c #48B9DF",
|
||||
"d c #3E95C5",
|
||||
"e c #2E71AB",
|
||||
"f c #399DCA",
|
||||
"g c #34A9D4",
|
||||
"h c #2387BE",
|
||||
"i c #1388C0",
|
||||
"j c #0059A1",
|
||||
"k c #005C9E",
|
||||
"l c #00498B",
|
||||
"m c #095897",
|
||||
"n c #1869A3",
|
||||
"o c #289CCA",
|
||||
"p c #34B1DA",
|
||||
"q c #3BB3DB",
|
||||
"r c #3BB3DA",
|
||||
"s c #35AFD7",
|
||||
"t c #2BA2CF",
|
||||
"u c #1E6AA2",
|
||||
"v c #106AA7",
|
||||
"w c #0258A0",
|
||||
"x c #00357F",
|
||||
"y c #002D71",
|
||||
"z c #003175",
|
||||
"A c #013A7E",
|
||||
"B c #084889",
|
||||
"C c #1577AF",
|
||||
"D c #1FA1CF",
|
||||
"E c #26A3D1",
|
||||
"F c #28A2CF",
|
||||
"G c #269ACA",
|
||||
"H c #2088BE",
|
||||
"I c #174784",
|
||||
"J c #0B1F5F",
|
||||
"K c #012568",
|
||||
"L c #00206A",
|
||||
"M c #00185A",
|
||||
"N c #001F62",
|
||||
"O c #002569",
|
||||
"P c #002C70",
|
||||
"Q c #0567A7",
|
||||
"R c #0D81BB",
|
||||
"S c #1485BD",
|
||||
"T c #1883BC",
|
||||
"U c #177DB7",
|
||||
"V c #144A88",
|
||||
"W c #0C1D5C",
|
||||
"X c #030B47",
|
||||
"Y c #00023B",
|
||||
"Z c #00207A",
|
||||
"` c #002072",
|
||||
" . c #00236B",
|
||||
".. c #001556",
|
||||
"+. c #001B5E",
|
||||
"@. c #003D81",
|
||||
"#. c #01599E",
|
||||
"$. c #04559E",
|
||||
"%. c #0761A6",
|
||||
"&. c #085499",
|
||||
"*. c #061958",
|
||||
"=. c #020843",
|
||||
"-. c #000137",
|
||||
";. c #001C79",
|
||||
">. c #00155D",
|
||||
",. c #000945",
|
||||
"'. c #000B49",
|
||||
"). c #000E4C",
|
||||
"!. c #002367",
|
||||
"~. c #002A6F",
|
||||
"{. c #003E8B",
|
||||
"]. c #003787",
|
||||
"^. c #00175C",
|
||||
"/. c #000035",
|
||||
"(. c #000030",
|
||||
"_. c #000E67",
|
||||
":. c #00043B",
|
||||
"<. c #000339",
|
||||
"[. c #00043C",
|
||||
"}. c #00053E",
|
||||
"|. c #00063F",
|
||||
"1. c #000E4F",
|
||||
"2. c #00247E",
|
||||
"3. c #00166A",
|
||||
"4. c #00002E",
|
||||
"5. c #00014F",
|
||||
"6. c #000029",
|
||||
"7. c #00012F",
|
||||
"8. c #000953",
|
||||
"9. c #000E6E",
|
||||
"0. c #000A6C",
|
||||
"a. c #000563",
|
||||
"b. c #00002F",
|
||||
"c. c #00001D",
|
||||
"d. c #000025",
|
||||
"e. c #000040",
|
||||
"f. c #000033",
|
||||
" ",
|
||||
" . + @ # $ ",
|
||||
" % & * = - ; > , ",
|
||||
" ' ) ! ~ { ] ^ / ( _ ",
|
||||
" : < [ } | 1 2 3 4 5 6 7 ",
|
||||
" 8 9 0 a b c d e f g h i ",
|
||||
" j k l m n o p q r s t u v w ",
|
||||
" x y z A B C D E F G H I J K ",
|
||||
" L M N O P Q R S T U V W X Y ",
|
||||
" Z ` ...+.@.#.$.%.&.*.=.-. ",
|
||||
" ;.>.,.'.).!.~.{.].^./.(. ",
|
||||
" _.:.<.[.}.|.1.2.3.4. ",
|
||||
" 5.6.(.4.7.8.9.0.a. ",
|
||||
" b.b.c.d.e.f. ",
|
||||
" ",
|
||||
" "};
|
||||
@@ -1,190 +0,0 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
## $Id: mozilla.in,v 1.12.8.1 2005-09-20 21:13:03 dbaron%dbaron.org Exp $
|
||||
##
|
||||
## Usage:
|
||||
##
|
||||
## $ mozilla [args]
|
||||
##
|
||||
## This script is meant to run the mozilla-bin binary from either
|
||||
## mozilla/xpfe/bootstrap or mozilla/dist/bin.
|
||||
##
|
||||
## The script will setup all the environment voodoo needed to make
|
||||
## the mozilla-bin binary to work.
|
||||
##
|
||||
|
||||
moz_pis_startstop_scripts()
|
||||
{
|
||||
MOZ_USER_DIR="%MOZ_USER_DIR%"
|
||||
# MOZ_PIS_ is the name space for "Mozilla Plugable Init Scripts"
|
||||
# These variables and there meaning are specified in
|
||||
# mozilla/xpfe/bootstrap/init.d/README
|
||||
MOZ_PIS_API=2
|
||||
MOZ_PIS_MOZBINDIR="${dist_bin}"
|
||||
MOZ_PIS_SESSION_PID="$$"
|
||||
MOZ_PIS_USER_DIR="${MOZ_USER_DIR}"
|
||||
export MOZ_PIS_API MOZ_PIS_MOZBINDIR MOZ_PIS_SESSION_PID MOZ_PIS_USER_DIR
|
||||
|
||||
case "${1}" in
|
||||
"start")
|
||||
for curr_pis in "${dist_bin}/init.d"/S* "${HOME}/${MOZ_USER_DIR}/init.d"/S* ; do
|
||||
if [ -x "${curr_pis}" ] ; then
|
||||
case "${curr_pis}" in
|
||||
*.sh) . "${curr_pis}" ;;
|
||||
*) "${curr_pis}" "start" ;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
;;
|
||||
"stop")
|
||||
for curr_pis in "${HOME}/${MOZ_USER_DIR}/init.d"/K* "${dist_bin}/init.d"/K* ; do
|
||||
if [ -x "${curr_pis}" ] ; then
|
||||
case "${curr_pis}" in
|
||||
*.sh) . "${curr_pis}" ;;
|
||||
*) "${curr_pis}" "stop" ;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
;;
|
||||
*)
|
||||
echo 1>&2 "$0: Internal error in moz_pis_startstop_scripts."
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
#uncomment for debugging
|
||||
#set -x
|
||||
|
||||
moz_libdir=%MOZAPPDIR%
|
||||
MRE_HOME=%MREDIR%
|
||||
|
||||
# Use run-mozilla.sh in the current dir if it exists
|
||||
# If not, then start resolving symlinks until we find run-mozilla.sh
|
||||
found=0
|
||||
progname="$0"
|
||||
curdir=`dirname "$progname"`
|
||||
progbase=`basename "$progname"`
|
||||
run_moz="$curdir/run-mozilla.sh"
|
||||
if test -x "$run_moz"; then
|
||||
dist_bin="$curdir"
|
||||
found=1
|
||||
else
|
||||
here=`/bin/pwd`
|
||||
while [ -h "$progname" ]; do
|
||||
bn=`basename "$progname"`
|
||||
cd `dirname "$progname"`
|
||||
progname=`/bin/ls -l "$bn" | sed -e 's/^.* -> //' `
|
||||
if [ ! -x "$progname" ]; then
|
||||
break
|
||||
fi
|
||||
curdir=`dirname "$progname"`
|
||||
run_moz="$curdir/run-mozilla.sh"
|
||||
if [ -x "$run_moz" ]; then
|
||||
cd "$curdir"
|
||||
dist_bin=`pwd`
|
||||
run_moz="$dist_bin/run-mozilla.sh"
|
||||
found=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
cd "$here"
|
||||
fi
|
||||
if [ $found = 0 ]; then
|
||||
# Check default compile-time libdir
|
||||
if [ -x "$moz_libdir/run-mozilla.sh" ]; then
|
||||
dist_bin="$moz_libdir"
|
||||
else
|
||||
echo "Cannot find mozilla runtime directory. Exiting."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
script_args=""
|
||||
debugging=0
|
||||
MOZILLA_BIN="${progbase}-bin"
|
||||
|
||||
if [ "$OSTYPE" = "beos" ]; then
|
||||
mimeset -F "$MOZILLA_BIN"
|
||||
fi
|
||||
|
||||
pass_arg_count=0
|
||||
while [ $# -gt $pass_arg_count ]
|
||||
do
|
||||
case "$1" in
|
||||
-p | --pure | -pure)
|
||||
MOZILLA_BIN="${MOZILLA_BIN}.pure"
|
||||
shift
|
||||
;;
|
||||
-g | --debug)
|
||||
script_args="$script_args -g"
|
||||
debugging=1
|
||||
shift
|
||||
;;
|
||||
-d | --debugger)
|
||||
script_args="$script_args -d $2"
|
||||
shift 2
|
||||
;;
|
||||
*)
|
||||
# Move the unrecognized argument to the end of the list.
|
||||
arg="$1"
|
||||
shift
|
||||
set -- "$@" "$arg"
|
||||
pass_arg_count=`expr $pass_arg_count + 1`
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
export MRE_HOME
|
||||
|
||||
## Start addon scripts
|
||||
moz_pis_startstop_scripts "start"
|
||||
|
||||
if [ $debugging = 1 ]
|
||||
then
|
||||
echo $dist_bin/run-mozilla.sh $script_args $dist_bin/$MOZILLA_BIN "$@"
|
||||
fi
|
||||
"$dist_bin/run-mozilla.sh" $script_args "$dist_bin/$MOZILLA_BIN" "$@"
|
||||
exitcode=$?
|
||||
|
||||
## Stop addon scripts
|
||||
moz_pis_startstop_scripts "stop"
|
||||
|
||||
exit $exitcode
|
||||
# EOF.
|
||||
@@ -1,72 +0,0 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2002
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Brian Ryner <bryner@brianryner.com>
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#include "nsXULAppAPI.h"
|
||||
#ifdef XP_WIN
|
||||
#include <windows.h>
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
#include "nsBuildID.h"
|
||||
|
||||
static const nsXREAppData kAppData = {
|
||||
sizeof(nsXREAppData),
|
||||
nsnull,
|
||||
"Mozilla",
|
||||
"Firefox",
|
||||
NS_STRINGIFY(APP_VERSION),
|
||||
NS_STRINGIFY(BUILD_ID),
|
||||
"{ec8030f7-c20a-464f-9b0e-13a3a9e97384}",
|
||||
"Copyright (c) 1998 - 2006 mozilla.org",
|
||||
NS_XRE_ENABLE_PROFILE_MIGRATOR |
|
||||
NS_XRE_ENABLE_EXTENSION_MANAGER
|
||||
};
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
return XRE_main(argc, argv, &kAppData);
|
||||
}
|
||||
|
||||
#if defined( XP_WIN ) && defined( WIN32 ) && !defined(__GNUC__)
|
||||
// We need WinMain in order to not be a console app. This function is
|
||||
// unused if we are a console application.
|
||||
int WINAPI WinMain( HINSTANCE, HINSTANCE, LPSTR args, int )
|
||||
{
|
||||
// Do the real work.
|
||||
return main( __argc, __argv );
|
||||
}
|
||||
#endif
|
||||
@@ -1,2 +0,0 @@
|
||||
#filter substitution
|
||||
pref("app.update.channel", "@MOZ_UPDATE_CHANNEL@");
|
||||
@@ -1,8 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<RDF xmlns:em="http://www.mozilla.org/2004/em-rdf#"
|
||||
xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
|
||||
|
||||
<Seq about="urn:mozilla:item:root"/>
|
||||
|
||||
</RDF>
|
||||
@@ -1,47 +0,0 @@
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
DIRS = {972ce4c6-7e08-4474-a285-3208198ce6fd}
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
@@ -1 +0,0 @@
|
||||
theme,{972ce4c6-7e08-4474-a285-3208198ce6fd}
|
||||
@@ -1,57 +0,0 @@
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../../../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
DEFINES += -DFIREFOX_VERSION=$(FIREFOX_VERSION)
|
||||
|
||||
FILES := \
|
||||
install.rdf \
|
||||
$(NULL)
|
||||
|
||||
libs::
|
||||
$(PERL) $(MOZILLA_DIR)/config/preprocessor.pl $(DEFINES) $(ACDEFINES) $(srcdir)/install.rdf.in > install.rdf
|
||||
$(INSTALL) $(FILES) $(DIST)/bin/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}
|
||||
|
||||
install::
|
||||
$(SYSINSTALL) $(IFLAGS1) $(FILES) $(DESTDIR)$(mozappdir)/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}
|
||||
@@ -1,44 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
#filter substitution
|
||||
|
||||
<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:em="http://www.mozilla.org/2004/em-rdf#">
|
||||
|
||||
<Description about="urn:mozilla:install-manifest">
|
||||
<em:id>{972ce4c6-7e08-4474-a285-3208198ce6fd}</em:id>
|
||||
<em:version>2.0</em:version>
|
||||
|
||||
<!-- Target Application this theme can install into,
|
||||
with minimum and maximum supported versions. -->
|
||||
<em:targetApplication>
|
||||
<Description>
|
||||
<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>
|
||||
<em:minVersion>@FIREFOX_VERSION@</em:minVersion>
|
||||
<em:maxVersion>@FIREFOX_VERSION@</em:maxVersion>
|
||||
</Description>
|
||||
</em:targetApplication>
|
||||
|
||||
<!-- Front End MetaData -->
|
||||
<em:name>Firefox (default)</em:name>
|
||||
<em:description>The default theme</em:description>
|
||||
|
||||
<!-- EXTENSION AUTHORS!
|
||||
DO NOT COPY THIS PROPERTY INTO YOUR INSTALL RDF FILES
|
||||
It will cause users not to be informed of incompatibilities
|
||||
with your extension when they are updated with Software Update
|
||||
and your extension will become unavailable to them!
|
||||
-->
|
||||
<em:appManaged>true</em:appManaged>
|
||||
|
||||
<em:locked>true</em:locked>
|
||||
|
||||
<!-- Front End Integration Hooks (used by Theme Manager)-->
|
||||
<!-- XXXben - preprocess this file to use different info for mac version -->
|
||||
<em:creator>Gerich and Horlander</em:creator>
|
||||
<em:contributor>Mozilla Contributors</em:contributor>
|
||||
|
||||
<em:internalName>classic/1.0</em:internalName>
|
||||
</Description>
|
||||
|
||||
</RDF>
|
||||
@@ -1,417 +0,0 @@
|
||||
/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
// XXX Toolkit-specific preferences should be moved into toolkit.js
|
||||
|
||||
#filter substitution
|
||||
|
||||
# SYNTAX HINTS: dashes are delimiters. Use underscores instead.
|
||||
# The first character after a period must be alphabetic.
|
||||
|
||||
#ifdef XP_UNIX
|
||||
#ifndef XP_MACOSX
|
||||
#define UNIX_BUT_NOT_MAC
|
||||
#endif
|
||||
#endif
|
||||
|
||||
pref("startup.homepage_override_url","chrome://browser-region/locale/region.properties");
|
||||
pref("general.startup.browser", true);
|
||||
|
||||
pref("browser.chromeURL","chrome://browser/content/");
|
||||
pref("browser.hiddenWindowChromeURL", "chrome://browser/content/hiddenWindow.xul");
|
||||
pref("xpinstall.dialog.confirm", "chrome://mozapps/content/xpinstall/xpinstallConfirm.xul");
|
||||
pref("xpinstall.dialog.progress.skin", "chrome://mozapps/content/extensions/extensions.xul?type=themes");
|
||||
pref("xpinstall.dialog.progress.chrome", "chrome://mozapps/content/extensions/extensions.xul?type=extensions");
|
||||
pref("xpinstall.dialog.progress.type.skin", "Extension:Manager-themes");
|
||||
pref("xpinstall.dialog.progress.type.chrome", "Extension:Manager-extensions");
|
||||
|
||||
pref("extensions.getMoreExtensionsURL", "chrome://mozapps/locale/extensions/extensions.properties");
|
||||
pref("extensions.getMoreThemesURL", "chrome://mozapps/locale/extensions/extensions.properties");
|
||||
// Developers can set this to |true| if they are constantly changing files in their
|
||||
// extensions directory so that the extension system does not constantly think that
|
||||
// their extensions are being updated and thus reregistered every time the app is
|
||||
// started.
|
||||
pref("extensions.ignoreMTimeChanges", false);
|
||||
// Enables some extra Extension System Logging (can reduce performance)
|
||||
pref("extensions.logging.enabled", false);
|
||||
|
||||
// App-specific update preferences
|
||||
|
||||
// Whether or not app updates are enabled
|
||||
pref("app.update.enabled", true);
|
||||
|
||||
// This preference turns on app.update.mode and allows automatic download and
|
||||
// install to take place. We use a separate boolean toggle for this to make
|
||||
// the UI easier to construct.
|
||||
pref("app.update.auto", true);
|
||||
|
||||
// Defines how the Application Update Service notifies the user about updates:
|
||||
//
|
||||
// AUM Set to: Minor Releases: Major Releases:
|
||||
// 0 download no prompt download no prompt
|
||||
// 1 download no prompt download no prompt if no incompatibilities
|
||||
// 2 download no prompt prompt
|
||||
//
|
||||
// See chart in nsUpdateService.js.in for more details
|
||||
//
|
||||
pref("app.update.mode", 1);
|
||||
|
||||
// If set to true, the Update Service will present no UI for any event.
|
||||
pref("app.update.silent", false);
|
||||
|
||||
// Update service URL:
|
||||
pref("app.update.url", "https://aus2.mozilla.org/update/1/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/update.xml");
|
||||
// URL user can browse to manually if for some reason all update installation
|
||||
// attempts fail. TODO: Change this URL
|
||||
pref("app.update.url.manual", "http://www.mozilla.org/products/firefox/");
|
||||
// A default value for the "More information about this update" link
|
||||
// supplied in the "An update is available" page of the update wizard.
|
||||
pref("app.update.url.details", "chrome://browser-region/locale/region.properties");
|
||||
|
||||
// User-settable override to app.update.url for testing purposes.
|
||||
//pref("app.update.url.override", "");
|
||||
|
||||
// Interval: Time between checks for a new version (in seconds)
|
||||
// default=1 day
|
||||
pref("app.update.interval", 86400);
|
||||
// Interval: Time before prompting the user to download a new version that
|
||||
// is available (in seconds) default=1 day
|
||||
pref("app.update.nagTimer.download", 86400);
|
||||
// Interval: Time before prompting the user to restart to install the latest
|
||||
// download (in seconds) default=30 minutes
|
||||
pref("app.update.nagTimer.restart", 1800);
|
||||
// Interval: When all registered timers should be checked (in milliseconds)
|
||||
// default=5 seconds
|
||||
pref("app.update.timer", 600000);
|
||||
|
||||
// Whether or not we show a dialog box informing the user that the update was
|
||||
// successfully applied. This is off in Firefox by default since we show a
|
||||
// upgrade start page instead! Other apps may wish to show this UI, and supply
|
||||
// a whatsNewURL field in their brand.properties that contains a link to a page
|
||||
// which tells users what's new in this new update.
|
||||
pref("app.update.showInstalledUI", false);
|
||||
|
||||
// 0 = suppress prompting for incompatibilities if there are updates available
|
||||
// to newer versions of installed addons that resolve them.
|
||||
// 1 = suppress prompting for incompatibilities only if there are VersionInfo
|
||||
// updates available to installed addons that resolve them, not newer
|
||||
// versions.
|
||||
pref("app.update.incompatible.mode", 0);
|
||||
|
||||
// Symmetric (can be overridden by individual extensions) update preferences.
|
||||
// e.g.
|
||||
// extensions.{GUID}.update.enabled
|
||||
// extensions.{GUID}.update.url
|
||||
// extensions.{GUID}.update.interval
|
||||
// .. etc ..
|
||||
//
|
||||
pref("extensions.update.enabled", true);
|
||||
pref("extensions.update.url", "chrome://mozapps/locale/extensions/extensions.properties");
|
||||
pref("extensions.update.interval", 86400); // Check for updates to Extensions and
|
||||
// Themes every week
|
||||
// Non-symmetric (not shared by extensions) extension-specific [update] preferences
|
||||
pref("extensions.getMoreExtensionsURL", "chrome://mozapps/locale/extensions/extensions.properties");
|
||||
pref("extensions.getMoreThemesURL", "chrome://mozapps/locale/extensions/extensions.properties");
|
||||
pref("extensions.dss.enabled", false); // Dynamic Skin Switching
|
||||
pref("extensions.dss.switchPending", false); // Non-dynamic switch pending after next
|
||||
// restart.
|
||||
|
||||
pref("xpinstall.whitelist.add", "update.mozilla.org");
|
||||
pref("xpinstall.whitelist.add.103", "addons.mozilla.org");
|
||||
|
||||
pref("keyword.enabled", true);
|
||||
pref("keyword.URL", "http://www.google.com/search?btnI=I%27m+Feeling+Lucky&ie=UTF-8&oe=UTF-8&q=");
|
||||
|
||||
pref("general.useragent.locale", "@AB_CD@");
|
||||
pref("general.skins.selectedSkin", "classic/1.0");
|
||||
pref("general.useragent.extra.firefox", "Firefox/@APP_VERSION@");
|
||||
|
||||
pref("general.smoothScroll", false);
|
||||
#ifdef UNIX_BUT_NOT_MAC
|
||||
pref("general.autoScroll", false);
|
||||
#else
|
||||
pref("general.autoScroll", true);
|
||||
#endif
|
||||
|
||||
// Whether or not the application should check at startup each time if it
|
||||
// is the default browser.
|
||||
pref("browser.shell.checkDefaultBrowser", true);
|
||||
|
||||
// 0 = blank, 1 = home (browser.startup.homepage), 2 = last
|
||||
// XXXBlake Remove this stupid pref
|
||||
pref("browser.startup.page", 1);
|
||||
pref("browser.startup.homepage", "resource:/browserconfig.properties");
|
||||
|
||||
pref("browser.cache.disk.capacity", 50000);
|
||||
pref("browser.enable_automatic_image_resizing", true);
|
||||
pref("browser.urlbar.matchOnlyTyped", false);
|
||||
pref("browser.chrome.site_icons", true);
|
||||
pref("browser.chrome.favicons", true);
|
||||
pref("browser.formfill.enable", true);
|
||||
|
||||
pref("browser.download.useDownloadDir", true);
|
||||
pref("browser.download.folderList", 0);
|
||||
#ifdef XP_WIN
|
||||
pref("browser.download.manager.showAlertOnComplete", true);
|
||||
#else
|
||||
pref("browser.download.manager.showAlertOnComplete", false);
|
||||
#endif
|
||||
pref("browser.download.manager.showAlertInterval", 2000);
|
||||
pref("browser.download.manager.retention", 2);
|
||||
pref("browser.download.manager.showWhenStarting", true);
|
||||
pref("browser.download.manager.useWindow", true);
|
||||
pref("browser.download.manager.closeWhenDone", false);
|
||||
pref("browser.download.manager.openDelay", 0);
|
||||
pref("browser.download.manager.focusWhenStarting", false);
|
||||
pref("browser.download.manager.flashCount", 2);
|
||||
|
||||
// pointer to the default engine name
|
||||
pref("browser.search.defaultenginename", "chrome://browser-region/locale/region.properties");
|
||||
// pointer to the Web Search url (content area context menu)
|
||||
pref("browser.search.defaulturl", "chrome://browser-region/locale/region.properties");
|
||||
// Ordering of Search Engines in the Engine list.
|
||||
pref("browser.search.order.1", "chrome://browser-region/locale/region.properties");
|
||||
pref("browser.search.order.2", "chrome://browser-region/locale/region.properties");
|
||||
|
||||
pref("browser.search.param.Google.1.default", "chrome://branding/content/searchconfig.properties");
|
||||
pref("browser.search.param.Google.1.custom", "chrome://branding/content/searchconfig.properties");
|
||||
pref("browser.search.order.Yahoo.1", "chrome://branding/content/searchconfig.properties");
|
||||
pref("browser.search.order.Yahoo.2", "chrome://branding/content/searchconfig.properties");
|
||||
pref("browser.search.order.Yahoo", "chrome://branding/content/searchconfig.properties");
|
||||
|
||||
// basic search popup constraint: minimum sherlock plugin version displayed
|
||||
// (note: must be a string representation of a float or it'll default to 0.0)
|
||||
pref("browser.search.basic.min_ver", "0.0");
|
||||
|
||||
// send ping to the server to update
|
||||
pref("browser.search.update", true);
|
||||
|
||||
pref("browser.history.grouping", "day");
|
||||
pref("browser.sessionhistory.max_entries", 50);
|
||||
|
||||
// handle external links
|
||||
// 0=default window, 1=current window/tab, 2=new window, 3=new tab in most recent window
|
||||
pref("browser.link.open_external", 3);
|
||||
|
||||
// handle links targeting new windows
|
||||
pref("browser.link.open_newwindow", 2);
|
||||
|
||||
// 0: no restrictions - divert everything
|
||||
// 1: don't divert window.open at all
|
||||
// 2: don't divert window.open with features
|
||||
pref("browser.link.open_newwindow.restriction", 2);
|
||||
|
||||
// Tab browser preferences.
|
||||
pref("browser.tabs.loadInBackground", true);
|
||||
pref("browser.tabs.loadFolderAndReplace", true);
|
||||
pref("browser.tabs.opentabfor.middleclick", true);
|
||||
pref("browser.tabs.opentabfor.urlbar", true);
|
||||
pref("browser.tabs.loadDivertedInBackground", false);
|
||||
pref("browser.tabs.loadBookmarksInBackground", false);
|
||||
|
||||
// Smart Browsing prefs
|
||||
pref("browser.related.enabled", true);
|
||||
pref("browser.related.autoload", 1); // 0 = Always, 1 = After first use, 2 = Never
|
||||
pref("browser.related.provider", "http://www-rl.netscape.com/wtgn?");
|
||||
pref("browser.related.disabledForDomains", "");
|
||||
pref("browser.goBrowsing.enabled", true);
|
||||
|
||||
// Default bookmark sorting
|
||||
pref("browser.bookmarks.sort.direction", "descending");
|
||||
pref("browser.bookmarks.sort.resource", "rdf:http://home.netscape.com/NC-rdf#Name");
|
||||
|
||||
// Scripts & Windows prefs
|
||||
pref("dom.disable_open_during_load", true);
|
||||
pref("javascript.options.showInConsole", false);
|
||||
// Make the status bar reliably present and unaffected by pages
|
||||
pref("dom.disable_window_open_feature.status", true);
|
||||
// This is the pref to control the location bar, change this to true to
|
||||
// force this instead of or in addition to the status bar - this makes
|
||||
// the origin of popup windows more obvious to avoid spoofing but we
|
||||
// cannot do it by default because it affects UE for web applications.
|
||||
pref("dom.disable_window_open_feature.location", false);
|
||||
pref("dom.disable_window_status_change", true);
|
||||
// allow JS to move and resize existing windows
|
||||
pref("dom.disable_window_move_resize", false);
|
||||
// prevent JS from monkeying with window focus, etc
|
||||
pref("dom.disable_window_flip", false);
|
||||
|
||||
pref("browser.trim_user_and_password", true);
|
||||
|
||||
// popups.policy 1=allow,2=reject
|
||||
pref("privacy.popups.policy", 1);
|
||||
pref("privacy.popups.usecustom", true);
|
||||
pref("privacy.popups.firstTime", true);
|
||||
pref("privacy.popups.showBrowserMessage", true);
|
||||
|
||||
pref("privacy.item.history", true);
|
||||
pref("privacy.item.formdata", true);
|
||||
pref("privacy.item.passwords", false);
|
||||
pref("privacy.item.downloads", true);
|
||||
pref("privacy.item.cookies", false);
|
||||
pref("privacy.item.cache", true);
|
||||
pref("privacy.item.siteprefs", false);
|
||||
pref("privacy.item.sessions", true);
|
||||
|
||||
pref("privacy.sanitize.sanitizeOnShutdown", false);
|
||||
pref("privacy.sanitize.promptOnSanitize", true);
|
||||
|
||||
pref("network.proxy.share_proxy_settings", false); // use the same proxy settings for all protocols
|
||||
|
||||
pref("network.cookie.cookieBehavior", 0); // cookies enabled
|
||||
pref("network.cookie.enableForCurrentSessionOnly", false);
|
||||
pref("network.cookie.denyRemovedCookies", false);
|
||||
|
||||
// l12n and i18n
|
||||
pref("intl.accept_languages", "chrome://global/locale/intl.properties");
|
||||
// collationOption is only set on linux for japanese. see bug 18338 and 62015
|
||||
// we need to check if this pref is still useful.
|
||||
pref("intl.collationOption", "chrome://global-platform/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.static", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.more1", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.more2", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.more3", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.more4", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.more5", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charsetmenu.browser.unicode", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charset.detector", "chrome://global/locale/intl.properties");
|
||||
pref("intl.charset.default", "chrome://global-platform/locale/intl.properties");
|
||||
pref("font.language.group", "chrome://global/locale/intl.properties");
|
||||
pref("intl.menuitems.alwaysappendaccesskeys","chrome://global/locale/intl.properties");
|
||||
pref("intl.menuitems.insertseparatorbeforeaccesskeys","chrome://global/locale/intl.properties");
|
||||
|
||||
// 0=lines, 1=pages, 2=history , 3=text size
|
||||
#ifdef XP_MACOSX
|
||||
// On OS X, if the wheel has one axis only, shift+wheel comes through as a
|
||||
// horizontal scroll event. Thus, we can't assign anything other than normal
|
||||
// scrolling to shift+wheel.
|
||||
pref("mousewheel.withmetakey.action",3);
|
||||
pref("mousewheel.withmetakey.sysnumlines",false);
|
||||
pref("mousewheel.withcontrolkey.action",2);
|
||||
pref("mousewheel.withcontrolkey.sysnumlines",false);
|
||||
#else
|
||||
pref("mousewheel.withcontrolkey.action",3);
|
||||
pref("mousewheel.withcontrolkey.sysnumlines",false);
|
||||
pref("mousewheel.withshiftkey.action",2);
|
||||
pref("mousewheel.withshiftkey.sysnumlines",false);
|
||||
#endif
|
||||
pref("mousewheel.withaltkey.action",0);
|
||||
pref("mousewheel.withaltkey.sysnumlines",false);
|
||||
|
||||
pref("profile.allow_automigration", false); // setting to false bypasses automigration in the profile code
|
||||
|
||||
// Customizable toolbar stuff
|
||||
pref("custtoolbar.personal_toolbar_folder", "");
|
||||
pref("browser.throbber.url","chrome://browser-region/locale/region.properties");
|
||||
|
||||
// pref to control the alert notification
|
||||
pref("alerts.slideIncrement", 1);
|
||||
pref("alerts.slideIncrementTime", 10);
|
||||
pref("alerts.totalOpenTime", 4000);
|
||||
pref("alerts.height", 50);
|
||||
|
||||
pref("browser.xul.error_pages.enabled", true);
|
||||
|
||||
pref("signon.rememberSignons", true);
|
||||
pref("signon.expireMasterPassword", false);
|
||||
pref("signon.SignonFileName", "signons.txt");
|
||||
|
||||
// We want to make sure mail URLs are handled externally...
|
||||
pref("network.protocol-handler.external.mailto", true); // for mail
|
||||
pref("network.protocol-handler.external.news", true); // for news
|
||||
pref("network.protocol-handler.external.snews", true); // for secure news
|
||||
pref("network.protocol-handler.external.nntp", true); // also news
|
||||
// ...without warning dialogs
|
||||
pref("network.protocol-handler.warn-external.mailto", false);
|
||||
pref("network.protocol-handler.warn-external.news", false);
|
||||
pref("network.protocol-handler.warn-external.snews", false);
|
||||
pref("network.protocol-handler.warn-external.nntp", false);
|
||||
|
||||
// By default, all protocol handlers are exposed. This means that
|
||||
// the browser will respond to openURL commands for all URL types.
|
||||
// It will also try to open link clicks inside the browser before
|
||||
// failing over to the system handlers.
|
||||
pref("network.protocol-handler.expose-all", true);
|
||||
pref("network.protocol-handler.expose.mailto", false);
|
||||
pref("network.protocol-handler.expose.news", false);
|
||||
pref("network.protocol-handler.expose.snews", false);
|
||||
pref("network.protocol-handler.expose.nntp", false);
|
||||
|
||||
// Default security warning dialogs to show once.
|
||||
pref("security.warn_entering_secure.show_once", true);
|
||||
pref("security.warn_entering_weak.show_once", true);
|
||||
pref("security.warn_leaving_secure.show_once", true);
|
||||
pref("security.warn_viewing_mixed.show_once", true);
|
||||
pref("security.warn_submit_insecure.show_once", true);
|
||||
|
||||
#ifdef XP_UNIX
|
||||
pref("browser.urlbar.clickSelectsAll", false);
|
||||
#else
|
||||
pref("browser.urlbar.clickSelectsAll", true);
|
||||
#endif
|
||||
|
||||
pref("accessibility.typeaheadfind", false);
|
||||
pref("accessibility.typeaheadfind.timeout", 5000);
|
||||
pref("accessibility.typeaheadfind.linksonly", false);
|
||||
pref("accessibility.typeaheadfind.flashBar", 1);
|
||||
|
||||
// Disable the default plugin for firefox
|
||||
pref("plugin.default_plugin_disabled", true);
|
||||
|
||||
// plugin finder service url
|
||||
pref("pfs.datasource.url", "https://pfs.mozilla.org/plugins/PluginFinderService.php?mimetype=%PLUGIN_MIMETYPE%&appID=%APP_ID%&appVersion=%APP_VERSION%&clientOS=%CLIENT_OS%&chromeLocale=%CHROME_LOCALE%");
|
||||
|
||||
#ifdef XP_WIN
|
||||
pref("browser.preferences.instantApply", false);
|
||||
#else
|
||||
pref("browser.preferences.instantApply", true);
|
||||
#endif
|
||||
#ifdef XP_MACOSX
|
||||
pref("browser.preferences.animateFadeIn", true);
|
||||
#else
|
||||
pref("browser.preferences.animateFadeIn", false);
|
||||
#endif
|
||||
#ifndef XP_OS2
|
||||
pref("browser.display.screen_resolution", 96);
|
||||
#endif
|
||||
|
||||
pref("browser.download.show_plugins_in_list", true);
|
||||
pref("browser.download.hide_plugins_without_extensions", true);
|
||||
|
||||
// Setting this pref to |true| forces BiDi UI menu items and keyboard shortcuts
|
||||
// to be exposed. By default, only expose it for bidi-associated system locales.
|
||||
pref("bidi.browser.ui", false);
|
||||
@@ -1,39 +0,0 @@
|
||||
<?xml version="1.0"?> <!-- -*- Mode: SGML -*- -->
|
||||
<!-- ***** BEGIN LICENSE BLOCK *****
|
||||
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
-
|
||||
- The contents of this file are subject to the Mozilla Public License Version
|
||||
- 1.1 (the "License"); you may not use this file except in compliance with
|
||||
- the License. You may obtain a copy of the License at
|
||||
- http://www.mozilla.org/MPL/
|
||||
-
|
||||
- Software distributed under the License is distributed on an "AS IS" basis,
|
||||
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
- for the specific language governing rights and limitations under the
|
||||
- License.
|
||||
-
|
||||
- The Original Code is Mozilla Communicator.
|
||||
-
|
||||
- The Initial Developer of the Original Code is
|
||||
- Netscape Communications Corp.
|
||||
- Portions created by the Initial Developer are Copyright (C) 1999
|
||||
- the Initial Developer. All Rights Reserved.
|
||||
-
|
||||
- Contributor(s):
|
||||
-
|
||||
- Alternatively, the contents of this file may be used under the terms of
|
||||
- either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
- in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
- of those above. If you wish to allow use of your version of this file only
|
||||
- under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
- use your version of this file under the terms of the MPL, indicate your
|
||||
- decision by deleting the provisions above and replace them with the notice
|
||||
- and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
- the provisions above, a recipient may use your version of this file under
|
||||
- the terms of any one of the MPL, the GPL or the LGPL.
|
||||
-
|
||||
- ***** END LICENSE BLOCK ***** -->
|
||||
|
||||
<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"/>
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
# Mozilla User Preferences
|
||||
|
||||
/* Do not edit this file.
|
||||
*
|
||||
* If you make changes to this file while the browser is running,
|
||||
* the changes will be overwritten when the browser exits.
|
||||
*
|
||||
* To make a manual change to preferences, you can visit the URL about:config
|
||||
* For more information, see http://www.mozilla.org/unix/customizing.html#prefs
|
||||
*/
|
||||
@@ -1,87 +0,0 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is Mozilla Communicator client code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Bill Law law@netscape.com
|
||||
* Jonathan Wilson <jonwil@tpgi.com.au>
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
#include <windows.h>
|
||||
#include "nsNativeAppSupportWin.h"
|
||||
|
||||
1 24 "firefox.exe.manifest"
|
||||
|
||||
IDI_APPICON ICON FIREFOX_ICO
|
||||
IDI_DOCUMENT ICON DOCUMENT_ICO
|
||||
IDI_APPLICATION ICON FIREFOX_ICO
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
IDS_STARTMENU_APPNAME, "Firefox"
|
||||
END
|
||||
|
||||
#ifdef MOZ_STATIC_BUILD
|
||||
|
||||
// XXX This code is copied from resource.h and widget.rc. It's a work-around
|
||||
// for the limitation that only one resource file can be used in an .exe. We
|
||||
// should develop a method, for static builds only, to combine multiple .rc
|
||||
// files into a single .rc file, and then use that to build the single .res
|
||||
// file for the .exe.
|
||||
|
||||
// We need this cursor for versions of Windows that don't support IDC_HAND,
|
||||
// namely Win95 and NT4.
|
||||
#define IDC_SELECTANCHOR 4100
|
||||
#define IDC_GRAB 4101
|
||||
#define IDC_GRABBING 4102
|
||||
#define IDC_CELL 4103
|
||||
#define IDC_COPY 4104
|
||||
#define IDC_ALIAS 4105
|
||||
#define IDC_ZOOMIN 4106
|
||||
#define IDC_ZOOMOUT 4107
|
||||
#define IDC_COLRESIZE 4108
|
||||
#define IDC_ROWRESIZE 4109
|
||||
#define IDC_VERTICALTEXT 4110
|
||||
|
||||
IDC_SELECTANCHOR CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\select.cur"
|
||||
IDC_GRAB CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\grab.cur"
|
||||
IDC_GRABBING CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\grabbing.cur"
|
||||
IDC_CELL CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\cell.cur"
|
||||
IDC_COPY CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\copy.cur"
|
||||
IDC_ALIAS CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\aliasb.cur"
|
||||
IDC_ZOOMIN CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\zoom_in.cur"
|
||||
IDC_ZOOMOUT CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\zoom_out.cur"
|
||||
IDC_COLRESIZE CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\col_resize.cur"
|
||||
IDC_ROWRESIZE CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\row_resize.cur"
|
||||
IDC_VERTICALTEXT CURSOR DISCARDABLE "..\\..\\widget\\src\\build\\res\\vertical_text.cur"
|
||||
|
||||
#endif
|
||||
@@ -1,77 +0,0 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
*
|
||||
* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is Mozilla Communicator client code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Bill Law law@netscape.com
|
||||
* IBM Corp.
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
#include <os2.h>
|
||||
|
||||
// Splash screen dialog ID.
|
||||
#define IDD_SPLASH 100
|
||||
|
||||
// Splash screen bitmap ID.
|
||||
#define IDB_SPLASH 101
|
||||
|
||||
ICON 1 FIREFOX_ICO
|
||||
|
||||
DLGTEMPLATE IDD_SPLASH DISCARDABLE
|
||||
BEGIN
|
||||
DIALOG "", IDD_SPLASH, 0, 0, 390, 261, , FCF_BORDER
|
||||
BEGIN
|
||||
END
|
||||
END
|
||||
|
||||
//BITMAP IDB_SPLASH "splash.bmp"
|
||||
|
||||
#ifdef MOZ_STATIC_BUILD
|
||||
#include "wdgtos2rc.h"
|
||||
|
||||
POINTER IDC_SELECTANCHOR "..\\..\\widget\\src\\os2\\res\\select.ptr"
|
||||
POINTER IDC_GRAB "..\\..\\widget\\src\\os2\\res\\grab.ptr"
|
||||
POINTER IDC_GRABBING "..\\..\\widget\\src\\os2\\res\\grabbing.ptr"
|
||||
POINTER IDC_CELL "..\\..\\widget\\src\\os2\\res\\cell.ptr"
|
||||
POINTER IDC_COPY "..\\..\\widget\\src\\os2\\res\\copy.ptr"
|
||||
POINTER IDC_ALIAS "..\\..\\widget\\src\\os2\\res\\aliasb.ptr"
|
||||
POINTER IDC_ZOOMIN "..\\..\\widget\\src\\os2\\res\\zoom_in.ptr"
|
||||
POINTER IDC_ZOOMOUT "..\\..\\widget\\src\\os2\\res\\zoom_out.ptr"
|
||||
|
||||
POINTER IDC_ARROWWAIT "..\\..\\widget\\src\\os2\\res\\arrow_wait.ptr"
|
||||
POINTER IDC_CROSS "..\\..\\widget\\src\\os2\\res\\crosshair.ptr"
|
||||
POINTER IDC_HELP "..\\..\\widget\\src\\os2\\res\\help.ptr"
|
||||
|
||||
ICON IDC_DNDURL "..\\..\\widget\\src\\os2\\res\\dndurl.ico"
|
||||
ICON IDC_DNDTEXT "..\\..\\widget\\src\\os2\\res\\dndtext.ico"
|
||||
#endif
|
||||
@@ -1,69 +0,0 @@
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
include $(topsrcdir)/config/config.mk
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
DEFINES += -DMOZ_APP_VERSION=$(MOZ_APP_VERSION)
|
||||
|
||||
ifndef MOZ_BRANDING_DIRECTORY
|
||||
DEFINES += -DMOZ_USE_GENERIC_BRANDING
|
||||
endif
|
||||
|
||||
ifneq (,$(filter windows gtk2 mac cocoa, $(MOZ_WIDGET_TOOLKIT)))
|
||||
DEFINES += -DHAVE_SHELL_SERVICE=1
|
||||
endif
|
||||
|
||||
ifndef MOZ_BRANDING_DIRECTORY
|
||||
libs locale::
|
||||
$(INSTALL) $(srcdir)/content/browserconfig.properties $(DIST)/bin
|
||||
|
||||
install::
|
||||
$(SYSINSTALL) $(srcdir)/content/browserconfig.properties $(DESTDIR)$(mozappdir)
|
||||
endif
|
||||
|
||||
ifneq (,$(filter windows mac cocoa, $(MOZ_WIDGET_TOOLKIT)))
|
||||
DEFINES += -DCONTEXT_COPY_IMAGE_CONTENTS=1
|
||||
endif
|
||||
|
Before Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 764 B |
|
Before Width: | Height: | Size: 7.8 KiB |
@@ -1,6 +0,0 @@
|
||||
# Do NOT localize or otherwise change these values
|
||||
browser.search.param.Google.1.custom=client=firefox
|
||||
browser.search.param.Google.1.default=client=firefox
|
||||
browser.search.param.Google.release=rls=%S:%S:unofficial
|
||||
|
||||
browser.search.param.Yahoo.release=rls=%S:%S:unofficial
|
||||
@@ -1,6 +0,0 @@
|
||||
# These values are used to construct the registry keys for the Add/Remove
|
||||
# Programs dialog under Windows. They must be kept in sync with the values
|
||||
# used by the installer.
|
||||
fileUninstall=UninstallDeerPark.exe
|
||||
URLInfoAbout=http://www.mozilla.org/
|
||||
URLUpdateInfo=http://www.mozilla.org/products/firefox/
|
||||
@@ -1,58 +0,0 @@
|
||||
#aboutDialog {
|
||||
padding: 0px 0px 10px 0px;
|
||||
width: 299px;
|
||||
}
|
||||
|
||||
#clientBox {
|
||||
background-image: url("chrome://branding/content/about.png");
|
||||
background-repeat: no-repeat;
|
||||
background-color: #FFFFFF;
|
||||
padding-top: 203px;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
#brandName {
|
||||
font-weight: bold; font-size: larger;
|
||||
}
|
||||
|
||||
#detailsBox {
|
||||
padding: 8px 10px 0px 8px;
|
||||
}
|
||||
|
||||
#userAgent {
|
||||
margin: 3px 10px 0px 5px;
|
||||
background-color: #FFFFFF;
|
||||
color: #000000;
|
||||
padding: 1px 0px 0px 3px;
|
||||
-moz-appearance: none;
|
||||
overflow: hidden;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
#groove {
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
#creditsIframe {
|
||||
cursor: default;
|
||||
-moz-user-select: none;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
#version {
|
||||
font-weight: bold;
|
||||
color: #909090;
|
||||
margin: 1em 0px 10px 17px;
|
||||
}
|
||||
|
||||
#copyright {
|
||||
margin: 0px 0px 3px 16px;
|
||||
}
|
||||
|
||||
button[dlgtype="extra2"] {
|
||||
margin-left: 13px;
|
||||
}
|
||||
|
||||
button[dlgtype="accept"] {
|
||||
margin-right: 13px;
|
||||
}
|
||||
@@ -1,86 +0,0 @@
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Firebird about dialog.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Blake Ross (blaker@netscape.com).
|
||||
# Portions created by the Initial Developer are Copyright (C) 2002
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK ***** -->
|
||||
|
||||
var gSelectedPage = 0;
|
||||
|
||||
function init(aEvent)
|
||||
{
|
||||
if (aEvent.target != document)
|
||||
return;
|
||||
var userAgentField = document.getElementById("userAgent");
|
||||
userAgentField.value = navigator.userAgent;
|
||||
|
||||
var button = document.documentElement.getButton("extra2");
|
||||
button.setAttribute("label", document.documentElement.getAttribute("creditslabel"));
|
||||
button.addEventListener("command", switchPage, false);
|
||||
|
||||
document.documentElement.getButton("accept").focus();
|
||||
#ifdef XP_MACOSX
|
||||
// it may not be sized at this point, and we need its width to calculate its position
|
||||
window.sizeToContent();
|
||||
window.moveTo((screen.availWidth / 2) - (window.outerWidth / 2), screen.availHeight / 5);
|
||||
#endif
|
||||
}
|
||||
|
||||
function uninit(aEvent)
|
||||
{
|
||||
if (aEvent.target != document)
|
||||
return;
|
||||
var iframe = document.getElementById("creditsIframe");
|
||||
iframe.setAttribute("src", "");
|
||||
}
|
||||
|
||||
function switchPage(aEvent)
|
||||
{
|
||||
var button = aEvent.target;
|
||||
if (button.localName != "button")
|
||||
return;
|
||||
|
||||
var iframe = document.getElementById("creditsIframe");
|
||||
if (gSelectedPage == 0) {
|
||||
iframe.setAttribute("src", "chrome://browser/content/credits.xhtml");
|
||||
button.setAttribute("label", document.documentElement.getAttribute("aboutlabel"));
|
||||
gSelectedPage = 1;
|
||||
}
|
||||
else {
|
||||
iframe.setAttribute("src", "");
|
||||
button.setAttribute("label", document.documentElement.getAttribute("creditslabel"));
|
||||
gSelectedPage = 0;
|
||||
}
|
||||
var modes = document.getElementById("modes");
|
||||
modes.setAttribute("selectedIndex", gSelectedPage);
|
||||
}
|
||||
|
||||
@@ -1,96 +0,0 @@
|
||||
<?xml version="1.0"?> <!-- -*- Mode: HTML -*- -->
|
||||
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Firebird about dialog.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Blake Ross (blaker@netscape.com).
|
||||
# Portions created by the Initial Developer are Copyright (C) 2002
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK ***** -->
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://browser/content/aboutDialog.css" type="text/css"?>
|
||||
|
||||
<!DOCTYPE window [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
|
||||
%brandDTD;
|
||||
<!ENTITY % aboutDialogDTD SYSTEM "chrome://browser/locale/aboutDialog.dtd" >
|
||||
%aboutDialogDTD;
|
||||
]>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
#endif
|
||||
|
||||
<dialog xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
id="aboutDialog"
|
||||
windowtype="Browser:About"
|
||||
onload="init(event);" onunload="uninit(event);"
|
||||
#ifdef XP_MACOSX
|
||||
buttons="extra2"
|
||||
align="end"
|
||||
#else
|
||||
title="&aboutDialog.title;"
|
||||
buttons="accept,extra2"
|
||||
#endif
|
||||
creditslabel="©right;"
|
||||
aboutlabel="&aboutLink;">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/aboutDialog.js"/>
|
||||
|
||||
<deck id="modes" flex="1">
|
||||
<vbox flex="1" id="clientBox">
|
||||
<!-- XXXben - this is a hack to deal with our strange and confusing
|
||||
non-decimal version numbering. We display the human-readable
|
||||
version here - hard coded for JUST this release. We will
|
||||
remove this line and replace with the #expand one for 1.0 -->
|
||||
|
||||
#expand <label id="version" value="&aboutVersion; __MOZ_APP_VERSION__"/>
|
||||
|
||||
<description id="copyright">©rightText;</description>
|
||||
<vbox id="detailsBox" align="center" flex="1">
|
||||
<spacer flex="1"/>
|
||||
<textbox id="userAgent" multiline="true" readonly="true" cols="60"/>
|
||||
</vbox>
|
||||
</vbox>
|
||||
<vbox flex="1" id="creditsBox">
|
||||
<iframe id="creditsIframe" src="chrome://browser/content/credits.xhtml" flex="1"/>
|
||||
</vbox>
|
||||
</deck>
|
||||
<separator class="groove" id="groove"/>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
#include browserMountPoints.inc
|
||||
#endif
|
||||
|
||||
</dialog>
|
||||
|
||||
@@ -1,135 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Netscape
|
||||
# Communications Corporation. Portions created by Netscape are
|
||||
# Copyright (C) 1998-2000 Netscape Communications Corporation. All
|
||||
# Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<!DOCTYPE overlay [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
|
||||
%brandDTD;
|
||||
<!ENTITY % baseMenuOverlayDTD SYSTEM "chrome://browser/locale/baseMenuOverlay.dtd">
|
||||
%baseMenuOverlayDTD;
|
||||
]>
|
||||
<overlay id="baseMenuOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/utilityOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://help/content/contextHelp.js"/>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
<!-- nsMenuBarX moves menu_preferences to the Application Menu -->
|
||||
<menupopup id="menu_ToolsPopup">
|
||||
<menuitem id="menu_preferences" oncommand="openPreferences();"/>
|
||||
</menupopup>
|
||||
<!-- Mac window menu -->
|
||||
#include ../../../toolkit/content/macWindowMenu.inc
|
||||
#endif
|
||||
|
||||
#ifdef XP_WIN
|
||||
<menu id="helpMenu"
|
||||
label="&helpMenuWin.label;"
|
||||
accesskey="&helpMenuWin.accesskey;">
|
||||
#else
|
||||
<menu id="helpMenu"
|
||||
label="&helpMenu.label;"
|
||||
accesskey="&helpMenu.accesskey;">
|
||||
#endif
|
||||
<menupopup id="menu_HelpPopup" onpopupshowing="buildHelpMenu();">
|
||||
<menuitem oncommand="openHelp('firefox-help', 'chrome://browser/locale/help/help.rdf');"
|
||||
#ifdef XP_MACOSX
|
||||
label="&helpContentsMac.label;"
|
||||
key="key_openHelpMacFrontend"/>
|
||||
#else
|
||||
label="&helpContents.label;"
|
||||
accesskey="&helpContents.accesskey;"
|
||||
key="key_openHelp"/>
|
||||
#endif
|
||||
# Show IE Users menu item on Windows only
|
||||
#ifdef XP_WIN
|
||||
<menuitem label="&helpForIEUsers.label;"
|
||||
accesskey="&helpForIEUsers.accesskey;"
|
||||
oncommand="openHelp('ieusers', 'chrome://browser/locale/help/help.rdf');"/>
|
||||
#endif
|
||||
<menuitem accesskey="&helpReleaseNotes.accesskey;"
|
||||
label="&helpReleaseNotes.label;"
|
||||
oncommand="openReleaseNotes(event)"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
<menuseparator id="aboutSeparator"/>
|
||||
<menuitem id="checkForUpdates"
|
||||
accesskey="&updateCmd.accesskey;"
|
||||
label="&updateCmd.label;"
|
||||
class="menuitem-iconic"
|
||||
oncommand="checkForUpdates();"/>
|
||||
#ifndef XP_MACOSX
|
||||
<menuseparator/>
|
||||
#endif
|
||||
<menuitem id="aboutName"
|
||||
accesskey="&aboutCmd.accesskey;"
|
||||
label="&aboutCmd.label;"
|
||||
#ifdef XP_MACOSX
|
||||
hidden="true"
|
||||
#endif
|
||||
oncommand="openAboutDialog();"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<keyset id="baseMenuKeyset">
|
||||
<key id="key_openHelp"
|
||||
oncommand="openHelp('firefox-help', 'chrome://browser/locale/help/help.rdf');"
|
||||
# VK_HELP doesn't work on other platforms yet
|
||||
#ifdef XP_MACOSX
|
||||
keycode="&openHelpMac.commandkey;"/>
|
||||
# On mac, we support both the help key and Cmd+?
|
||||
# ...Map Cmd+Shift+/, show Cmd+?
|
||||
# (that's for en-US, it might be different for other keyboard layouts)
|
||||
<key id="key_openHelpMac"
|
||||
oncommand="openHelp('firefox-help', 'chrome://browser/locale/help/help.rdf');"
|
||||
key="&openHelpMac2.commandkey;"
|
||||
modifiers="&openHelpMac2.modifiers;"/>
|
||||
<key id="key_openHelpMacFrontend"
|
||||
key="&openHelpMac2.frontendCommandkey;"
|
||||
modifiers="&openHelpMac2.frontendModifiers;"/>
|
||||
#else
|
||||
keycode="&openHelp.commandkey;"/>
|
||||
#endif
|
||||
</keyset>
|
||||
|
||||
<stringbundleset id="stringbundleset">
|
||||
<stringbundle id="bundle_browser" src="chrome://browser/locale/browser.properties"/>
|
||||
<stringbundle id="bundle_browser_region" src="chrome://browser-region/locale/region.properties"/>
|
||||
</stringbundleset>
|
||||
</overlay>
|
||||
@@ -1,237 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<popup id="contentAreaContextMenu"
|
||||
onpopupshowing="if (event.target != this) return true; gContextMenu = new nsContextMenu( this ); return gContextMenu.shouldDisplay;"
|
||||
onpopuphiding="if (event.target == this) gContextMenu = null;">
|
||||
<menuitem id="context-openlink"
|
||||
label="&openLinkCmd.label;"
|
||||
accesskey="&openLinkCmd.accesskey;"
|
||||
oncommand="gContextMenu.openLink();"/>
|
||||
<menuitem id="context-openlinkintab"
|
||||
label="&openLinkCmdInTab.label;"
|
||||
accesskey="&openLinkCmdInTab.accesskey;"
|
||||
oncommand="gContextMenu.openLinkInTab();"/>
|
||||
<menuseparator id="context-sep-open"/>
|
||||
<menuitem id="context-bookmarklink"
|
||||
label="&bookmarkLinkCmd.label;"
|
||||
accesskey="&bookmarkLinkCmd.accesskey;"
|
||||
oncommand="BookmarksUtils.addBookmark(gContextMenu.linkURL,
|
||||
gContextMenu.linkText());"/>
|
||||
<menuitem id="context-savelink"
|
||||
label="&saveLinkCmd.label;"
|
||||
accesskey="&saveLinkCmd.accesskey;"
|
||||
oncommand="gContextMenu.saveLink();"/>
|
||||
<menuitem id="context-sendlink"
|
||||
label="&sendLinkCmd.label;"
|
||||
accesskey="&sendLinkCmd.accesskey;"
|
||||
oncommand="gContextMenu.sendLink();"/>
|
||||
<menuitem id="context-copyemail"
|
||||
label="©EmailCmd.label;"
|
||||
accesskey="©EmailCmd.accesskey;"
|
||||
oncommand="gContextMenu.copyEmail();"/>
|
||||
<menuitem id="context-copylink"
|
||||
label="©LinkCmd.label;"
|
||||
accesskey="©LinkCmd.accesskey;"
|
||||
command="cmd_copyLink"/>
|
||||
<menuseparator id="context-sep-copylink"/>
|
||||
<menuitem id="context-viewimage"
|
||||
label="&viewImageCmd.label;"
|
||||
accesskey="&viewImageCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewImage(event);"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
#ifdef CONTEXT_COPY_IMAGE_CONTENTS
|
||||
<menuitem id="context-copyimage-contents"
|
||||
label="©ImageContentsCmd.label;"
|
||||
accesskey="©ImageContentsCmd.accesskey;"
|
||||
command="cmd_copyImageContents"/>
|
||||
#endif
|
||||
<menuitem id="context-copyimage"
|
||||
label="©ImageCmd.label;"
|
||||
accesskey="©ImageCmd.accesskey;"
|
||||
command="cmd_copyImageLocation"/>
|
||||
<menuseparator id="context-sep-copyimage"/>
|
||||
<menuitem id="context-saveimage"
|
||||
label="&saveImageCmd.label;"
|
||||
accesskey="&saveImageCmd.accesskey;"
|
||||
oncommand="gContextMenu.saveImage();"/>
|
||||
<menuitem id="context-sendimage"
|
||||
label="&sendImageCmd.label;"
|
||||
accesskey="&sendImageCmd.accesskey;"
|
||||
oncommand="gContextMenu.sendImage();"/>
|
||||
<menuitem id="context-setDesktopBackground"
|
||||
label="&setDesktopBackgroundCmd.label;"
|
||||
accesskey="&setDesktopBackgroundCmd.accesskey;"
|
||||
oncommand="gContextMenu.setDesktopBackground();"/>
|
||||
|
||||
<!--XXXBlake XUL sucks! We need autocheck for menuitems. -->
|
||||
<menuitem id="context-blockimage" class="menuitem-iconic"
|
||||
accesskey="&blockImageCmd.accesskey;"
|
||||
oncommand="gContextMenu.toggleImageBlocking(this.getAttribute('checked') != 'true');"/>
|
||||
<menuitem id="context-back"
|
||||
label="&backCmd.label;"
|
||||
accesskey="&backCmd.accesskey;"
|
||||
command="Browser:Back"/>
|
||||
<menuitem id="context-forward"
|
||||
label="&forwardCmd.label;"
|
||||
accesskey="&forwardCmd.accesskey;"
|
||||
command="Browser:Forward"/>
|
||||
<menuitem id="context-reload"
|
||||
label="&reloadCmd.label;"
|
||||
accesskey="&reloadCmd.accesskey;"
|
||||
command="Browser:Reload"/>
|
||||
<menuitem id="context-stop"
|
||||
label="&stopCmd.label;"
|
||||
accesskey="&stopCmd.accesskey;"
|
||||
command="Browser:Stop"/>
|
||||
<menuseparator id="context-sep-stop"/>
|
||||
<menuitem id="context-bookmarkpage"
|
||||
label="&bookmarkPageCmd.label;"
|
||||
accesskey="&bookmarkPageCmd.accesskey;"
|
||||
oncommand="addBookmarkAs(document.getElementById('content'));"/>
|
||||
<menuitem id="context-savepage"
|
||||
label="&savePageCmd.label;"
|
||||
accesskey="&savePageCmd.accesskey;"
|
||||
oncommand="saveDocument(window.content.document);"/>
|
||||
<menuitem id="context-sendpage"
|
||||
label="&sendPageCmd.label;"
|
||||
accesskey="&sendPageCmd.accesskey;"
|
||||
command="Browser:SendLink"/>
|
||||
<menuseparator id="context-sep-viewbgimage"/>
|
||||
<menuitem id="context-viewbgimage"
|
||||
label="&viewBGImageCmd.label;"
|
||||
accesskey="&viewBGImageCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewBGImage(event);"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
<menuitem id="context-undo"
|
||||
label="&undoCmd.label;"
|
||||
accesskey="&undoCmd.accesskey;"
|
||||
command="cmd_undo"/>
|
||||
<menuseparator id="context-sep-undo"/>
|
||||
<menuitem id="context-cut"
|
||||
label="&cutCmd.label;"
|
||||
accesskey="&cutCmd.accesskey;"
|
||||
command="cmd_cut"/>
|
||||
<menuitem id="context-copy"
|
||||
label="©Cmd.label;"
|
||||
accesskey="©Cmd.accesskey;"
|
||||
command="cmd_copy"/>
|
||||
<menuitem id="context-paste"
|
||||
label="&pasteCmd.label;"
|
||||
accesskey="&pasteCmd.accesskey;"
|
||||
command="cmd_paste"/>
|
||||
<menuitem id="context-delete"
|
||||
label="&deleteCmd.label;"
|
||||
accesskey="&deleteCmd.accesskey;"
|
||||
command="cmd_delete"/>
|
||||
<menuseparator id="context-sep-paste"/>
|
||||
<menuitem id="context-selectall"
|
||||
label="&selectAllCmd.label;"
|
||||
accesskey="&selectAllCmd.accesskey;"
|
||||
command="cmd_selectAll"/>
|
||||
<menuseparator id="context-sep-selectall"/>
|
||||
<menuitem id="context-keywordfield"
|
||||
label="&keywordfield.label;"
|
||||
accesskey="&keywordfield.accesskey;"
|
||||
oncommand="AddKeywordForSearchField();"/>
|
||||
<menuitem id="context-searchselect"
|
||||
accesskey="&search.accesskey;"
|
||||
oncommand="OpenSearch('internet', gContextMenu.searchSelected(), true);"/>
|
||||
<menuseparator id="frame-sep"/>
|
||||
<menu id="frame" label="&thisFrameMenu.label;" accesskey="&thisFrameMenu.accesskey;">
|
||||
<menupopup>
|
||||
<menuitem label="&showOnlyThisFrameCmd.label;"
|
||||
accesskey="&showOnlyThisFrameCmd.accesskey;"
|
||||
oncommand="gContextMenu.showOnlyThisFrame();"/>
|
||||
<menuitem label="&openFrameCmd.label;"
|
||||
accesskey="&openFrameCmd.accesskey;"
|
||||
oncommand="gContextMenu.openFrame();"/>
|
||||
<menuitem label="&openFrameCmdInTab.label;"
|
||||
accesskey="&openFrameCmdInTab.accesskey;"
|
||||
oncommand="gContextMenu.openFrameInTab();"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&reloadFrameCmd.label;"
|
||||
accesskey="&reloadFrameCmd.accesskey;"
|
||||
oncommand="gContextMenu.reloadFrame();"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&bookmarkFrameCmd.label;"
|
||||
accesskey="&bookmarkFrameCmd.accesskey;"
|
||||
oncommand="gContextMenu.addBookmarkForFrame();"/>
|
||||
<menuitem label="&saveFrameCmd.label;"
|
||||
accesskey="&saveFrameCmd.accesskey;"
|
||||
oncommand="saveDocument(gContextMenu.target.ownerDocument);"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&viewFrameSourceCmd.label;"
|
||||
accesskey="&viewFrameSourceCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewFrameSource();"/>
|
||||
<menuitem label="&viewFrameInfoCmd.label;"
|
||||
accesskey="&viewFrameInfoCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewFrameInfo();"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuseparator id="context-sep-properties"/>
|
||||
<menuitem id="context-viewpartialsource-selection"
|
||||
label="&viewPartialSourceForSelectionCmd.label;"
|
||||
accesskey="&viewPartialSourceCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewPartialSource('selection');"/>
|
||||
<menuitem id="context-viewpartialsource-mathml"
|
||||
label="&viewPartialSourceForMathMLCmd.label;"
|
||||
accesskey="&viewPartialSourceCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewPartialSource('mathml');"/>
|
||||
<menuitem id="context-viewsource"
|
||||
label="&viewPageSourceCmd.label;"
|
||||
accesskey="&viewPageSourceCmd.accesskey;"
|
||||
oncommand="BrowserViewSourceOfDocument(content.document);"/>
|
||||
<menuitem id="context-viewinfo"
|
||||
label="&viewPageInfoCmd.label;"
|
||||
accesskey="&viewPageInfoCmd.accesskey;"
|
||||
oncommand="gContextMenu.viewInfo();"/>
|
||||
<menuitem id="context-metadata"
|
||||
label="&metadataCmd.label;"
|
||||
accesskey="&metadataCmd.accesskey;"
|
||||
oncommand="gContextMenu.showMetadata();"/>
|
||||
<menuseparator hidden="true" id="context-sep-bidi"/>
|
||||
<menuitem hidden="true" id="context-bidi-text-direction-toggle"
|
||||
label="&bidiSwitchTextDirectionItem.label;"
|
||||
accesskey="&bidiSwitchTextDirectionItem.accesskey;"
|
||||
command="cmd_switchTextDirection"/>
|
||||
<menuitem hidden="true" id="context-bidi-page-direction-toggle"
|
||||
label="&bidiSwitchPageDirectionItem.label;"
|
||||
accesskey="&bidiSwitchPageDirectionItem.accesskey;"
|
||||
oncommand="SwitchDocumentDirection(window.content);"/>
|
||||
</popup>
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
<!DOCTYPE window [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
|
||||
%brandDTD;
|
||||
<!ENTITY % browserDTD SYSTEM "chrome://browser/locale/browser.dtd" >
|
||||
%browserDTD;
|
||||
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
|
||||
%globalDTD;
|
||||
<!ENTITY % globalRegionDTD SYSTEM "chrome://global-region/locale/region.dtd">
|
||||
%globalRegionDTD;
|
||||
<!ENTITY % charsetDTD SYSTEM "chrome://global/locale/charsetOverlay.dtd" >
|
||||
%charsetDTD;
|
||||
<!ENTITY % findBarDTD SYSTEM "chrome://global/locale/findbar.dtd" >
|
||||
%findBarDTD;
|
||||
]>
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
<!-- Total hack. Used by the Go menu to build up items. -->
|
||||
<tree id="hiddenHistoryTree" hidden="true" collapsed="true" datasources="rdf:null"
|
||||
flags="dont-build-content"
|
||||
hidecolumnpicker="true">
|
||||
<template>
|
||||
<rule>
|
||||
<treechildren>
|
||||
<treeitem uri="rdf:*" rdf:type="rdf:http://www.w3.org/1999/02/22-rdf-syntax-ns#type">
|
||||
<treerow>
|
||||
<treecell label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
<treecell label="rdf:http://home.netscape.com/NC-rdf#Date" hidden="true"/>
|
||||
</treerow>
|
||||
</treeitem>
|
||||
</treechildren>
|
||||
</rule>
|
||||
</template>
|
||||
<treecols id="hiddenHistoryTreeCols">
|
||||
<treecol flex="1" id="Name"
|
||||
hideheader="true" primary="true"/>
|
||||
<treecol id="Date" hidden="true" hideheader="true"
|
||||
sort="rdf:http://home.netscape.com/NC-rdf#Date" sortActive="true" sortDirection="descending"/>
|
||||
</treecols>
|
||||
</tree>
|
||||
@@ -1,531 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<menubar id="main-menubar" statusbar="statusbar-display"
|
||||
style="border:0px;padding:0px;margin:0px;-moz-appearance:none">
|
||||
<menu id="file-menu" label="&fileMenu.label;"
|
||||
accesskey="&fileMenu.accesskey;">
|
||||
<menupopup id="menu_FilePopup" onpopupshowing="getContentAreaFrameCount();">
|
||||
<menuitem label="&newNavigatorCmd.label;"
|
||||
accesskey="&newNavigatorCmd.accesskey;"
|
||||
key="key_newNavigator"
|
||||
command="cmd_newNavigator"/>
|
||||
<menuitem command="cmd_newNavigatorTab" key="key_newNavigatorTab"
|
||||
label="&tabCmd.label;" accesskey="&tabCmd.accesskey;"/>
|
||||
<menuitem label="&openLocationCmd.label;" accesskey="&openLocationCmd.accesskey;" key="focusURLBar" command="Browser:OpenLocation"/>
|
||||
<menuitem label="&openFileCmd.label;" accesskey="&openFileCmd.accesskey;" key="openFileKb" command="Browser:OpenFile"/>
|
||||
<menuitem id="menu_closeWindow" hidden="true" command="cmd_closeWindow" key="key_closeWindow" label="&closeWindow.label;"/>
|
||||
<menuitem id="menu_close" label="&closeCmd.label;" key="key_close" accesskey="&closeCmd.accesskey;" command="cmd_close"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&savePageCmd.label;" accesskey="&savePageCmd.accesskey;" key="key_savePage" command="Browser:SavePage"/>
|
||||
<menuitem id="menu_saveFrame" label="&saveFrameCmd.label;" accesskey="&saveFrameCmd.accesskey;" oncommand="saveFrameDocument();" hidden="true"/>
|
||||
<menuitem id="menu_sendLink" label="&sendPageCmd.label;" accesskey="&sendPageCmd.accesskey;" command="Browser:SendLink"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&printSetupCmd.label;" accesskey="&printSetupCmd.accesskey;" command="cmd_pageSetup"/>
|
||||
#ifndef XP_MACOSX
|
||||
<menuitem label="&printPreviewCmd.label;" accesskey="&printPreviewCmd.accesskey;" oncommand="PrintUtils.printPreview(onEnterPrintPreview, onExitPrintPreview);"/>
|
||||
#endif
|
||||
<menuitem label="&printCmd.label;" accesskey="&printCmd.accesskey;" key="printKb" command="cmd_print"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&import.label;" accesskey="&import.accesskey;" oncommand="BrowserImport();"/>
|
||||
#ifndef XP_MACOSX
|
||||
<menuseparator/>
|
||||
#endif
|
||||
<menuitem id="goOfflineMenuitem"
|
||||
label="&goOfflineCmd.label;" accesskey="&goOfflineCmd.accesskey;"
|
||||
type="checkbox" oncommand="BrowserOffline.toggleOfflineStatus();"/>
|
||||
<menuitem id="menu_FileQuitItem"
|
||||
#ifdef XP_WIN
|
||||
label="&quitApplicationCmdWin.label;"
|
||||
accesskey="&quitApplicationCmdWin.accesskey;"
|
||||
#else
|
||||
label="&quitApplicationCmd.label;"
|
||||
accesskey="&quitApplicationCmd.accesskey;"
|
||||
#endif
|
||||
oncommand="goQuitApplication();"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<menu id="edit-menu" label="&editMenu.label;"
|
||||
accesskey="&editMenu.accesskey;">
|
||||
<menupopup id="menu_EditPopup">
|
||||
<menuitem label="&undoCmd.label;"
|
||||
key="key_undo"
|
||||
accesskey="&undoCmd.accesskey;"
|
||||
command="cmd_undo"/>
|
||||
<menuitem label="&redoCmd.label;"
|
||||
key="key_redo"
|
||||
accesskey="&redoCmd.accesskey;"
|
||||
command="cmd_redo"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&cutCmd.label;"
|
||||
key="key_cut"
|
||||
accesskey="&cutCmd.accesskey;"
|
||||
command="cmd_cut"/>
|
||||
<menuitem label="©Cmd.label;"
|
||||
key="key_copy"
|
||||
accesskey="©Cmd.accesskey;"
|
||||
command="cmd_copy"/>
|
||||
<menuitem label="&pasteCmd.label;"
|
||||
key="key_paste"
|
||||
accesskey="&pasteCmd.accesskey;"
|
||||
command="cmd_paste"/>
|
||||
<menuitem label="&deleteCmd.label;"
|
||||
key="key_delete"
|
||||
accesskey="&deleteCmd.accesskey;"
|
||||
command="cmd_delete"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&selectAllCmd.label;"
|
||||
key="key_selectAll"
|
||||
accesskey="&selectAllCmd.accesskey;"
|
||||
command="cmd_selectAll"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&findOnCmd.label;" accesskey="&findOnCmd.accesskey;" key="key_find" command="cmd_find"/>
|
||||
<menuitem label="&findAgainCmd.label;" accesskey="&findAgainCmd.accesskey;" key="key_findAgain" command="cmd_findAgain"/>
|
||||
<menuseparator hidden="true" id="textfieldDirection-separator"/>
|
||||
<menuitem id="textfieldDirection-swap"
|
||||
command="cmd_switchTextDirection"
|
||||
key="key_switchTextDirection"
|
||||
label="&bidiSwitchTextDirectionItem.label;"
|
||||
accesskey="&bidiSwitchTextDirectionItem.accesskey;"
|
||||
hidden="true"/>
|
||||
#ifdef XP_UNIX
|
||||
#ifndef XP_MACOSX
|
||||
<menuseparator/>
|
||||
<menuitem id="menu_preferences"
|
||||
label="&preferencesCmdUnix.label;"
|
||||
accesskey="&preferencesCmdUnix.accesskey;"
|
||||
oncommand="openPreferences();"/>
|
||||
#endif
|
||||
#endif
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<menu id="view-menu" label="&viewMenu.label;" accesskey="&viewMenu.accesskey;">
|
||||
<menupopup id="menu_viewPopup">
|
||||
<menu id="viewToolbarsMenu" label="&viewToolbarsMenu.label;" accesskey="&viewToolbarsMenu.accesskey;"
|
||||
onpopupshowing="onViewToolbarsPopupShowing(event);">
|
||||
<menupopup onpopupshowing="updateToolbarStates(this);">
|
||||
<menuseparator/>
|
||||
<menuitem label="&viewCustomizeToolbar.label;" accesskey="&viewCustomizeToolbar.accesskey;"
|
||||
command="cmd_CustomizeToolbars"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuitem id="toggle_taskbar" label="&taskbarCmd.label;" accesskey="&taskbarCmd.accesskey;" type="checkbox" command="cmd_toggleTaskbar" checked="true" />
|
||||
<menu id="viewSidebarMenuMenu"
|
||||
label="&viewSidebarMenu.label;"
|
||||
accesskey="&viewSidebarMenu.accesskey;">
|
||||
<menupopup id="viewSidebarMenu">
|
||||
<menuitem key="viewBookmarksSidebarKb" observes="viewBookmarksSidebar" accesskey="&bookmarksSidebarCmd.accesskey;"/>
|
||||
<menuitem key="key_gotoHistory" observes="viewHistorySidebar" accesskey="&historySidebarCmd.accesskey;"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuseparator/>
|
||||
<menuitem label="&stopCmd.label;"
|
||||
accesskey="&stopCmd.accesskey;"
|
||||
command="Browser:Stop"
|
||||
#ifdef XP_MACOSX
|
||||
key="key_stop_mac"/>
|
||||
#else
|
||||
key="key_stop"/>
|
||||
#endif
|
||||
<menuitem label="&reloadCmd.label;" accesskey="&reloadCmd.accesskey;" command="Browser:Reload" key="key_reload"/>
|
||||
<menuseparator/>
|
||||
<menu id="viewTextZoomMenu" label="&textSize.label;" accesskey="&textSize.accesskey;">
|
||||
<menupopup>
|
||||
<menuitem key="key_textZoomEnlarge" label="&textZoomEnlargeCmd.label;" accesskey="&textZoomEnlargeCmd.accesskey;"
|
||||
command="cmd_textZoomEnlarge"/>
|
||||
<menuitem key="key_textZoomReduce" label="&textZoomReduceCmd.label;" accesskey="&textZoomReduceCmd.accesskey;"
|
||||
command="cmd_textZoomReduce"/>
|
||||
<menuseparator/>
|
||||
<menuitem key="key_textZoomReset" label="&textZoomResetCmd.label;" accesskey="&textZoomResetCmd.accesskey;"
|
||||
command="cmd_textZoomReset"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu id="pageStyleMenu" label="&pageStyleMenu.label;" accesskey="&pageStyleMenu.accesskey;">
|
||||
<menupopup onpopupshowing="stylesheetFillPopup(this);"
|
||||
oncommand="stylesheetSwitchAll(window.content, event.target.getAttribute('data')); setStyleDisabled(false);">
|
||||
<menuitem label="&pageStyleNoStyle.label;" accesskey="&pageStyleNoStyle.accesskey;"
|
||||
oncommand="setStyleDisabled(true); event.preventBubble();" type="radio"/>
|
||||
<menuitem label="&pageStylePersistentOnly.label;" accesskey="&pageStylePersistentOnly.accesskey;" type="radio" checked="true"/>
|
||||
<menuseparator/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu id="charsetMenu"
|
||||
label="&charsetMenu.label;"
|
||||
accesskey="&charsetMenu.accesskey;"
|
||||
datasources="rdf:charset-menu"
|
||||
ref="NC:BrowserCharsetMenuRoot"
|
||||
oncommand="MultiplexHandler(event)"
|
||||
onpopupshowing="CreateMenu('browser');UpdateMenus(event)"
|
||||
onpopupshown="CreateMenu('more-menu');">
|
||||
<template>
|
||||
<rule rdf:type="http://home.netscape.com/NC-rdf#BookmarkSeparator">
|
||||
<menupopup>
|
||||
<menuseparator uri="..." />
|
||||
</menupopup>
|
||||
</rule>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem type="radio" name="charsetGroup" checked="rdf:http://home.netscape.com/NC-rdf#Checked" uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
|
||||
<menupopup>
|
||||
<menu label="&charsetMenuAutodet.label;" accesskey="&charsetMenuAutodet.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserAutodetMenuRoot">
|
||||
<template>
|
||||
<rule rdf:type="http://home.netscape.com/NC-rdf#CharsetDetector">
|
||||
<menupopup>
|
||||
<menuitem type="radio" name="detectorGroup" checked="rdf:http://home.netscape.com/NC-rdf#Checked" uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuMore.label;" accesskey="&charsetMenuMore.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMoreCharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
<menu label="&charsetMenuMore1.label;" accesskey="&charsetMenuMore1.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMore1CharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuMore2.label;" accesskey="&charsetMenuMore2.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMore2CharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuMore3.label;" accesskey="&charsetMenuMore3.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMore3CharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuMore4.label;" accesskey="&charsetMenuMore4.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMore4CharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuMore5.label;" accesskey="&charsetMenuMore5.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserMore5CharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menu label="&charsetMenuUnicode.label;" accesskey="&charsetMenuUnicode.accesskey;" datasources="rdf:charset-menu" ref="NC:BrowserUnicodeCharsetMenuRoot">
|
||||
<template>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem uri="..." label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
<menupopup>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuseparator />
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuitem name="charsetCustomize" accesskey="&charsetCustomize.accesskey;" label="&charsetCustomize.label;" oncommand="window.openDialog('chrome://global/content/customizeCharset.xul','PrefWindow', 'chrome,modal=yes,resizable=yes', 'browser')"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
<menuseparator/>
|
||||
<menuitem accesskey="&pageSourceCmd.accesskey;" label="&pageSourceCmd.label;" key="key_viewSource" command="View:PageSource"/>
|
||||
#ifndef XP_MACOSX
|
||||
<menuitem accesskey="&fullScreenCmd.accesskey;"
|
||||
label="&fullScreenCmd.label;" key="key_fullScreen"
|
||||
id="fullScreenItem"
|
||||
type="checkbox"
|
||||
command="View:FullScreen"/>
|
||||
#endif
|
||||
<menuseparator hidden="true" id="documentDirection-separator"/>
|
||||
<menuitem hidden="true" id="documentDirection-swap"
|
||||
label="&bidiSwitchPageDirectionItem.label;"
|
||||
accesskey="&bidiSwitchPageDirectionItem.accesskey;"
|
||||
oncommand="SwitchDocumentDirection(window.content)"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<menu id="go-menu" label="&goMenu.label;" accesskey="&goMenu.accesskey;"
|
||||
oncommand="var url = event.target.getAttribute('statustext'); if (url) openUILink(url, event, false, true);"
|
||||
onclick="checkForMiddleClick(this, event);">
|
||||
|
||||
<menupopup id="goPopup" onpopupshowing="updateGoMenu(this);" onpopuphiding="onGoMenuHidden();">
|
||||
<menuitem label="&backCmd.label;"
|
||||
#ifdef XP_MACOSX
|
||||
key="goBackKb2"
|
||||
#else
|
||||
key="goBackKb"
|
||||
#endif
|
||||
oncommand="BrowserBack(event, true)"
|
||||
onclick="checkForMiddleClick(this, event);">
|
||||
<observes element="Browser:Back" attribute="disabled" />
|
||||
</menuitem>
|
||||
<menuitem label="&forwardCmd.label;"
|
||||
#ifdef XP_MACOSX
|
||||
key="goForwardKb2"
|
||||
#else
|
||||
key="goForwardKb"
|
||||
#endif
|
||||
oncommand="BrowserForward(event, true)"
|
||||
onclick="checkForMiddleClick(this, event);">
|
||||
<observes element="Browser:Forward" attribute="disabled" />
|
||||
</menuitem>
|
||||
|
||||
<menuitem label="&goHomeCmd.label;"
|
||||
command="Browser:Home"
|
||||
key="goHome"/>
|
||||
<menuseparator id="startHistorySeparator"/>
|
||||
<menuseparator hidden="true" id="endHistorySeparator"/>
|
||||
<menuitem observes="viewHistorySidebar"
|
||||
key="key_gotoHistory"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<menu id="bookmarks-menu" label="&bookmarksMenu.label;" accesskey="&bookmarksMenu.accesskey;"
|
||||
datasources="rdf:bookmarks rdf:files rdf:localsearch"
|
||||
ref="NC:BookmarksRoot" flags="dont-test-empty"
|
||||
template='bookmarks-template'
|
||||
infer="forward-proxy"
|
||||
onpopupshowing="UpdateBookmarkAllTabsMenuitem(); BookmarksMenu.onShowMenu(event.target)"
|
||||
onpopuphidden="BookmarksMenu.onHideMenu(event.target)"
|
||||
oncommand="BookmarksMenu.loadBookmark(event, event.target, this.database)"
|
||||
onclick="BookmarksMenu.loadBookmarkMiddleClick(event, this.database)"
|
||||
ondraggesture="nsDragAndDrop.startDrag(event, BookmarksMenuDNDObserver)"
|
||||
ondragdrop="nsDragAndDrop.drop(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragenter="nsDragAndDrop.dragEnter(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragover="nsDragAndDrop.dragOver(event, BookmarksMenuDNDObserver); event.preventBubble()">
|
||||
<menupopup id="menu_BookmarksPopup" contextmenu='bookmarks-context-menu'>
|
||||
<menuitem key="addBookmarkAsKb"
|
||||
label="&addCurPageAsCmd.label;"
|
||||
command="Browser:AddBookmarkAs"/>
|
||||
<menuitem id="bookmarkAllCmd"
|
||||
# Accel+Shift+A-F are reserved on GTK2
|
||||
#ifndef MOZ_WIDGET_GTK2
|
||||
key="bookmarkAllTabsKb"
|
||||
#endif
|
||||
label="&bookmarkAllCmd.label;"
|
||||
command="Browser:BookmarkAllTabs"/>
|
||||
<menuitem key="manBookmarkKb"
|
||||
label="&manBookmarksCmd.label;"
|
||||
oncommand="toOpenWindowByType('bookmarks:manager', 'chrome://browser/content/bookmarks/bookmarksManager.xul');"/>
|
||||
<menuseparator/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
<menu id="tools-menu" label="&toolsMenu.label;" accesskey="&toolsMenu.accesskey;">
|
||||
<menupopup id="menu_ToolsPopup"
|
||||
#ifdef XP_WIN
|
||||
onpopupshowing="MailIntegration.updateUnreadCount();"
|
||||
#endif
|
||||
>
|
||||
<menuitem label="&search.label;" accesskey="&search.accesskey;"
|
||||
key="key_search" command="Tools:Search"/>
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
<menuseparator/>
|
||||
<menuitem label="&mailButton.readMail.label;"
|
||||
accesskey="&mailButton.readMail.accesskey;"
|
||||
command="Browser:ReadMail"/>
|
||||
<menuitem label="&mailButton.newMessage.label;"
|
||||
accesskey="&mailButton.newMessage.accesskey;"
|
||||
key="key_newMessage" command="Browser:NewMessage"/>
|
||||
|
||||
#endif
|
||||
<menuseparator/>
|
||||
<menuitem label="&downloads.label;" accesskey="&downloads.accesskey;"
|
||||
# all platforms except Unix, because Ctrl+J is used for web search there
|
||||
#ifndef XP_UNIX
|
||||
key="key_openDownloads"
|
||||
#endif
|
||||
#ifdef XP_MACOSX
|
||||
key="key_openDownloads"
|
||||
#endif
|
||||
command="Tools:Downloads"/>
|
||||
<menuitem label="&extensions.label;" accesskey="&extensions.accesskey;"
|
||||
command="Tools:Extensions"/>
|
||||
<menuitem label="&themes.label;" accesskey="&themes.accesskey;"
|
||||
command="Tools:Themes"/>
|
||||
<menuseparator id="devToolsSeparator"/>
|
||||
<menuitem id="javascriptConsole"
|
||||
label="&javaScriptConsoleCmd.label;" accesskey="&javaScriptConsoleCmd.accesskey;"
|
||||
oncommand="toJavaScriptConsole();"/>
|
||||
#ifdef XP_WIN
|
||||
<menuitem accesskey="&pageInfoCmd.accesskey;" label="&pageInfoCmd.label;"
|
||||
command="View:PageInfo"/>
|
||||
#else
|
||||
<menuitem accesskey="&pageInfoCmd.accesskey;" label="&pageInfoCmd.label;"
|
||||
key="key_viewInfo" command="View:PageInfo"/>
|
||||
#endif
|
||||
<menuseparator id="sanitizeSeparator"/>
|
||||
<menuitem id="sanitizeItem"
|
||||
accesskey="&clearPrivateDataCmd.accesskey;"
|
||||
label="&clearPrivateDataCmd.label;"
|
||||
key="key_sanitize" command="Tools:Sanitize"/>
|
||||
#ifndef XP_UNIX
|
||||
<menuseparator id="prefSep"/>
|
||||
<menuitem id="menu_preferences"
|
||||
label="&preferencesCmd.label;"
|
||||
accesskey="&preferencesCmd.accesskey;"
|
||||
oncommand="openPreferences();"/>
|
||||
#endif
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
<menu id="windowMenu" />
|
||||
#endif
|
||||
<menu id="helpMenu" />
|
||||
</menubar>
|
||||
|
||||
|
||||
<template id='bookmarks-template' xmlns:nc="http://home.netscape.com/NC-rdf#">
|
||||
<rule parent="hbox" rdf:type="http://home.netscape.com/NC-rdf#BookmarkSeparator">
|
||||
<toolbarseparator uri="rdf:*"
|
||||
rdf:type="rdf:http://www.w3.org/1999/02/22-rdf-syntax-ns#type"/>
|
||||
</rule>
|
||||
<rule parent="hbox" rdf:type="http://home.netscape.com/NC-rdf#Livemark">
|
||||
<toolbarbutton type="menu" class="bookmark-item" uri="rdf:*" editable="true"
|
||||
rdf:type="http://home.netscape.com/NC-rdf#Folder"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"
|
||||
livemark="true"
|
||||
chromedir="&locale.dir;">
|
||||
#ifdef XP_MACOSX
|
||||
<menupopup/>
|
||||
#else
|
||||
<menupopup contextmenu="bookmarks-context-menu"/>
|
||||
#endif
|
||||
</toolbarbutton>
|
||||
</rule>
|
||||
<rule parent="hbox" iscontainer="true">
|
||||
<toolbarbutton type="menu" class="bookmark-item" uri="rdf:*" editable="true"
|
||||
rdf:type="http://home.netscape.com/NC-rdf#Folder"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name">
|
||||
#ifdef XP_MACOSX
|
||||
<menupopup/>
|
||||
#else
|
||||
<menupopup contextmenu="bookmarks-context-menu"/>
|
||||
#endif
|
||||
</toolbarbutton>
|
||||
</rule>
|
||||
<rule parent="hbox">
|
||||
<toolbarbutton class="bookmark-item" uri="rdf:*" editable="true"
|
||||
status="rdf:http://home.netscape.com/WEB-rdf#status"
|
||||
rdf:type="http://home.netscape.com/NC-rdf#Bookmark"
|
||||
image="rdf:http://home.netscape.com/NC-rdf#Icon"
|
||||
statustext="rdf:http://home.netscape.com/NC-rdf#URL"
|
||||
tooltip="btTooltip"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</rule>
|
||||
<rule rdf:type="http://home.netscape.com/NC-rdf#BookmarkSeparator">
|
||||
<menupopup>
|
||||
<menuseparator uri="rdf:*" />
|
||||
</menupopup>
|
||||
</rule>
|
||||
<rule rdf:type="http://home.netscape.com/NC-rdf#Livemark">
|
||||
<menupopup>
|
||||
<menu class="menu-iconic bookmark-item" uri="rdf:*"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"
|
||||
type="rdf:http://www.w3.org/1999/02/22-rdf-syntax-ns#type"
|
||||
livemark="true">
|
||||
#ifdef XP_MACOSX
|
||||
<menupopup/>
|
||||
#else
|
||||
<menupopup contextmenu="bookmarks-context-menu"/>
|
||||
#endif
|
||||
</menu>
|
||||
</menupopup>
|
||||
</rule>
|
||||
<rule iscontainer="true">
|
||||
<menupopup>
|
||||
<menu class="menu-iconic bookmark-item" uri="rdf:*"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"
|
||||
type="rdf:http://www.w3.org/1999/02/22-rdf-syntax-ns#type">
|
||||
#ifdef XP_MACOSX
|
||||
<menupopup/>
|
||||
#else
|
||||
<menupopup contextmenu="bookmarks-context-menu"/>
|
||||
#endif
|
||||
</menu>
|
||||
</menupopup>
|
||||
</rule>
|
||||
<rule>
|
||||
<menupopup>
|
||||
<menuitem class="menuitem-iconic bookmark-item" uri="rdf:*"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"
|
||||
image="rdf:http://home.netscape.com/NC-rdf#Icon"
|
||||
status="rdf:http://home.netscape.com/WEB-rdf#status"
|
||||
statustext="rdf:http://home.netscape.com/NC-rdf#URL"/>
|
||||
</menupopup>
|
||||
</rule>
|
||||
</template>
|
||||
@@ -1,343 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@bengoodger.com> (v2.0)
|
||||
# Blake Ross <blakeross@telocity.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
#ifdef XP_UNIX
|
||||
#ifndef XP_MACOSX
|
||||
#define XP_GNOME 1
|
||||
#endif
|
||||
#endif
|
||||
|
||||
<stringbundleset id="stringbundleset">
|
||||
<stringbundle id="bundle_brand" src="chrome://branding/locale/brand.properties"/>
|
||||
<stringbundle id="bundle_shell" src="chrome://browser/locale/shellservice.properties"/>
|
||||
<stringbundle id="bundle_findBar" src="chrome://global/locale/findbar.properties"/>
|
||||
<stringbundle id="bundle_preferences" src="chrome://browser/locale/preferences/preferences.properties"/>
|
||||
</stringbundleset>
|
||||
|
||||
<commandset id="globalEditCommandSet"
|
||||
commandupdater="true"
|
||||
events="focus"
|
||||
oncommandupdate="goUpdateGlobalEditMenuItems()"/>
|
||||
<commandset id="selectEditCommandSet"
|
||||
commandupdater="true"
|
||||
events="select"
|
||||
oncommandupdate="goUpdateSelectEditMenuItems()"/>
|
||||
<commandset id="undoEditCommandSet"
|
||||
commandupdater="true"
|
||||
events="undo"
|
||||
oncommandupdate="goUpdateUndoEditMenuItems()"/>
|
||||
<commandset id="pasteCommandSet"
|
||||
commandupdater="true"
|
||||
events="clipboard"
|
||||
oncommandupdate="goUpdatePasteMenuItems()"/>
|
||||
|
||||
<commandset id="mainCommandSet">
|
||||
<command id="cmd_newNavigator" oncommand="OpenBrowserWindow()"/>
|
||||
<command id="cmd_bm_open" oncommand="goDoCommand('cmd_bm_open');"/>
|
||||
<command id="cmd_bm_openinnewwindow" oncommand="goDoCommand('cmd_bm_openinnewwindow');"/>
|
||||
<command id="cmd_bm_openinnewtab" oncommand="goDoCommand('cmd_bm_openinnewtab');"/>
|
||||
<command id="cmd_bm_openfolder" oncommand="goDoCommand('cmd_bm_openfolder');"/>
|
||||
<command id="cmd_bm_managefolder" oncommand="goDoCommand('cmd_bm_managefolder');"/>
|
||||
<command id="cmd_bm_newfolder" oncommand="goDoCommand('cmd_bm_newfolder');"/>
|
||||
<command id="cmd_bm_newbookmark" oncommand="goDoCommand('cmd_bm_newbookmark');"/>
|
||||
<command id="cmd_bm_newseparator" oncommand="goDoCommand('cmd_bm_newseparator');"/>
|
||||
<command id="cmd_bm_properties" oncommand="goDoCommand('cmd_bm_properties');"/>
|
||||
<command id="cmd_bm_refreshlivemark" oncommand="goDoCommand('cmd_bm_refreshlivemark');"/>
|
||||
<command id="cmd_bm_rename" oncommand="goDoCommand('cmd_bm_rename');"/>
|
||||
<command id="cmd_bm_moveBookmark" oncommand="goDoCommand('cmd_bm_moveBookmark');"/>
|
||||
<command id="cmd_bm_sortbyname" oncommand="goDoCommand('cmd_bm_sortbyname');"/>
|
||||
|
||||
<command id="cmd_handleBackspace" oncommand="BrowserHandleBackspace();" />
|
||||
|
||||
<command id="cmd_newNavigatorTab" oncommand="BrowserOpenTab();"/>
|
||||
<command id="Browser:OpenFile" oncommand="BrowserOpenFileWindow();"/>
|
||||
<command id="Browser:SavePage" oncommand="saveDocument(window.content.document);"/>
|
||||
|
||||
<command id="Browser:SendLink" oncommand="MailIntegration.sendLinkForContent();"/>
|
||||
<command id="Browser:NewMessage" oncommand="MailIntegration.sendMessage('', '');"/>
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
<command id="Browser:ReadMail" oncommand="MailIntegration.readMail();" label="&mailButton.readMail.label;"/>
|
||||
<command id="Browser:ReadNews" oncommand="MailIntegration.readNews();"/>
|
||||
#endif
|
||||
|
||||
<command id="cmd_pageSetup" oncommand="PrintUtils.showPageSetup();"/>
|
||||
<command id="cmd_print" oncommand="PrintUtils.print();"/>
|
||||
<command id="cmd_close" oncommand="BrowserCloseTabOrWindow()"/>
|
||||
<command id="cmd_closeWindow" oncommand="BrowserTryToCloseWindow()"/>
|
||||
<command id="cmd_toggleTaskbar" oncommand="goToggleToolbar('status-bar','toggle_taskbar');"/>
|
||||
<command id="cmd_CustomizeToolbars" oncommand="BrowserCustomizeToolbar()"/>
|
||||
|
||||
<command id="cmd_copyLink"
|
||||
oncommand="goDoCommand('cmd_copyLink')"
|
||||
disabled="false"/>
|
||||
<command id="cmd_copyImageLocation"
|
||||
oncommand="goDoCommand('cmd_copyImageLocation')"
|
||||
disabled="false"/>
|
||||
<command id="cmd_copyImageContents"
|
||||
oncommand="goDoCommand('cmd_copyImageContents')"
|
||||
disabled="false"/>
|
||||
<command id="cmd_undo"
|
||||
oncommand="goDoCommand('cmd_undo')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_redo"
|
||||
oncommand="goDoCommand('cmd_redo')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_cut"
|
||||
oncommand="goDoCommand('cmd_cut')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_copy"
|
||||
oncommand="goDoCommand('cmd_copy')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_paste"
|
||||
oncommand="goDoCommand('cmd_paste')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_delete"
|
||||
oncommand="goDoCommand('cmd_delete')"
|
||||
valueDefault="&deleteCmd.label;"
|
||||
disabled="true"/>
|
||||
<command id="cmd_selectAll"
|
||||
oncommand="goDoCommand('cmd_selectAll')"
|
||||
disabled="true"/>
|
||||
<command id="cmd_switchTextDirection"
|
||||
oncommand="goDoCommand('cmd_switchTextDirection');"
|
||||
disabled="true"/>
|
||||
|
||||
<command id="View:PageSource" oncommand="BrowserViewSourceOfDocument(content.document);"/>
|
||||
<command id="View:PageInfo" oncommand="BrowserPageInfo();"/>
|
||||
<command id="View:FullScreen" oncommand="BrowserFullScreen();"/>
|
||||
<command id="cmd_find" oncommand="onFindCmd();"/>
|
||||
<command id="cmd_findAgain" oncommand="onFindAgainCmd();"/>
|
||||
<command id="cmd_findPrevious" oncommand="onFindPreviousCmd();"/>
|
||||
<command id="Browser:AddBookmarkAs" oncommand="addBookmarkAs(document.getElementById('content'), false);"/>
|
||||
<command id="Browser:BookmarkAllTabs" oncommand="addBookmarkAs(document.getElementById('content'), true);"/>
|
||||
<command id="Browser:Home" oncommand="BrowserHome();"/>
|
||||
<command id="Browser:Back" oncommand="BrowserBack();" disabled="true"/>
|
||||
<command id="Browser:Forward" oncommand="BrowserForward();" disabled="true"/>
|
||||
<command id="Browser:Stop" oncommand="BrowserStop();" disabled="true"/>
|
||||
<command id="Browser:Reload" oncommand="if (event.shiftKey) BrowserReloadSkipCache(); else BrowserReload()" disabled="true"/>
|
||||
<command id="Browser:ReloadSkipCache" oncommand="BrowserReloadSkipCache()" disabled="true"/>
|
||||
<command id="cmd_textZoomReduce" oncommand="ZoomManager.prototype.getInstance().reduce();"/>
|
||||
<command id="cmd_textZoomEnlarge" oncommand="ZoomManager.prototype.getInstance().enlarge();"/>
|
||||
<command id="cmd_textZoomReset" oncommand="ZoomManager.prototype.getInstance().reset();"/>
|
||||
<command id="Browser:OpenLocation" oncommand="openLocation();"/>
|
||||
|
||||
<command id="Tools:Search" oncommand="WebSearch();"/>
|
||||
<command id="Tools:Downloads" oncommand="toOpenWindowByType('Download:Manager',
|
||||
'chrome://mozapps/content/downloads/downloads.xul',
|
||||
'chrome,dialog=no,resizable');"/>
|
||||
<command id="Tools:Extensions" oncommand="BrowserOpenExtensions('extensions');"/>
|
||||
<command id="Tools:Themes" oncommand="BrowserOpenExtensions('themes');"/>
|
||||
<command id="Tools:Sanitize" oncommand="gBrowserGlue.sanitize(window || null);"/>
|
||||
</commandset>
|
||||
|
||||
<broadcasterset id="mainBroadcasterSet">
|
||||
<broadcaster id="viewBookmarksSidebar" autoCheck="false" label="&bookmarksButton.label;"
|
||||
type="checkbox" group="sidebar" sidebarurl="chrome://browser/content/bookmarks/bookmarksPanel.xul"
|
||||
oncommand="toggleSidebar('viewBookmarksSidebar');"/>
|
||||
|
||||
<broadcaster id="viewHistorySidebar" autoCheck="false" label="&historyButton.label;"
|
||||
type="checkbox" group="sidebar" sidebarurl="chrome://browser/content/history/history-panel.xul"
|
||||
oncommand="toggleSidebar('viewHistorySidebar');"/>
|
||||
|
||||
<broadcaster id="viewWebPanelsSidebar" autoCheck="false"
|
||||
type="checkbox" group="sidebar" sidebarurl="chrome://browser/content/web-panels.xul"
|
||||
oncommand="toggleSidebar('viewWebPanelsSidebar');"/>
|
||||
|
||||
<!-- popup blocking menu items -->
|
||||
<broadcaster id="blockedPopupAllowSite"
|
||||
accesskey="&allowPopups.accesskey;"
|
||||
oncommand="gPopupBlockerObserver.toggleAllowPopupsForSite(event);"/>
|
||||
<broadcaster id="blockedPopupEditSettings"
|
||||
#ifdef XP_WIN
|
||||
label="&editPopupSettings.label;"
|
||||
#else
|
||||
label="&editPopupSettingsUnix.label;"
|
||||
#endif
|
||||
accesskey="&editPopupSettings.accesskey;"
|
||||
oncommand="gPopupBlockerObserver.editPopupSettings();"/>
|
||||
<broadcaster id="blockedPopupDontShowMessage"
|
||||
accesskey="&dontShowMessage.accesskey;"
|
||||
type="checkbox"
|
||||
oncommand="gPopupBlockerObserver.dontShowMessage();"/>
|
||||
<broadcaster id="blockedPopupsSeparator"/>
|
||||
|
||||
</broadcasterset>
|
||||
|
||||
<keyset id="mainKeyset">
|
||||
<key id="key_newNavigator"
|
||||
key="&newNavigatorCmd.key;"
|
||||
command="cmd_newNavigator"
|
||||
modifiers="accel"/>
|
||||
<key id="key_newNavigatorTab" key="&tabCmd.commandkey;" modifiers="accel" command="cmd_newNavigatorTab"/>
|
||||
<key id="focusURLBar" key="&openCmd.commandkey;" command="Browser:OpenLocation"
|
||||
modifiers="accel"/>
|
||||
#ifndef XP_MACOSX
|
||||
<key id="focusURLBar2" key="&urlbar.accesskey;" command="Browser:OpenLocation"
|
||||
modifiers="alt"/>
|
||||
#endif
|
||||
|
||||
#
|
||||
# Search Command Key Logic works like this:
|
||||
#
|
||||
# Unix: Ctrl+K (cross platform binding)
|
||||
# Ctrl+J (in case of emacs Ctrl-K conflict)
|
||||
# Mac: Ctrl+K (cross platform binding)
|
||||
# Win: Ctrl+K (cross platform binding)
|
||||
# Ctrl+E (IE compat)
|
||||
#
|
||||
# We support Ctrl+K on all platforms now and advertise it in the menu since it is
|
||||
# our standard - it is a "safe" choice since it is near no harmful keys like "W" as
|
||||
# "E" is. People mourning the loss of Ctrl+K for emacs compat can switch their GTK
|
||||
# system setting to use emacs emulation, and we should respect it. Focus-Search-Box
|
||||
# is a fundamental keybinding and we are maintaining a XP binding so that it is easy
|
||||
# for people to switch to Linux.
|
||||
#
|
||||
# Do *not* tamper with these values without talking to ben@mozilla.org
|
||||
#
|
||||
<key id="key_search" key="&searchFocus.commandkey;" command="Tools:Search" modifiers="accel"/>
|
||||
#ifdef XP_WIN
|
||||
<key id="key_search2" key="&searchFocus.commandkey2;" command="Tools:Search" modifiers="accel"/>
|
||||
#endif
|
||||
#ifdef XP_GNOME
|
||||
<key id="key_search2" key="&searchFocusUnix.commandkey;" command="Tools:Search" modifiers="accel"/>
|
||||
<key id="key_openDownloads" key="&downloadsUnix.commandkey;" command="Tools:Downloads" modifiers="accel"/>
|
||||
#else
|
||||
<key id="key_openDownloads" key="&downloads.commandkey;" command="Tools:Downloads" modifiers="accel"/>
|
||||
#endif
|
||||
<key id="openFileKb" key="&openFileCmd.commandkey;" command="Browser:OpenFile" modifiers="accel"/>
|
||||
<key id="key_savePage" key="&savePageCmd.commandkey;" command="Browser:SavePage" modifiers="accel"/>
|
||||
<key id="printKb" key="&printCmd.commandkey;" command="cmd_print" modifiers="accel"/>
|
||||
<key id="key_close" key="&closeCmd.key;" command="cmd_close" modifiers="accel"/>
|
||||
<key id="key_closeWindow" key="&closeCmd.key;" command="cmd_closeWindow" modifiers="accel,shift"/>
|
||||
<key id="key_undo"
|
||||
key="&undoCmd.key;"
|
||||
modifiers="accel"/>
|
||||
#ifdef XP_UNIX
|
||||
<key id="key_redo" key="&undoCmd.key;" modifiers="accel,shift"/>
|
||||
#else
|
||||
<key id="key_redo" key="&redoCmd.key;" modifiers="accel"/>
|
||||
#endif
|
||||
<key id="key_cut"
|
||||
key="&cutCmd.key;"
|
||||
modifiers="accel"/>
|
||||
<key id="key_copy"
|
||||
key="©Cmd.key;"
|
||||
modifiers="accel"/>
|
||||
<key id="key_paste"
|
||||
key="&pasteCmd.key;"
|
||||
modifiers="accel"/>
|
||||
<key id="key_delete" keycode="VK_DELETE" command="cmd_delete"/>
|
||||
<key id="key_selectAll" key="&selectAllCmd.key;" modifiers="accel"/>
|
||||
|
||||
<key keycode="VK_BACK" command="cmd_handleBackspace"/>
|
||||
<key keycode="VK_BACK" command="Browser:Forward" 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"/>
|
||||
#else
|
||||
<key id="goBackKb" keycode="VK_LEFT" command="Browser:Back" modifiers="accel" />
|
||||
<key id="goForwardKb" keycode="VK_RIGHT" command="Browser:Forward" modifiers="accel" />
|
||||
#endif
|
||||
#ifdef XP_UNIX
|
||||
<key id="goBackKb2" key="&goBackCmd.commandKey;" command="Browser:Back" modifiers="accel"/>
|
||||
<key id="goForwardKb2" key="&goForwardCmd.commandKey;" command="Browser:Forward" modifiers="accel"/>
|
||||
#endif
|
||||
<key id="goHome" keycode="VK_HOME" command="Browser:Home" modifiers="alt"/>
|
||||
<key keycode="VK_F5" command="Browser:Reload"/>
|
||||
#ifndef XP_MACOSX
|
||||
<key keycode="VK_F5" command="Browser:ReloadSkipCache" modifiers="accel"/>
|
||||
<key id="key_fullScreen" keycode="VK_F11" command="View:FullScreen"/>
|
||||
#endif
|
||||
<key key="&reloadCmd.commandkey;" command="Browser:Reload" modifiers="accel" id="key_reload"/>
|
||||
<key key="&reloadCmd.commandkey;" command="Browser:ReloadSkipCache" modifiers="accel,shift"/>
|
||||
<key id="key_viewSource" key="&pageSourceCmd.commandkey;" command="View:PageSource" modifiers="accel"/>
|
||||
#ifndef XP_WIN
|
||||
<key id="key_viewInfo" key="&pageInfoCmd.commandkey;" command="View:PageInfo" modifiers="accel"/>
|
||||
#endif
|
||||
<key id="key_find" key="&findOnCmd.commandkey;" command="cmd_find" modifiers="accel"/>
|
||||
<key id="key_findAgain" key="&findAgainCmd.commandkey;" command="cmd_findAgain" modifiers="accel"/>
|
||||
<key id="key_findPrevious" key="&findAgainCmd.commandkey;" command="cmd_findPrevious" modifiers="accel,shift"/>
|
||||
<key keycode="&findAgainCmd.commandkey2;" command="cmd_findAgain"/>
|
||||
<key keycode="&findAgainCmd.commandkey2;" command="cmd_findPrevious" modifiers="shift"/>
|
||||
|
||||
<key id="addBookmarkAsKb" key="&addCurPageAsCmd.commandkey;" command="Browser:AddBookmarkAs" modifiers="accel"/>
|
||||
# Accel+Shift+A-F are reserved on GTK2
|
||||
#ifndef MOZ_WIDGET_GTK2
|
||||
<key id="bookmarkAllTabsKb" key="&addCurPageAsCmd.commandkey;" command="Browser:BookmarkAllTabs" modifiers="accel,shift"/>
|
||||
#endif
|
||||
<key id="viewBookmarksSidebarKb" key="&bookmarksSidebarCmd.commandkey;" command="viewBookmarksSidebar" modifiers="accel"/>
|
||||
#ifdef XP_WIN
|
||||
# Cmd+I is conventially mapped to Info on MacOS X, thus it should not be
|
||||
# overridden for other purposes there.
|
||||
<key id="viewBookmarksSidebarWinKb" key="&bookmarksSidebarWinCmd.commandkey;" command="viewBookmarksSidebar" modifiers="accel"/>
|
||||
#endif
|
||||
|
||||
# don't use |command="Browser:Stop"|, ESC is being used to freeze animated gifs,
|
||||
# even if the stop button and menuitem are disabled (see Bug 284140)
|
||||
<key id="key_stop" keycode="VK_ESCAPE" oncommand="BrowserStop();"/>
|
||||
#ifdef XP_MACOSX
|
||||
<key id="key_stop_mac" modifiers="accel" key="&stopCmd.macCommandKey;" oncommand="BrowserStop();"/>
|
||||
<key id="key_gotoHistory" key="&historySidebarCmd.commandKey;" command="viewHistorySidebar" modifiers="accel,shift"/>
|
||||
#else
|
||||
<key id="key_gotoHistory" key="&historySidebarCmd.commandKey;" command="viewHistorySidebar" modifiers="accel"/>
|
||||
#endif
|
||||
|
||||
<key id="key_newMessage"
|
||||
key="&sendMessage.commandkey;"
|
||||
command="Browser:NewMessage"
|
||||
#ifdef XP_MACOSX
|
||||
modifiers="accel,shift"/>
|
||||
#else
|
||||
modifiers="accel"/>
|
||||
#endif
|
||||
<key id="key_textZoomReduce" key="&textZoomReduceCmd.commandkey;" command="cmd_textZoomReduce" modifiers="accel"/>
|
||||
<key id="key_textZoomEnlarge" key="&textZoomEnlargeCmd.commandkey;" command="cmd_textZoomEnlarge" modifiers="accel"/>
|
||||
<key key="&textZoomEnlargeCmd.commandkey2;" command="cmd_textZoomEnlarge" modifiers="accel"/>
|
||||
<key id="key_textZoomReset" key="&textZoomResetCmd.commandkey;" command="cmd_textZoomReset" modifiers="accel"/>
|
||||
|
||||
<key id="key_switchTextDirection" key="&bidiSwitchTextDirectionItem.commandkey;" command="cmd_switchTextDirection" modifiers="accel,shift" />
|
||||
|
||||
<key id="key_sanitize" command="Tools:Sanitize" keycode="VK_DELETE" modifiers="accel,shift"/>
|
||||
</keyset>
|
||||
|
||||
# Used by baseMenuOverlay
|
||||
#ifdef XP_MACOSX
|
||||
<commandset id="baseMenuCommandSet" />
|
||||
#endif
|
||||
<keyset id="baseMenuKeyset" />
|
||||
@@ -1,15 +0,0 @@
|
||||
searchbar {
|
||||
-moz-binding: url("chrome://browser/content/search.xml#searchbar");
|
||||
}
|
||||
|
||||
/* ::::: print preview toolbar ::::: */
|
||||
|
||||
toolbar[printpreview="true"] {
|
||||
-moz-binding: url("chrome://global/content/printPreviewBindings.xml#printpreviewtoolbar");
|
||||
}
|
||||
|
||||
#noPreviewAvailable
|
||||
{
|
||||
background-color: white !important;
|
||||
font-size: 12px !important;
|
||||
}
|
||||
@@ -1,473 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# -*- Mode: HTML -*-
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-2000
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Blake Ross <blake@cs.stanford.edu>
|
||||
# David Hyatt <hyatt@mozilla.org>
|
||||
# Joe Hewitt <hewitt@netscape.com>
|
||||
# Pierre Chanial <chanial@noos.fr>
|
||||
# Dean Tessman <dean_tessman@hotmail.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://browser/skin/" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://browser/content/browser.css" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://global/skin/findBar.css" type="text/css"?>
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/baseMenuOverlay.xul"?>
|
||||
|
||||
# All DTD information is stored in a separate file so that it can be shared by
|
||||
# hiddenWindow.xul.
|
||||
#include browser-doctype.inc
|
||||
|
||||
<window id="main-window"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
onload="BrowserStartup()" onunload="BrowserShutdown()" onclose="return WindowIsClosing();"
|
||||
contenttitlesetting="true"
|
||||
title="&mainWindow.title;"
|
||||
titlemodifier="&mainWindow.title;"
|
||||
titlemenuseparator="&mainWindow.titlemodifiermenuseparator;"
|
||||
windowtype="navigator:browser"
|
||||
screenX="4" screenY="4"
|
||||
persist="screenX screenY width height sizemode">
|
||||
|
||||
# All JS files which are not content (only) dependent that browser.xul
|
||||
# wishes to include *must* go into the global-scripts.inc file
|
||||
# so that they can be shared by macBrowserOverlay.xul.
|
||||
#include global-scripts.inc
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/contentAreaUtils.js"/>
|
||||
|
||||
# All sets except for popupsets (commands, keys, stringbundles and broadcasters) *must* go into the
|
||||
# browser-sets.inc file for sharing with hiddenWindow.xul.
|
||||
#include browser-sets.inc
|
||||
|
||||
<popupset id="mainPopupSet">
|
||||
<popup id="backMenu"
|
||||
position="after_start"
|
||||
onpopupshowing="return BrowserBackMenu(event);"
|
||||
oncommand="gotoHistoryIndex(event);"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
<popup id="forwardMenu"
|
||||
position="after_start"
|
||||
onpopupshowing="return BrowserForwardMenu(event);"
|
||||
oncommand="gotoHistoryIndex(event);"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
<tooltip id="aHTMLTooltip" onpopupshowing="return FillInHTMLTooltip(document.tooltipNode);"/>
|
||||
|
||||
<popup type="autocomplete" id="PopupAutoComplete"/>
|
||||
|
||||
<popup id="toolbar-context-menu"
|
||||
onpopupshowing="updateToolbarStates(this); onViewToolbarsPopupShowing(event);">
|
||||
<menuseparator/>
|
||||
<menuitem command="cmd_CustomizeToolbars"
|
||||
label="&viewCustomizeToolbar.label;"
|
||||
accesskey="&viewCustomizeToolbar.accesskey;"/>
|
||||
</popup>
|
||||
|
||||
<popup id="blockedPopupOptions"
|
||||
onpopupshowing="gPopupBlockerObserver.fillPopupList(event);">
|
||||
<menuitem observes="blockedPopupAllowSite"/>
|
||||
<menuitem observes="blockedPopupEditSettings"/>
|
||||
<menuitem observes="blockedPopupDontShowMessage"/>
|
||||
<menuseparator observes="blockedPopupsSeparator"/>
|
||||
</popup>
|
||||
|
||||
#include browser-context.inc
|
||||
|
||||
</popupset>
|
||||
|
||||
# The hacky hidden tree used by the Go menu to build items.
|
||||
#include browser-gotreehack.inc
|
||||
|
||||
<!-- bookmarks context menu -->
|
||||
<popupset>
|
||||
<menupopup id="bookmarks-context-menu"
|
||||
onpopupshowing="return BookmarksMenu.createContextMenu(event);"
|
||||
onpopuphidden ="BookmarksMenu.destroyContextMenu(event);"/>
|
||||
</popupset>
|
||||
|
||||
<!-- bookmarks toolbar tooltip -->
|
||||
<tooltip id="btTooltip" noautohide="true"
|
||||
onpopupshowing="return BookmarksToolbar.fillInBTTooltip(document.tooltipNode)">
|
||||
<vbox id="btTooltipTextBox" flex="1">
|
||||
<label id="btTitleText" />
|
||||
<label id="btUrlText" />
|
||||
</vbox>
|
||||
</tooltip>
|
||||
|
||||
<toolbox id="navigator-toolbox" class="toolbox-top" mode="icons">
|
||||
<!-- Menu -->
|
||||
<toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
|
||||
#ifdef XP_MACOSX
|
||||
defaultset="menubar-items"
|
||||
#else
|
||||
defaultset="menubar-items,spring,throbber-box"
|
||||
#endif
|
||||
mode="icons" context="toolbar-context-menu">
|
||||
<toolbaritem id="menubar-items" align="center">
|
||||
# The entire main menubar is placed into browser-menubar.inc, so that it can be shared by
|
||||
# hiddenWindow.xul.
|
||||
#include browser-menubar.inc
|
||||
</toolbaritem>
|
||||
</toolbar>
|
||||
|
||||
<toolbarpalette id="BrowserToolbarPalette">
|
||||
<toolbarbutton id="back-button" type="menu-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
chromedir="&locale.dir;"
|
||||
label="&backCmd.label;"
|
||||
oncommand="BrowserBack(event)"
|
||||
onclick="checkForMiddleClick(this, event);"
|
||||
context="backMenu"
|
||||
tooltiptext="&backButton.tooltip;">
|
||||
<observes element="Browser:Back" attribute="disabled"/>
|
||||
<menupopup context=""
|
||||
onpopupshowing="BrowserBackMenu(event);"
|
||||
oncommand="gotoHistoryIndex(event); event.preventBubble();"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
</toolbarbutton>
|
||||
|
||||
<toolbarbutton id="forward-button" type="menu-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
chromedir="&locale.dir;"
|
||||
label="&forwardCmd.label;"
|
||||
oncommand="BrowserForward(event)"
|
||||
onclick="checkForMiddleClick(this, event);"
|
||||
context="forwardMenu"
|
||||
tooltiptext="&forwardButton.tooltip;">
|
||||
<observes element="Browser:Forward" attribute="disabled"/>
|
||||
<menupopup context=""
|
||||
onpopupshowing="BrowserForwardMenu(event);"
|
||||
oncommand="gotoHistoryIndex(event); event.preventBubble()"
|
||||
onclick="checkForMiddleClick(this, event);"/>
|
||||
</toolbarbutton>
|
||||
|
||||
<toolbarbutton id="reload-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&reloadCmd.label;"
|
||||
command="Browser:Reload"
|
||||
tooltiptext="&reloadButton.tooltip;"/>
|
||||
|
||||
<toolbarbutton id="stop-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&stopCmd.label;"
|
||||
command="Browser:Stop"
|
||||
tooltiptext="&stopButton.tooltip;"/>
|
||||
|
||||
<toolbarbutton id="home-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&homeButton.label;"
|
||||
ondragover="nsDragAndDrop.dragOver(event, homeButtonObserver);"
|
||||
ondragdrop="nsDragAndDrop.drop(event, homeButtonObserver);"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, homeButtonObserver);"
|
||||
onclick="BrowserHomeClick(event);"/>
|
||||
|
||||
<toolbaritem id="urlbar-container" align="center" flex="1000"
|
||||
title="&locationItem.title;" class="chromeclass-location">
|
||||
<textbox id="urlbar" flex="1"
|
||||
type="autocomplete"
|
||||
autocompletesearch="history"
|
||||
autocompletepopup="PopupAutoComplete"
|
||||
completeselectedindex="true"
|
||||
tabscrolling="true"
|
||||
showcommentcolumn="true"
|
||||
enablehistory="true"
|
||||
oninput="gBrowser.userTypedValue = this.value"
|
||||
ontextentered="return handleURLBarCommand(param);"
|
||||
ontextreverted="return handleURLBarRevert();"
|
||||
onfocus="URLBarFocusHandler(event, this);"
|
||||
onmousedown="URLBarMouseDownHandler(event, this);"
|
||||
onclick="URLBarClickHandler(event, this);">
|
||||
<deck id="page-proxy-deck" onclick="PageProxyClickHandler(event);">
|
||||
<image id="page-proxy-button"
|
||||
ondraggesture="PageProxyDragGesture(event);"
|
||||
tooltiptext="&proxyIcon.tooltip;"/>
|
||||
<image id="page-proxy-favicon"
|
||||
ondraggesture="PageProxyDragGesture(event);"
|
||||
onload="this.parentNode.selectedIndex = 1;
|
||||
event.stopPropagation();
|
||||
event.preventBubble();"
|
||||
onerror="gBrowser.addToMissedIconCache(this.src);
|
||||
this.removeAttribute('src');
|
||||
this.parentNode.selectedIndex = 0;"
|
||||
tooltiptext="&proxyIcon.tooltip;"/>
|
||||
</deck>
|
||||
<hbox>
|
||||
<button type="menu" style="-moz-user-focus: none" class="plain" id="feed-button" chromedir="&locale.dir;">
|
||||
<menupopup onpopupshowing="return FeedHandler.buildFeedList(event);" position="after_end"
|
||||
oncommand="FeedHandler.addLiveBookmark(event.target.getAttribute('feed'));" />
|
||||
</button>
|
||||
<image id="lock-icon" onclick="displaySecurityInfo()"/>
|
||||
</hbox>
|
||||
</textbox>
|
||||
</toolbaritem>
|
||||
|
||||
<toolbaritem id="search-container" title="&searchItem.title;"
|
||||
align="center" class="chromeclass-toolbar-additional">
|
||||
<searchbar id="searchbar"/>
|
||||
</toolbaritem>
|
||||
|
||||
<toolbaritem id="go-container" align="center" class="chromeclass-toolbar-additional">
|
||||
<toolbarbutton id="go-button"
|
||||
chromedir="&locale.dir;"
|
||||
label="&goButton.label;"
|
||||
oncommand="handleURLBarCommand(event);"
|
||||
ondragover="nsDragAndDrop.dragOver(event, goButtonObserver);"
|
||||
ondragdrop="nsDragAndDrop.drop(event, goButtonObserver);"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, goButtonObserver);"
|
||||
tooltiptext="&goButton.tooltip;"/>
|
||||
</toolbaritem>
|
||||
|
||||
<toolbarbutton id="print-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&printButton.label;" command="cmd_print"
|
||||
tooltiptext="&printButton.tooltip;"/>
|
||||
|
||||
<toolbaritem id="throbber-box" title="&throbberItem.title;" align="center" pack="center">
|
||||
<button id="navigator-throbber"
|
||||
oncommand="goClickThrobber('browser.throbber.url', event)"
|
||||
onclick="checkForMiddleClick(this, event);"
|
||||
tooltiptext="&throbber.tooltip;"/>
|
||||
</toolbaritem>
|
||||
|
||||
<toolbaritem id="personal-bookmarks" title="&bookmarksItem.title;" flex="1"
|
||||
class="chromeclass-directories">
|
||||
<stack id="bookmarks-stack" flex="1" style="min-width:0px; width:0px;"
|
||||
onpopupshowing="BookmarksToolbar.setOpenedMenu(event);"
|
||||
onpopuphidden="BookmarksToolbar.unsetOpenedMenu(event);">
|
||||
<hbox id="bookmarks-ptf" class="bookmarks-toolbar-items" contextmenu="bookmarks-context-menu"
|
||||
flex="1" style="min-width:0px; width:0px;padding-left: 3px;"
|
||||
datasources="rdf:bookmarks rdf:files rdf:localsearch"
|
||||
template="bookmarks-template" flags="dont-test-empty"
|
||||
infer="forward-proxy"
|
||||
rdf:type="http://home.netscape.com/NC-rdf#Folder"
|
||||
onpopupshowing="BookmarksMenu.onShowMenu(event.target)"
|
||||
onpopuphidden="BookmarksMenu.onHideMenu(event.target)"
|
||||
oncommand="BookmarksMenu.loadBookmark(event, event.target, this.database)"
|
||||
onclick="BookmarksMenu.loadBookmarkMiddleClick(event, this.database)"
|
||||
ondraggesture="nsDragAndDrop.startDrag(event, BookmarksMenuDNDObserver)"
|
||||
ondragdrop="nsDragAndDrop.drop(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragenter="nsDragAndDrop.dragEnter(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragover="nsDragAndDrop.dragOver(event, BookmarksMenuDNDObserver); event.preventBubble()">
|
||||
</hbox>
|
||||
<hbox class="bookmarks-toolbar-overflow-items" mousethrough="always">
|
||||
<hbox mousethrough="always" id="overflow-padder"/>
|
||||
<toolbarbutton id="bookmarks-chevron" type="menu" class="chevron"
|
||||
chromedir="&locale.dir;"
|
||||
mousethrough="never" collapsed="true"
|
||||
datasources="rdf:bookmarks rdf:files rdf:localsearch"
|
||||
template="bookmarks-template" flags="dont-test-empty"
|
||||
onpopupshowing="BookmarksMenu.onShowMenu(event.target)"
|
||||
onpopuphidden="BookmarksMenu.onHideMenu(event.target)"
|
||||
oncommand="BookmarksMenu.loadBookmark(event, event.target, this.database)"
|
||||
onclick="BookmarksMenu.loadBookmarkMiddleClick(event, this.database)"
|
||||
ondraggesture="nsDragAndDrop.startDrag(event, BookmarksMenuDNDObserver)"
|
||||
ondragdrop="nsDragAndDrop.drop(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragenter="nsDragAndDrop.dragEnter(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, BookmarksMenuDNDObserver); event.preventBubble()"
|
||||
ondragover="nsDragAndDrop.dragOver(event, BookmarksMenuDNDObserver); event.preventBubble()">
|
||||
<menupopup onpopupshowing="if (event.target == this) BookmarksToolbar.updateOverflowMenu(this);"
|
||||
#ifndef XP_MACOSX
|
||||
contextmenu="bookmarks-context-menu"
|
||||
#endif
|
||||
/>
|
||||
</toolbarbutton>
|
||||
</hbox>
|
||||
<toolbarbutton class="bookmark-item bookmarks-toolbar-customize" mousethrough="never"
|
||||
label="&bookmarksToolbarItem.label;"/>
|
||||
</stack>
|
||||
</toolbaritem>
|
||||
|
||||
<toolbarbutton id="downloads-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
observes="Tools:Downloads"
|
||||
ondragdrop="nsDragAndDrop.drop(event, DownloadsButtonDNDObserver); event.preventBubble()"
|
||||
ondragover="nsDragAndDrop.dragOver(event, DownloadsButtonDNDObserver); event.preventBubble()"
|
||||
ondragenter="nsDragAndDrop.dragEnter(event, DownloadsButtonDNDObserver); event.preventBubble()"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, DownloadsButtonDNDObserver); event.preventBubble()"
|
||||
label="&downloads.label;"
|
||||
tooltiptext="&downloads.tooltip;"/>
|
||||
|
||||
<toolbarbutton id="history-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
observes="viewHistorySidebar"
|
||||
tooltiptext="&historyButton.tooltip;"/>
|
||||
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
<toolbarbutton id="mail-button" type="menu" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&mailButton.label;" orient="vertical"
|
||||
onmouseover="MailIntegration.updateUnreadCount();"
|
||||
tooltiptext="&mailButton.tooltip;">
|
||||
<menupopup tooltiptext="">
|
||||
<menuitem accesskey="&mailButton.readMail.accesskey;"
|
||||
command="Browser:ReadMail"/>
|
||||
<menuitem label="&mailButton.newMessage.label;"
|
||||
accesskey="&mailButton.newMessage.accesskey;"
|
||||
command="Browser:NewMessage"/>
|
||||
</menupopup>
|
||||
</toolbarbutton>
|
||||
#endif
|
||||
|
||||
<toolbarbutton id="bookmarks-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
observes="viewBookmarksSidebar"
|
||||
tooltiptext="&bookmarksButton.tooltip;"
|
||||
ondragover="nsDragAndDrop.dragOver(event, bookmarksButtonObserver);"
|
||||
ondragdrop="nsDragAndDrop.drop(event, bookmarksButtonObserver);"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, bookmarksButtonObserver);"/>
|
||||
|
||||
<toolbarbutton id="new-tab-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&tabCmd.label;"
|
||||
command="cmd_newNavigatorTab"
|
||||
tooltiptext="&newTabButton.tooltip;"
|
||||
ondragover="nsDragAndDrop.dragOver(event, newTabButtonObserver);"
|
||||
ondragdrop="nsDragAndDrop.drop(event, newTabButtonObserver);"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, newTabButtonObserver);"/>
|
||||
|
||||
<toolbarbutton id="new-window-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&newNavigatorCmd.label;"
|
||||
command="key_newNavigator"
|
||||
tooltiptext="&newWindowButton.tooltip;"
|
||||
ondragover="nsDragAndDrop.dragOver(event, newWindowButtonObserver);"
|
||||
ondragdrop="nsDragAndDrop.drop(event, newWindowButtonObserver);"
|
||||
ondragexit="nsDragAndDrop.dragExit(event, newWindowButtonObserver);"/>
|
||||
|
||||
<toolbarbutton id="cut-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&cutCmd.label;"
|
||||
command="cmd_cut"
|
||||
tooltiptext="&cutButton.tooltip;"/>
|
||||
|
||||
<toolbarbutton id="copy-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="©Cmd.label;"
|
||||
command="cmd_copy"
|
||||
tooltiptext="©Button.tooltip;"/>
|
||||
|
||||
<toolbarbutton id="paste-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
label="&pasteCmd.label;"
|
||||
command="cmd_paste"
|
||||
tooltiptext="&pasteButton.tooltip;"/>
|
||||
|
||||
</toolbarpalette>
|
||||
|
||||
<toolbar id="nav-bar" class="toolbar-primary chromeclass-toolbar"
|
||||
toolbarname="&navbarCmd.label;" accesskey="&navbarCmd.accesskey;"
|
||||
fullscreentoolbar="true" mode="icons"
|
||||
customizable="true"
|
||||
#ifdef XP_MACOSX
|
||||
defaultset="back-button,forward-button,reload-button,stop-button,home-button,urlbar-container,go-container,search-container,throbber-box"
|
||||
#else
|
||||
defaultset="back-button,forward-button,reload-button,stop-button,home-button,urlbar-container,go-container,search-container,fullscreenflex,window-controls"
|
||||
#endif
|
||||
context="toolbar-context-menu">
|
||||
#ifndef XP_MACOSX
|
||||
<hbox id="fullscreenflex" flex="1" hidden="true" fullscreencontrol="true"/>
|
||||
<hbox id="window-controls" hidden="true" fullscreencontrol="true">
|
||||
<toolbarbutton id="minimize-button" class="toolbarbutton-1"
|
||||
tooltiptext="&fullScreenMinimize.tooltip;"
|
||||
oncommand="window.minimize();"/>
|
||||
|
||||
<toolbarbutton id="restore-button" class="toolbarbutton-1"
|
||||
tooltiptext="&fullScreenRestore.tooltip;"
|
||||
oncommand="BrowserFullScreen();"/>
|
||||
|
||||
<toolbarbutton id="close-button" class="toolbarbutton-1"
|
||||
tooltiptext="&fullScreenClose.tooltip;"
|
||||
oncommand="BrowserTryToCloseWindow();"/>
|
||||
</hbox>
|
||||
#endif
|
||||
</toolbar>
|
||||
|
||||
<toolbarset id="customToolbars" context="toolbar-context-menu"/>
|
||||
|
||||
<toolbar id="PersonalToolbar" class="chromeclass-directories" iconsize="small"
|
||||
customizable="true" defaultset="personal-bookmarks" mode="icons"
|
||||
toolbarname="&personalbarCmd.label;" accesskey="&personalbarCmd.accesskey;"
|
||||
context="toolbar-context-menu"/>
|
||||
</toolbox>
|
||||
|
||||
<hbox flex="1" id="browser">
|
||||
<vbox id="sidebar-box" hidden="true" class="chromeclass-extrachrome">
|
||||
<sidebarheader align="center">
|
||||
<label id="sidebar-title" persist="value" flex="1" crop="end"/>
|
||||
<image id="sidebar-throbber"/>
|
||||
<toolbarbutton class="tabs-closebutton" tooltiptext="&sidebarCloseButton.tooltip;" oncommand="toggleSidebar();"/>
|
||||
</sidebarheader>
|
||||
<browser id="sidebar" flex="1" autoscroll="false"
|
||||
style="min-width: 150px; width: 200px; max-width: 400px;"/>
|
||||
</vbox>
|
||||
|
||||
<splitter id="sidebar-splitter" class="chromeclass-extrachrome" hidden="true"/>
|
||||
<vbox id="appcontent" flex="1">
|
||||
<tabbrowser id="content" disablehistory="true"
|
||||
flex="1" contenttooltip="aHTMLTooltip"
|
||||
contentcontextmenu="contentAreaContextMenu"
|
||||
onnewtab="BrowserOpenTab();"
|
||||
autocompletepopup="PopupAutoComplete"
|
||||
ondragdrop="nsDragAndDrop.drop(event, contentAreaDNDObserver);"
|
||||
onclick="return contentAreaClick(event, false);"/>
|
||||
</vbox>
|
||||
</hbox>
|
||||
|
||||
#include ../../../toolkit/components/typeaheadfind/content/findBar.inc
|
||||
|
||||
<statusbar class="chromeclass-status" id="status-bar"
|
||||
ondragdrop="nsDragAndDrop.drop(event, contentAreaDNDObserver);">
|
||||
<statusbarpanel id="statusbar-display" flex="1"/>
|
||||
<statusbarpanel class="statusbarpanel-progress" collapsed="true" id="statusbar-progresspanel">
|
||||
<progressmeter class="progressmeter-statusbar" id="statusbar-icon" mode="normal" value="0"/>
|
||||
</statusbarpanel>
|
||||
<statusbarpanel id="security-button" class="statusbarpanel-iconic-text"
|
||||
ondblclick="if (event.button == 0) displaySecurityInfo();"/>
|
||||
<statusbarpanel id="page-report-button" type="menu"
|
||||
class="statusbarpanel-menu-iconic"
|
||||
tooltiptext="&pageReportIcon.tooltip;">
|
||||
<menupopup onpopupshowing="gPopupBlockerObserver.fillPopupList(event);">
|
||||
<menuitem observes="blockedPopupAllowSite"/>
|
||||
<menuitem observes="blockedPopupEditSettings"/>
|
||||
<menuitem observes="blockedPopupDontShowMessage"/>
|
||||
<menuseparator observes="blockedPopupsSeparator"/>
|
||||
</menupopup>
|
||||
</statusbarpanel>
|
||||
#ifdef ALTSS_ICON
|
||||
<statusbarpanel id="page-theme-button" type="menu"
|
||||
class="statusbarpanel-menu-iconic"
|
||||
tooltiptext="&pageStyleIcon.tooltip;">
|
||||
<menupopup onpopupshowing="stylesheetFillPopup(this);"
|
||||
oncommand="stylesheetSwitchAll(window.content, event.target.getAttribute('data')); setStyleDisabled(false);">
|
||||
<menuitem label="&pageStyleNoStyle.label;" accesskey="&pageStyleNoStyle.accesskey;"
|
||||
oncommand="setStyleDisabled(true); event.preventBubble();" type="radio" hidden="true"/>
|
||||
<menuitem label="&pageStylePersistentOnly.label;" accesskey="&pageStylePersistentOnly.accesskey;" type="radio" checked="true"/>
|
||||
<menuseparator/>
|
||||
</menupopup>
|
||||
</statusbarpanel>
|
||||
#endif
|
||||
</statusbar>
|
||||
</window>
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
<stringbundleset id="stringbundleset"/>
|
||||
|
||||
<commandset id="mainCommandSet"/>
|
||||
<commandset id="baseMenuCommandSet"/>
|
||||
|
||||
<broadcasterset id="mainBroadcasterSet"/>
|
||||
|
||||
<keyset id="mainKeyset"/>
|
||||
<keyset id="baseMenuKeyset"/>
|
||||
|
||||
<menubar id="main-menubar"/>
|
||||
|
||||
<template id="bookmarks-template"/>
|
||||
|
||||
<tree id="hiddenHistoryTree"/>
|
||||
@@ -1,2 +0,0 @@
|
||||
# Do NOT localize or otherwise change these values
|
||||
browser.startup.homepage=http://www.mozilla.org/projects/deerpark/
|
||||
@@ -1,370 +0,0 @@
|
||||
<!-- -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Firefox Credits.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Ben Goodger.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2004
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@mozilla.org>
|
||||
# David Baron <dbaron@mozilla.org>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
|
||||
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"
|
||||
[
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
|
||||
%brandDTD;
|
||||
<!ENTITY % creditsDTD SYSTEM "chrome://browser/locale/credits.dtd">
|
||||
%creditsDTD;
|
||||
<!ENTITY % licenseDTD SYSTEM "chrome://global/locale/license.dtd">
|
||||
%licenseDTD;
|
||||
]
|
||||
>
|
||||
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>&brandFullName; Credits</title>
|
||||
|
||||
<style>
|
||||
html {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
* {
|
||||
cursor: default;
|
||||
-moz-user-select: none;
|
||||
}
|
||||
|
||||
#titleBox {
|
||||
position: fixed;
|
||||
left: 0px;
|
||||
top: 0px;
|
||||
right: 0px;
|
||||
bottom: auto;
|
||||
z-index: 999;
|
||||
}
|
||||
|
||||
#footerBox {
|
||||
position: fixed;
|
||||
left: 0px;
|
||||
top: auto;
|
||||
right: 0px;
|
||||
bottom: 0px;
|
||||
z-index: 999;
|
||||
}
|
||||
|
||||
#creditsBox {
|
||||
position: absolute;
|
||||
left: 0px;
|
||||
top: 0px;
|
||||
overflow: hidden;
|
||||
z-index: 1;
|
||||
height: 285px;
|
||||
width: 280px;
|
||||
margin-left: 10px;
|
||||
margin-right: 10px;
|
||||
font-family: Arial, sans-serif;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-weight: bold;
|
||||
font-size: small;
|
||||
text-align: center;
|
||||
margin: 15px 0px 5px 0px;
|
||||
}
|
||||
|
||||
.creditsGroup {
|
||||
margin-bottom: 1px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.footnote {
|
||||
font-size: x-small;
|
||||
text-align: justify;
|
||||
}
|
||||
|
||||
h2.title {
|
||||
margin-top: 200px;
|
||||
margin-bottom: 100px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.motto {
|
||||
margin-top: 2px;
|
||||
font-style: italic;
|
||||
font-size: small;
|
||||
font-weight: normal;
|
||||
padding-left: 2em;
|
||||
}
|
||||
|
||||
#gecko {
|
||||
margin-top: 100px;
|
||||
margin-bottom: 100px;
|
||||
font-size: medium;
|
||||
}
|
||||
|
||||
a {
|
||||
color: blue;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
ul {
|
||||
margin-top: 0px;
|
||||
margin-left: 0px;
|
||||
padding-left: 0px;
|
||||
}
|
||||
|
||||
li {
|
||||
list-style-type: none;
|
||||
}
|
||||
|
||||
.center {
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"></script>
|
||||
<script type="application/x-javascript">
|
||||
<![CDATA[
|
||||
|
||||
var gCreditsInterval = -1;
|
||||
|
||||
function uninit()
|
||||
{
|
||||
if (gCreditsInterval > -1)
|
||||
clearInterval(gCreditsInterval);
|
||||
}
|
||||
|
||||
function init()
|
||||
{
|
||||
var cb = document.getElementById("creditsBox");
|
||||
cb.scrollTop = 0;
|
||||
setTimeout(runCredits, 3000);
|
||||
}
|
||||
|
||||
function runCredits()
|
||||
{
|
||||
gCreditsInterval = setInterval("creditsCallback()", 25);
|
||||
}
|
||||
|
||||
function creditsCallback()
|
||||
{
|
||||
var cb = document.getElementById("creditsBox");
|
||||
var newtop = cb.scrollTop + 1;
|
||||
cb.scrollTop = newtop;
|
||||
if (cb.scrollTop != newtop) {
|
||||
// we're at the bottom
|
||||
clearInterval(gCreditsInterval);
|
||||
setTimeout(function() { cb.scrollTop = 0 }, 3000);
|
||||
}
|
||||
}
|
||||
|
||||
]]>
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();" onunload="uninit();">
|
||||
<div id="titleBox">
|
||||
<img src="chrome://branding/content/aboutCredits.png" />
|
||||
</div>
|
||||
|
||||
<div id="creditsBox">
|
||||
<h2 class="title">&brandFullName;™
|
||||
<div class="motto">&brandMotto;</div>
|
||||
</h2>
|
||||
|
||||
<div class="creditsGroup">
|
||||
<ul>
|
||||
<li>Josh Aas</li>
|
||||
<li>Robert Accettura</li>
|
||||
<li>Christopher Aillon</li>
|
||||
<li>Marc Attinasi</li>
|
||||
<li>Arvid Axelsson</li>
|
||||
<li>Mitchell Baker</li>
|
||||
<li>David Baron</li>
|
||||
<li>Chris Beard</li>
|
||||
<li>Mike Beltzner</li>
|
||||
<li>Uri Bernstein</li>
|
||||
<li>Daniel Burka</li>
|
||||
<li>Andrew Cave</li>
|
||||
<li>Pierre Chanial</li>
|
||||
<li>Bob Clary</li>
|
||||
<li>Chris Cooper</li>
|
||||
<li>Mike Connor</li>
|
||||
<li>Catherine Corre</li>
|
||||
<li>Chris Crews</li>
|
||||
<li>André Dahlqvist</li>
|
||||
<li>Bart Decrem</li>
|
||||
<li>Sébastien Delahaye</li>
|
||||
<li>Stephen Desroches</li>
|
||||
<li>Jeremy Dolan</li>
|
||||
<li>Asa Dotzler</li>
|
||||
<li>Ali Ebrahim</li>
|
||||
<li>Rafael Ebron</li>
|
||||
<li>Brendan Eich</li>
|
||||
<li>Darin Fisher</li>
|
||||
<li>Erik Fornoff</li>
|
||||
<li>Simon Fraser</li>
|
||||
<li>Steven Garrity</li>
|
||||
<li>Kevin Gerich</li>
|
||||
<li>Ben Goodger</li>
|
||||
<li>Jonathan Granrose</li>
|
||||
<li>Jasper Hauser</li>
|
||||
<li>Steven Hellings</li>
|
||||
<li>Joe Hewitt</li>
|
||||
<li>Jon Hicks</li>
|
||||
<li>Ian Hickson</li>
|
||||
<li>Chris Hofmann</li>
|
||||
<li>Stephen Horlander</li>
|
||||
<li>Ed Hume</li>
|
||||
<li>David Hyatt</li>
|
||||
<li>Logan Ingalls</li>
|
||||
<li>David P. James</li>
|
||||
<li>Glen Johnson</li>
|
||||
<li>Blake Kaplan</li>
|
||||
<li>Michael Kaply</li>
|
||||
<li>R.J. Keller</li>
|
||||
<li>John Keiser</li>
|
||||
<li>Jason Kersey</li>
|
||||
<li>Marcia Knous</li>
|
||||
<li>Aaron Leventhal</li>
|
||||
<li>Will Levine</li>
|
||||
<li>Sarah Liberman</li>
|
||||
<li>Scott MacGregor</li>
|
||||
<li>Daniel Matejka</li>
|
||||
<li>Nigel McFarlane</li>
|
||||
<li>Myk Melez</li>
|
||||
<li>Mark Mentovai</li>
|
||||
<li>Steven Michaud</li>
|
||||
<li>Bernd Mielke</li>
|
||||
<li>Simon Montagu</li>
|
||||
<li>Masayuki Nakano</li>
|
||||
<li>Noririty</li>
|
||||
<li>Leaf Nunes</li>
|
||||
<li>Robert O'Callahan</li>
|
||||
<li>Mats Palmgren</li>
|
||||
<li>Simon Paquet</li>
|
||||
<li>Jay Patel</li>
|
||||
<li>Igor Pavlov, 7-Zip</li>
|
||||
<li>Chase Phillips</li>
|
||||
<li>Mike Pinkerton</li>
|
||||
<li>Eric Pollmann</li>
|
||||
<li>Rick Potts</li>
|
||||
<li>Asaf Romano</li>
|
||||
<li>Doron Rosenberg</li>
|
||||
<li>Blake Ross</li>
|
||||
<li>Jesse Ruderman</li>
|
||||
<li>Brian Ryner</li>
|
||||
<li>Andrew Schultz</li>
|
||||
<li>Gavin Sharp</li>
|
||||
<li>Mike Shaver</li>
|
||||
<li>Dave Shea</li>
|
||||
<li>Jungshik Shin</li>
|
||||
<li>Jonas Sicking</li>
|
||||
<li>Benjamin Smedberg</li>
|
||||
<li>Seth Spitzer</li>
|
||||
<li>Alan Starr</li>
|
||||
<li>Johnny Stenback</li>
|
||||
<li>Luke Stone</li>
|
||||
<li>Robert Strong</li>
|
||||
<li>David Tenser</li>
|
||||
<li>Dean Tessman</li>
|
||||
<li>Namachivayam Thirumazhusai</li>
|
||||
<li>Ben Turner</li>
|
||||
<li>Peter Van der Beken</li>
|
||||
<li>Peter van der Woude</li>
|
||||
<li>Jan Varga</li>
|
||||
<li>Daniel Veditz</li>
|
||||
<li>Vladimir Vukicevic</li>
|
||||
<li>Jeff Walden</li>
|
||||
<li>Tracy Walker</li>
|
||||
<li>Martijn Wargers</li>
|
||||
<li>Chris Waterson</li>
|
||||
<li>Steffen Wilberg</li>
|
||||
<li>Boris Zbarsky</li>
|
||||
</ul>
|
||||
|
||||
&credit.translation;
|
||||
</div>
|
||||
|
||||
<!-- organizational supporters -->
|
||||
<div class="creditsGroup">
|
||||
<h3>&credit.thanks;</h3>
|
||||
<ul>
|
||||
<li>silverorange</li>
|
||||
<li>Spark PR</li>
|
||||
<li>MozillaZine Community</li>
|
||||
<li>MozillaZine</li>
|
||||
<li>MozDev</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<p id="gecko" class="center">&credit.poweredByGecko;</p>
|
||||
|
||||
<p class="footnote">
|
||||
&brandFullName;™ &license.part0; copyright ©1998-2006 &license.part1;
|
||||
<a href="" link="about:credits" onclick="visitLink(event);">&license.contrib;</a>,
|
||||
&license.part2;
|
||||
<a href="" link="chrome://global/content/MPL-1.1.html" onclick="visitLink(event);">Mozilla Public License</a>
|
||||
&license.and;
|
||||
<a href="" link="chrome://global/content/NPL-1.1.html" onclick="visitLink(event);">Netscape Public License</a>&license.part3;</p>
|
||||
|
||||
<p class="footnote">
|
||||
Portions of this software are Copyright ©1994 The Regents of the
|
||||
University of California. All Rights Reserved.</p>
|
||||
|
||||
<p class="footnote">
|
||||
This software may contain portions that are Copyright ©1998-2005
|
||||
SupportSoft, Inc. All Rights Reserved.</p>
|
||||
|
||||
<p class="footnote">
|
||||
Mozilla Firefox™ and the Firefox logo are trademarks of the Mozilla
|
||||
Foundation. You are not granted rights or licenses to the trademarks
|
||||
of the Mozilla Foundation or any party, including without limitation the
|
||||
Firefox name or logo.</p>
|
||||
|
||||
<p class="footnote">
|
||||
U.S. GOVERNMENT END USERS. The Software is a “commercial item,”
|
||||
as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of
|
||||
“commercial computer software” and “commercial computer software
|
||||
documentation,” as such terms are used in 48 C.F.R. 12.212 (Sept. 1995).
|
||||
Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through
|
||||
227.7202-4 (June 1995), all U.S. Government End Users acquire the
|
||||
Software with only those rights set forth herein.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="footerBox">
|
||||
<img src="chrome://branding/content/aboutFooter.png" />
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -1,50 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<overlay id="downloadManagerOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<window id="downloadManager">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
</overlay>
|
||||
@@ -1,50 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<overlay id="extensionsManagerOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<window id="extensionsManager">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
</overlay>
|
||||
@@ -1,208 +0,0 @@
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is Feedview for Firefox.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Tom Germeau <tom.germeau@epigoon.com>.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2005
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Ben Goodger <ben@mozilla.org>
|
||||
* Myk Melez <myk@mozilla.org>
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
var FeedView = {
|
||||
/**
|
||||
* Converts a W3C-DTF (subset of ISO 8601) date string to an IETF date string.
|
||||
* @param dateString
|
||||
* A string that may contain a W3C-DTF date string
|
||||
* @returns an IETF date string
|
||||
*/
|
||||
_W3CToIETFDate: function(dateString) {
|
||||
// W3C-DTF is described in this note: http://www.w3.org/TR/NOTE-datetime
|
||||
// IETF is obtained via the Date object's toUTCString() method. The object's
|
||||
// toString() method is insufficient because it spells out timezones on Win32
|
||||
// (f.e. "Pacific Standard Time" instead of "PST"), which Mail doesn't grok.
|
||||
// For info, see http://lxr.mozilla.org/mozilla/source/js/src/jsdate.c#1654.
|
||||
|
||||
const HOURS_TO_MINUTES = 60;
|
||||
const MINUTES_TO_SECONDS = 60;
|
||||
const SECONDS_TO_MILLISECONDS = 1000;
|
||||
const MINUTES_TO_MILLISECONDS = MINUTES_TO_SECONDS * SECONDS_TO_MILLISECONDS;
|
||||
const HOURS_TO_MILLISECONDS = HOURS_TO_MINUTES * MINUTES_TO_MILLISECONDS;
|
||||
|
||||
var parts = dateString.match(/(\d\d\d\d)(-(\d\d))?(-(\d\d))?(T(\d\d):(\d\d)(:(\d\d)(\.(\d+))?)?(Z|([+-])(\d\d):(\d\d))?)?/);
|
||||
|
||||
// Here's an example of a W3C-DTF date string and what .match returns for it.
|
||||
// date: 2003-05-30T11:18:50.345-08:00
|
||||
// date.match returns array values:
|
||||
// 0: 2003-05-30T11:18:50-08:00,
|
||||
// 1: 2003,
|
||||
// 2: -05,
|
||||
// 3: 05,
|
||||
// 4: -30,
|
||||
// 5: 30,
|
||||
// 6: T11:18:50-08:00,
|
||||
// 7: 11,
|
||||
// 8: 18,
|
||||
// 9: :50,
|
||||
// 10: 50,
|
||||
// 11: .345,
|
||||
// 12: 345,
|
||||
// 13: -08:00,
|
||||
// 14: -,
|
||||
// 15: 08,
|
||||
// 16: 00
|
||||
|
||||
// Create a Date object from the date parts. Note that the Date object
|
||||
// apparently can't deal with empty string parameters in lieu of numbers,
|
||||
// so optional values (like hours, minutes, seconds, and milliseconds)
|
||||
// must be forced to be numbers.
|
||||
var date = new Date(parts[1], parts[3]-1, parts[5], parts[7] || 0,
|
||||
parts[8] || 0, parts[10] || 0, parts[12] || 0);
|
||||
|
||||
// We now have a value that the Date object thinks is in the local timezone
|
||||
// but which actually represents the date/time in the remote timezone
|
||||
// (f.e. the value was "10:00 EST", and we have converted it to "10:00 PST"
|
||||
// instead of "07:00 PST"). We need to correct that. To do so, we're going
|
||||
// to add the offset between the remote timezone and UTC (to convert the value
|
||||
// to UTC), then add the offset between UTC and the local timezone (to convert
|
||||
// the value to the local timezone).
|
||||
|
||||
// Ironically, W3C-DTF gives us the offset between UTC and the remote timezone
|
||||
// rather than the other way around, while the getTimezoneOffset() method
|
||||
// of a Date object gives us the offset between the local timezone and UTC
|
||||
// rather than the other way around. Both of these are the additive inverse
|
||||
// (i.e. -x for x) of what we want, so we have to invert them to use them
|
||||
// by multipying by -1
|
||||
// (f.e. if "the offset between UTC and the remote timezone" is -5 hours,
|
||||
// then "the offset between the remote timezone and UTC" is -5*-1 = 5 hours).
|
||||
|
||||
// Note that if the timezone portion of the date/time string is absent
|
||||
// (which violates W3C-DTF, although ISO 8601 allows it), we assume the value
|
||||
// to be in UTC.
|
||||
|
||||
// The offset between the remote timezone and UTC in milliseconds.
|
||||
var remoteToUTCOffset = 0;
|
||||
if (parts[13] && parts[13] != "Z") {
|
||||
var direction = (parts[14] == "+" ? 1 : -1);
|
||||
if (parts[15])
|
||||
remoteToUTCOffset += direction * parts[15] * HOURS_TO_MILLISECONDS;
|
||||
if (parts[16])
|
||||
remoteToUTCOffset += direction * parts[16] * MINUTES_TO_MILLISECONDS;
|
||||
}
|
||||
remoteToUTCOffset = remoteToUTCOffset * -1; // invert it
|
||||
|
||||
// The offset between UTC and the local timezone in milliseconds.
|
||||
var UTCToLocalOffset = date.getTimezoneOffset() * MINUTES_TO_MILLISECONDS;
|
||||
UTCToLocalOffset = UTCToLocalOffset * -1; // invert it
|
||||
|
||||
date.setTime(date.getTime() + remoteToUTCOffset + UTCToLocalOffset);
|
||||
|
||||
return date.toUTCString();
|
||||
},
|
||||
|
||||
/**
|
||||
* Normalizes date strings embedded in the feed into a common format.
|
||||
*/
|
||||
_initializeDates: function() {
|
||||
// Normalize date formatting for all feed entries
|
||||
var divs = document.getElementsByTagName("div");
|
||||
for (var i = 0; i < divs.length; i++) {
|
||||
var d = divs[i].getAttribute("date");
|
||||
dump("*** D = " + d + "\n");
|
||||
if (d) {
|
||||
// If the date looks like it's in W3C-DTF format, convert it into
|
||||
// an IETF standard date string.
|
||||
if (d.search(/^\d\d\d\d/) != -1)
|
||||
d = this._W3CToIETFDate(d);
|
||||
|
||||
d = new Date(d);
|
||||
|
||||
// If the date could be parsed...
|
||||
if (d instanceof Date) {
|
||||
// XXX It would be nicer to say day = "Today" or "Yesterday".
|
||||
var day = d.toGMTString();
|
||||
day = day.substring(0, 11);
|
||||
|
||||
function padZeros(num) {
|
||||
return num < 10 ? "0" + num : num;
|
||||
}
|
||||
divs[i].getElementsByTagName("span")[0].textContent =
|
||||
day + " @ " + padZeros(d.getHours()) + ":" + padZeros(d.getMinutes());
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns the value of a boolean preference
|
||||
* @param name
|
||||
* The name of the preference
|
||||
* @returns The value of the preference
|
||||
*/
|
||||
_getBooleanPref: function(name) {
|
||||
return document.getElementById("data").getAttribute(name) == "true";
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns the value of an integer preference
|
||||
* @param name
|
||||
* The name of the preference
|
||||
* @returns The value of the preference
|
||||
*/
|
||||
_getIntegerPref: function(name) {
|
||||
return parseInt(document.getElementById("data").getAttribute(name));
|
||||
},
|
||||
|
||||
/**
|
||||
* Reload the page after an interval
|
||||
*/
|
||||
reload: function() {
|
||||
location.reload();
|
||||
},
|
||||
|
||||
/**
|
||||
* Initialize the feed view
|
||||
*/
|
||||
init: function() {
|
||||
// Hide the menu if the user chose to have it closed
|
||||
if (!this._getBooleanPref("showmenu"))
|
||||
document.getElementById("menubox").style.display = "none";
|
||||
|
||||
// Normalize the date formats
|
||||
this._initializeDates();
|
||||
|
||||
// Set up the auto-reload timer.
|
||||
// The timer loads every browser.feedview.reloadInterval minutes.
|
||||
// It is disabled if the value of that preference is 0.
|
||||
var reloadInterval = this._getIntegerPref("reloadinterval") || 0;
|
||||
if (reloadInterval > 0)
|
||||
setTimeout("FeedView.reload()", reloadInterval * 60 * 1000);
|
||||
}
|
||||
};
|
||||
@@ -1,222 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- ***** BEGIN LICENSE BLOCK *****
|
||||
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
-
|
||||
- The contents of this file are subject to the Mozilla Public License Version
|
||||
- 1.1 (the "License"); you may not use this file except in compliance with
|
||||
- the License. You may obtain a copy of the License at
|
||||
- http://www.mozilla.org/MPL/
|
||||
-
|
||||
- Software distributed under the License is distributed on an "AS IS" basis,
|
||||
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
- for the specific language governing rights and limitations under the
|
||||
- License.
|
||||
-
|
||||
- The Original Code is Feedview for Firefox.
|
||||
-
|
||||
- The Initial Developer of the Original Code is
|
||||
- Tom Germeau <tom.germeau@epigoon.com>.
|
||||
- Portions created by the Initial Developer are Copyright (C) 2004
|
||||
- the Initial Developer. All Rights Reserved.
|
||||
-
|
||||
- Contributor(s):
|
||||
- Ben Goodger <ben@mozilla.org>
|
||||
-
|
||||
- Alternatively, the contents of this file may be used under the terms of
|
||||
- either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
- in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
- of those above. If you wish to allow use of your version of this file only
|
||||
- under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
- use your version of this file under the terms of the MPL, indicate your
|
||||
- decision by deleting the provisions above and replace them with the notice
|
||||
- and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
- the provisions above, a recipient may use your version of this file under
|
||||
- the terms of any one of the MPL, the GPL or the LGPL.
|
||||
-
|
||||
- ***** END LICENSE BLOCK ***** -->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:date="http://www.jclark.com/xt/java/java.util.Date"
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/" version="1.0"
|
||||
xmlns:atom03="http://purl.org/atom/ns#"
|
||||
xmlns:atom10="http://www.w3.org/2005/Atom"
|
||||
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<xsl:param name="url"/>
|
||||
<xsl:param name="articleCount"/>
|
||||
<xsl:param name="title"/>
|
||||
<xsl:param name="addLiveBookmarkLink"/>
|
||||
<xsl:param name="liveBookmarkInfoURL"/>
|
||||
<xsl:param name="liveBookmarkInfoText"/>
|
||||
<!-- these parameters are read from the Firefox preferences system and are stored
|
||||
as attributes on the <options> element in this page. -->
|
||||
<xsl:param name="showMenu"/>
|
||||
<xsl:param name="reloadInterval"/>
|
||||
|
||||
<xsl:output method="html" media-type="text/html"/>
|
||||
<xsl:template match="/">
|
||||
<html>
|
||||
<head>
|
||||
<title>
|
||||
<xsl:value-of select="$title"/>
|
||||
</title>
|
||||
<link rel="stylesheet" href="chrome://browser/skin/feedview.css"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/feedview.js"/>
|
||||
</head>
|
||||
<body>
|
||||
<!-- Menu box -->
|
||||
<div id="menubox">
|
||||
<span id="number">
|
||||
<xsl:value-of select="$articleCount"/>
|
||||
</span>
|
||||
<br/>
|
||||
<br/>
|
||||
<a href="javascript:void(0);" id="addLiveBookmarkLink">
|
||||
<xsl:attribute name="feed">
|
||||
<xsl:value-of select="$url"/>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="$addLiveBookmarkLink"/>
|
||||
</a>
|
||||
<br/>
|
||||
<br/>
|
||||
<a id="liveBookmarkInfoLink">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:value-of select="$liveBookmarkInfoURL"/>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="$liveBookmarkInfoText"/>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<!-- The options place holder -->
|
||||
<div id="data" style="display: none;">
|
||||
<xsl:attribute name="showmenu">
|
||||
<xsl:value-of select="$showMenu"/>
|
||||
</xsl:attribute>
|
||||
<xsl:attribute name="reloadinterval">
|
||||
<xsl:value-of select="$reloadInterval"/>
|
||||
</xsl:attribute>
|
||||
<xsl:attribute name="url">
|
||||
<xsl:value-of select="$url"/>
|
||||
</xsl:attribute>
|
||||
</div>
|
||||
|
||||
<xsl:apply-templates/>
|
||||
|
||||
<script type="application/x-javascript">
|
||||
// Initialize the view
|
||||
FeedView.init();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
</xsl:template>
|
||||
<!-- RSS RDF Support-->
|
||||
<xsl:template name="a-element">
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:apply-templates select="*[local-name()='link']"/>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="*[local-name()='title']"/>
|
||||
</xsl:element>
|
||||
</xsl:template>
|
||||
<xsl:template match="*[local-name()='channel']">
|
||||
<h1>
|
||||
<xsl:call-template name="a-element"/>
|
||||
</h1>
|
||||
<!-- Following line for RSS .091 -->
|
||||
<div id="articles">
|
||||
<xsl:apply-templates select="*[local-name()='item']"/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
<xsl:template match="*[local-name()='image']"></xsl:template>
|
||||
<xsl:template match="*[local-name()='textinput']"></xsl:template>
|
||||
<xsl:template match="*[local-name()='item']">
|
||||
<div class="article">
|
||||
<xsl:if test="dc:date">
|
||||
<xsl:attribute name="date">
|
||||
<xsl:value-of select="dc:date" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:if test="*[local-name()='pubDate']">
|
||||
<xsl:attribute name="date">
|
||||
<xsl:value-of select="*[local-name()='pubDate']" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<h2><xsl:call-template name="a-element"/></h2>
|
||||
<span class="date"></span>
|
||||
<xsl:value-of select="*[local-name()='description']" />
|
||||
<p></p>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ATOM 0.3 SUPPORT-->
|
||||
<xsl:template match="atom03:feed">
|
||||
<h1>
|
||||
<a href="{atom03:link[substring(@rel, 1, 8)!='service.']/@href}">
|
||||
<xsl:value-of select="atom03:title"/>
|
||||
</a>
|
||||
</h1>
|
||||
<div id="articles">
|
||||
<xsl:apply-templates select="atom03:entry"/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
<xsl:template match="atom03:entry">
|
||||
<div class="article">
|
||||
<xsl:if test="atom03:issued">
|
||||
<xsl:attribute name="date">
|
||||
<xsl:value-of select="atom03:issued"/>
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<a href="{atom03:link[substring(@rel, 1, 8)!='service.']/@href}">
|
||||
<h2><xsl:value-of select="atom03:title"/></h2>
|
||||
</a>
|
||||
<span class="date"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="atom03:content">
|
||||
<xsl:value-of select="atom03:content"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="atom03:summary"/>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
<p/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ATOM 1.0 SUPPORT-->
|
||||
<xsl:template match="atom10:feed">
|
||||
<h1>
|
||||
<a href="{atom10:link[substring(@rel, 1, 8)!='service.']/@href}">
|
||||
<xsl:value-of select="atom10:title"/>
|
||||
</a>
|
||||
</h1>
|
||||
<div id="articles">
|
||||
<xsl:apply-templates select="atom10:entry"/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
<xsl:template match="atom10:entry">
|
||||
<div class="article">
|
||||
<xsl:if test="atom10:updated">
|
||||
<xsl:attribute name="date">
|
||||
<xsl:value-of select="atom10:updated"/>
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<a href="{atom10:link[substring(@rel, 1, 8)!='service.']/@href}">
|
||||
<h2><xsl:value-of select="atom10:title"/></h2>
|
||||
</a>
|
||||
<span class="date"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="atom10:content">
|
||||
<xsl:value-of select="atom10:content"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="atom10:summary"/>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
<p/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
@@ -1,48 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@bengoodger.com> (v2.0)
|
||||
# Blake Ross <blakeross@telocity.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/nsDragAndDrop.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/findBar.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/printUtils.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/utilityOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/bookmarks.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/bookmarksMenu.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/viewZoomOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/browser.js"/>
|
||||
@@ -1,54 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# -*- Mode: HTML -*-
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-2000
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt <hyatt@mozilla.org> (Original Author)
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<window id="main-window"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
#endif
|
||||
@@ -1,50 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<overlay id="jsConsoleOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<window id="JSConsoleWindow">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
</overlay>
|
||||
@@ -1,73 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# -*- Mode: HTML -*-
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-2000
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt <hyatt@mozilla.org> (Original Author)
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
# All DTD information is stored in a separate file so that it can be shared by
|
||||
# hiddenWindow.xul.
|
||||
#include browser-doctype.inc
|
||||
|
||||
<overlay id="hidden-overlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/baseMenuOverlay.xul"?>
|
||||
|
||||
# All JS files which are not content (only) dependent that browser.xul
|
||||
# wishes to include *must* go into the global-scripts.inc file
|
||||
# so that they can be shared by this overlay.
|
||||
#include global-scripts.inc
|
||||
|
||||
<script type="application/x-javascript">
|
||||
addEventListener("load", nonBrowserWindowStartup, false);
|
||||
</script>
|
||||
|
||||
# All sets except for popupsets (commands, keys, stringbundles and broadcasters) *must* go into the
|
||||
# browser-sets.inc file for sharing with hiddenWindow.xul.
|
||||
#include browser-sets.inc
|
||||
|
||||
# The hacky hidden tree used by the Go menu to build items.
|
||||
#include browser-gotreehack.inc
|
||||
|
||||
# The entire main menubar is placed into browser-menubar.inc, so that it can be shared by
|
||||
# hiddenWindow.xul.
|
||||
#include browser-menubar.inc
|
||||
|
||||
</overlay>
|
||||
@@ -1,606 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is this file as it was released on January 3, 2001.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Jonas Sicking.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2000
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Jonas Sicking <sicking@bigfoot.com> (Original Author)
|
||||
# Gervase Markham <gerv@gerv.net>
|
||||
# Heikki Toivonen <heikki@netscape.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
const XLinkNS = "http://www.w3.org/1999/xlink";
|
||||
const XULNS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
|
||||
const XMLNS = "http://www.w3.org/XML/1998/namespace";
|
||||
const XHTMLNS = "http://www.w3.org/1999/xhtml";
|
||||
var gMetadataBundle;
|
||||
var gLangBundle;
|
||||
var gRegionBundle;
|
||||
var nodeView;
|
||||
var htmlMode = false;
|
||||
|
||||
var onLink = false;
|
||||
var onImage = false;
|
||||
var onInsDel = false;
|
||||
var onQuote = false;
|
||||
var onMisc = false;
|
||||
var onTable = false;
|
||||
var onTitle = false;
|
||||
var onLang = false;
|
||||
|
||||
const nsICacheService = Components.interfaces.nsICacheService;
|
||||
const cacheService = Components.classes["@mozilla.org/network/cache-service;1"]
|
||||
.getService(nsICacheService);
|
||||
var httpCacheSession = cacheService.createSession("HTTP", 0, true);
|
||||
httpCacheSession.doomEntriesIfExpired = false;
|
||||
var ftpCacheSession = cacheService.createSession("FTP", 0, true);
|
||||
ftpCacheSession.doomEntriesIfExpired = false;
|
||||
|
||||
|
||||
function onLoad()
|
||||
{
|
||||
gMetadataBundle = document.getElementById("bundle_metadata");
|
||||
gLangBundle = document.getElementById("bundle_languages");
|
||||
gRegionBundle = document.getElementById("bundle_regions");
|
||||
|
||||
showMetadataFor(window.arguments[0]);
|
||||
nodeView = window.arguments[0].ownerDocument.defaultView;
|
||||
}
|
||||
|
||||
function showMetadataFor(elem)
|
||||
{
|
||||
// skip past non-element nodes
|
||||
while (elem && elem.nodeType != Node.ELEMENT_NODE)
|
||||
elem = elem.parentNode;
|
||||
|
||||
if (!elem) {
|
||||
alert(gMetadataBundle.getString("unableToShowProps"));
|
||||
window.close();
|
||||
}
|
||||
|
||||
if (elem.ownerDocument.getElementsByName && !elem.ownerDocument.namespaceURI)
|
||||
htmlMode = true;
|
||||
|
||||
// htmllocalname is "" if it's not an html tag, or the name of the tag if it is.
|
||||
var htmllocalname = "";
|
||||
if (isHTMLElement(elem,"")) {
|
||||
htmllocalname = elem.localName.toLowerCase();
|
||||
}
|
||||
|
||||
// We only look for images once
|
||||
checkForImage(elem, htmllocalname);
|
||||
|
||||
// Walk up the tree, looking for elements of interest.
|
||||
// Each of them could be at a different level in the tree, so they each
|
||||
// need their own boolean to tell us to stop looking.
|
||||
while (elem && elem.nodeType == Node.ELEMENT_NODE) {
|
||||
htmllocalname = "";
|
||||
if (isHTMLElement(elem,"")) {
|
||||
htmllocalname = elem.localName.toLowerCase();
|
||||
}
|
||||
|
||||
if (!onLink) checkForLink(elem, htmllocalname);
|
||||
if (!onInsDel) checkForInsDel(elem, htmllocalname);
|
||||
if (!onQuote) checkForQuote(elem, htmllocalname);
|
||||
if (!onTable) checkForTable(elem, htmllocalname);
|
||||
if (!onTitle) checkForTitle(elem, htmllocalname);
|
||||
if (!onLang) checkForLang(elem, htmllocalname);
|
||||
|
||||
elem = elem.parentNode;
|
||||
}
|
||||
|
||||
// Decide which sections to show
|
||||
var onMisc = onTable || onTitle || onLang;
|
||||
if (!onMisc) hideNode("misc-sec");
|
||||
if (!onLink) hideNode("link-sec");
|
||||
if (!onImage) hideNode("image-sec");
|
||||
if (!onInsDel) hideNode("insdel-sec");
|
||||
if (!onQuote) hideNode("quote-sec");
|
||||
|
||||
// Fix the Misc section visibilities
|
||||
if (onMisc) {
|
||||
if (!onTable) hideNode("misc-tblsummary");
|
||||
if (!onLang) hideNode("misc-lang");
|
||||
if (!onTitle) hideNode("misc-title");
|
||||
}
|
||||
|
||||
// Get rid of the "No properties" message. This is a backstop -
|
||||
// it should really never show, as long as nsContextMenu.js's
|
||||
// checking doesn't get broken.
|
||||
if (onLink || onImage || onInsDel || onQuote || onMisc)
|
||||
hideNode("no-properties")
|
||||
}
|
||||
|
||||
|
||||
function checkForImage(elem, htmllocalname)
|
||||
{
|
||||
var img;
|
||||
var imgType; // "img" = <img>
|
||||
// "object" = <object>
|
||||
// "input" = <input type=image>
|
||||
// "background" = css background (to be added later)
|
||||
var ismap = false;
|
||||
|
||||
if (htmllocalname === "img") {
|
||||
img = elem;
|
||||
imgType = "img";
|
||||
|
||||
} else if (htmllocalname === "object" &&
|
||||
elem.type.substring(0,6) == "image/" &&
|
||||
elem.data) {
|
||||
img = elem;
|
||||
imgType = "object";
|
||||
|
||||
} else if (htmllocalname === "input" &&
|
||||
elem.type.toUpperCase() == "IMAGE") {
|
||||
img = elem;
|
||||
imgType = "input";
|
||||
|
||||
} else if (htmllocalname === "area" || htmllocalname === "a") {
|
||||
|
||||
// Clicked in image map?
|
||||
var map = elem;
|
||||
ismap = true;
|
||||
setAlt(map);
|
||||
|
||||
while (map && map.nodeType == Node.ELEMENT_NODE && !isHTMLElement(map,"map") )
|
||||
map = map.parentNode;
|
||||
|
||||
if (map && map.nodeType == Node.ELEMENT_NODE) {
|
||||
img = getImageForMap(map);
|
||||
var imgLocalName = img && img.localName.toLowerCase();
|
||||
if (imgLocalName == "img" || imgLocalName == "object")
|
||||
imgType = imgLocalName;
|
||||
}
|
||||
}
|
||||
|
||||
if (img) {
|
||||
|
||||
var imgURL = imgType == "object" ? img.data : img.src;
|
||||
setInfo("image-url", imgURL);
|
||||
var size = getSize(imgURL);
|
||||
|
||||
if (size != -1) {
|
||||
var kbSize = size / 1024;
|
||||
kbSize = Math.round(kbSize*100)/100;
|
||||
setInfo("image-filesize", gMetadataBundle.getFormattedString("imageSize", [kbSize, size]));
|
||||
} else {
|
||||
setInfo("image-filesize", gMetadataBundle.getString("imageSizeUnknown"));
|
||||
}
|
||||
if ("width" in img && img.width != "") {
|
||||
setInfo("image-width", gMetadataBundle.getFormattedString("imageWidth", [ img.width ]));
|
||||
setInfo("image-height", gMetadataBundle.getFormattedString("imageHeight", [ img.height ]));
|
||||
}
|
||||
else {
|
||||
setInfo("image-width", "");
|
||||
setInfo("image-height", "");
|
||||
}
|
||||
|
||||
if (imgType == "img") {
|
||||
setInfo("image-desc", getAbsoluteURL(img.longDesc, img));
|
||||
} else {
|
||||
setInfo("image-desc", "");
|
||||
}
|
||||
|
||||
onImage = true;
|
||||
}
|
||||
|
||||
if (!ismap) {
|
||||
if (imgType == "img" || imgType == "input") {
|
||||
setAlt(img);
|
||||
} else {
|
||||
hideNode("image-alt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function checkForLink(elem, htmllocalname)
|
||||
{
|
||||
if ((htmllocalname === "a" && elem.href != "") ||
|
||||
htmllocalname === "area") {
|
||||
|
||||
setInfo("link-lang", convertLanguageCode(elem.getAttribute("hreflang")));
|
||||
setInfo("link-url", elem.href);
|
||||
setInfo("link-type", elem.getAttribute("type"));
|
||||
setInfo("link-rel", elem.getAttribute("rel"));
|
||||
setInfo("link-rev", elem.getAttribute("rev"));
|
||||
|
||||
var target = elem.target;
|
||||
|
||||
switch (target) {
|
||||
case "_top":
|
||||
setInfo("link-target", gMetadataBundle.getString("sameWindowText"));
|
||||
break;
|
||||
case "_parent":
|
||||
setInfo("link-target", gMetadataBundle.getString("parentFrameText"));
|
||||
break;
|
||||
case "_blank":
|
||||
setInfo("link-target", gMetadataBundle.getString("newWindowText"));
|
||||
break;
|
||||
case "":
|
||||
case "_self":
|
||||
if (elem.ownerDocument.defaultView) {
|
||||
if (elem.ownerDocument != elem.ownerDocument.defaultView.content.document)
|
||||
setInfo("link-target", gMetadataBundle.getString("sameFrameText"));
|
||||
else
|
||||
setInfo("link-target", gMetadataBundle.getString("sameWindowText"));
|
||||
} else {
|
||||
hideNode("link-target");
|
||||
}
|
||||
break;
|
||||
default:
|
||||
setInfo("link-target", "\"" + target + "\"");
|
||||
}
|
||||
|
||||
onLink = true;
|
||||
}
|
||||
|
||||
else if (elem.getAttributeNS(XLinkNS,"href") != "") {
|
||||
setInfo("link-url", getAbsoluteURL(elem.getAttributeNS(XLinkNS,"href"),elem));
|
||||
setInfo("link-lang", "");
|
||||
setInfo("link-type", "");
|
||||
setInfo("link-rel", "");
|
||||
setInfo("link-rev", "");
|
||||
|
||||
switch (elem.getAttributeNS(XLinkNS,"show")) {
|
||||
case "embed":
|
||||
setInfo("link-target", gMetadataBundle.getString("embeddedText"));
|
||||
break;
|
||||
case "new":
|
||||
setInfo("link-target", gMetadataBundle.getString("newWindowText"));
|
||||
break;
|
||||
case "":
|
||||
case "replace":
|
||||
if (elem.ownerDocument != elem.ownerDocument.defaultView.content.document)
|
||||
setInfo("link-target", gMetadataBundle.getString("sameFrameText"));
|
||||
else
|
||||
setInfo("link-target", gMetadataBundle.getString("sameWindowText"));
|
||||
break;
|
||||
default:
|
||||
setInfo("link-target", "");
|
||||
break;
|
||||
}
|
||||
|
||||
onLink = true;
|
||||
}
|
||||
}
|
||||
|
||||
function checkForInsDel(elem, htmllocalname)
|
||||
{
|
||||
if ((htmllocalname === "ins" || htmllocalname === "del") &&
|
||||
(elem.cite || elem.dateTime)) {
|
||||
setInfo("insdel-cite", getAbsoluteURL(elem.cite, elem));
|
||||
setInfo("insdel-date", elem.dateTime);
|
||||
onInsDel = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function checkForQuote(elem, htmllocalname)
|
||||
{
|
||||
if ((htmllocalname === "q" || htmllocalname === "blockquote") && elem.cite) {
|
||||
setInfo("quote-cite", getAbsoluteURL(elem.cite, elem));
|
||||
onQuote = true;
|
||||
}
|
||||
}
|
||||
|
||||
function checkForTable(elem, htmllocalname)
|
||||
{
|
||||
if (htmllocalname === "table" && elem.summary) {
|
||||
setInfo("misc-tblsummary", elem.summary);
|
||||
onTable = true;
|
||||
}
|
||||
}
|
||||
|
||||
function checkForLang(elem, htmllocalname)
|
||||
{
|
||||
if ((htmllocalname && elem.lang) || elem.getAttributeNS(XMLNS, "lang")) {
|
||||
var abbr;
|
||||
if (htmllocalname && elem.lang)
|
||||
abbr = elem.lang;
|
||||
else
|
||||
abbr = elem.getAttributeNS(XMLNS, "lang");
|
||||
|
||||
setInfo("misc-lang", convertLanguageCode(abbr));
|
||||
onLang = true;
|
||||
}
|
||||
}
|
||||
|
||||
function checkForTitle(elem, htmllocalname)
|
||||
{
|
||||
if (htmllocalname && elem.title) {
|
||||
setInfo("misc-title", elem.title);
|
||||
onTitle = true;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Set text of node id to value
|
||||
* if value="" the node with specified id is hidden.
|
||||
* Node should be have one of these forms
|
||||
* <xul:label id="id-text" value=""/>
|
||||
* <xul:description id="id-text"/>
|
||||
*/
|
||||
function setInfo(id, value)
|
||||
{
|
||||
if (!value) {
|
||||
hideNode(id);
|
||||
return;
|
||||
}
|
||||
|
||||
var node = document.getElementById(id+"-text");
|
||||
|
||||
if (node.namespaceURI == XULNS && node.localName == "label" ||
|
||||
(node.namespaceURI == XULNS && node.localName == "textbox")) {
|
||||
node.setAttribute("value",value);
|
||||
|
||||
} else if (node.namespaceURI == XULNS && node.localName == "description") {
|
||||
while (node.hasChildNodes())
|
||||
node.removeChild(node.firstChild);
|
||||
node.appendChild(node.ownerDocument.createTextNode(value));
|
||||
}
|
||||
}
|
||||
|
||||
// Hide node with specified id
|
||||
function hideNode(id)
|
||||
{
|
||||
var style = document.getElementById(id).getAttribute("style");
|
||||
document.getElementById(id).setAttribute("style", "display:none;" + style);
|
||||
}
|
||||
|
||||
/*
|
||||
* Find <img> or <object> which uses an imagemap.
|
||||
* If more then one object is found we can't determine which one
|
||||
* was clicked.
|
||||
*
|
||||
* This code has to be changed once bug 1882 is fixed.
|
||||
* Once bug 72527 is fixed this code should use the .images collection.
|
||||
*/
|
||||
function getImageForMap(map)
|
||||
{
|
||||
var mapuri = "#" + map.getAttribute("name");
|
||||
var multipleFound = false;
|
||||
var img;
|
||||
|
||||
var list = getHTMLElements(map.ownerDocument, "img");
|
||||
for (var i=0; i < list.length; i++) {
|
||||
if (list.item(i).getAttribute("usemap") == mapuri) {
|
||||
if (img) {
|
||||
multipleFound = true;
|
||||
break;
|
||||
} else {
|
||||
img = list.item(i);
|
||||
imgType = "img";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
list = getHTMLElements(map.ownerDocument, "object");
|
||||
for (i = 0; i < list.length; i++) {
|
||||
if (list.item(i).getAttribute("usemap") == mapuri) {
|
||||
if (img) {
|
||||
multipleFound = true;
|
||||
break;
|
||||
} else {
|
||||
img = list.item(i);
|
||||
imgType = "object";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (multipleFound)
|
||||
img = null;
|
||||
|
||||
return img;
|
||||
}
|
||||
|
||||
/*
|
||||
* Takes care of XMLBase and <base>
|
||||
* url is the possibly relative url.
|
||||
* node is the node where the url was given (needed for XMLBase)
|
||||
*
|
||||
* This function is called in many places as a workaround for bug 72524
|
||||
* Once bug 72522 is fixed this code should use the Node.baseURI attribute
|
||||
*
|
||||
* for node==null or url=="", empty string is returned
|
||||
*/
|
||||
function getAbsoluteURL(url, node)
|
||||
{
|
||||
if (!url || !node)
|
||||
return "";
|
||||
|
||||
var urlArr = new Array(url);
|
||||
var doc = node.ownerDocument;
|
||||
|
||||
if (node.nodeType == Node.ATTRIBUTE_NODE)
|
||||
node = node.ownerElement;
|
||||
|
||||
while (node && node.nodeType == Node.ELEMENT_NODE) {
|
||||
if (node.getAttributeNS(XMLNS, "base") != "")
|
||||
urlArr.unshift(node.getAttributeNS(XMLNS, "base"));
|
||||
|
||||
node = node.parentNode;
|
||||
}
|
||||
|
||||
// Look for a <base>.
|
||||
var baseTags = getHTMLElements(doc,"base");
|
||||
if (baseTags && baseTags.length) {
|
||||
urlArr.unshift(baseTags[baseTags.length - 1].getAttribute("href"));
|
||||
}
|
||||
|
||||
// resolve everything from bottom up, starting with document location
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
var URL = ioService.newURI(doc.location.href, null, null);
|
||||
for (var i=0; i<urlArr.length; i++) {
|
||||
URL.spec = URL.resolve(urlArr[i]);
|
||||
}
|
||||
|
||||
return URL.spec;
|
||||
}
|
||||
|
||||
function getHTMLElements(node, name)
|
||||
{
|
||||
if (htmlMode)
|
||||
return node.getElementsByTagName(name);
|
||||
return node.getElementsByTagNameNS(XHTMLNS, name);
|
||||
}
|
||||
|
||||
// name should be in lower case
|
||||
function isHTMLElement(node, name)
|
||||
{
|
||||
if (node.nodeType != Node.ELEMENT_NODE)
|
||||
return false;
|
||||
|
||||
if (htmlMode)
|
||||
return !name || node.localName.toLowerCase() == name;
|
||||
|
||||
return (!name || node.localName == name) && node.namespaceURI == XHTMLNS;
|
||||
}
|
||||
|
||||
// This function coded according to the spec at:
|
||||
// http://www.bath.ac.uk/~py8ieh/internet/discussion/metadata.txt
|
||||
function convertLanguageCode(abbr)
|
||||
{
|
||||
if (!abbr) return "";
|
||||
var result;
|
||||
var language = "";
|
||||
var region;
|
||||
var is_region_set = false;
|
||||
var tokens = abbr.split("-");
|
||||
|
||||
if (tokens[0] === "x" || tokens[0] === "i")
|
||||
{
|
||||
// x and i prefixes mean unofficial ones. So we upper-case the first
|
||||
// word and leave the rest.
|
||||
tokens.shift();
|
||||
|
||||
if (tokens[0])
|
||||
{
|
||||
// Upper-case first letter
|
||||
language = tokens[0].substr(0, 1).toUpperCase() + tokens[0].substr(1);
|
||||
tokens.shift();
|
||||
|
||||
if (tokens[0])
|
||||
{
|
||||
// Add on the rest as space-separated strings inside the brackets
|
||||
region = tokens.join(" ");
|
||||
is_region_set = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Otherwise we treat the first as a lang, the second as a region
|
||||
// and the rest as strings.
|
||||
try
|
||||
{
|
||||
language = gLangBundle.getString(tokens[0]);
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
// Language not present in lang bundle
|
||||
language = tokens[0];
|
||||
}
|
||||
|
||||
tokens.shift();
|
||||
|
||||
if (tokens[0])
|
||||
{
|
||||
try
|
||||
{
|
||||
// We don't add it on to the result immediately
|
||||
// because we want to get the spacing right.
|
||||
region = gRegionBundle.getString(tokens[0].toLowerCase());
|
||||
|
||||
tokens.shift();
|
||||
|
||||
if (tokens[0])
|
||||
{
|
||||
// Add on the rest as space-separated strings inside the brackets
|
||||
region += " " + tokens.join(" ");
|
||||
}
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
// Region not present in region bundle
|
||||
region = tokens.join(" ");
|
||||
}
|
||||
|
||||
is_region_set = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (is_region_set) {
|
||||
result = gMetadataBundle.getFormattedString("languageRegionFormat",
|
||||
[language, region]);
|
||||
} else
|
||||
result = language;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
// Returns the size of the URL in bytes; must be cached and therefore an HTTP or FTP URL
|
||||
function getSize(url) {
|
||||
try
|
||||
{
|
||||
var cacheEntryDescriptor = httpCacheSession.openCacheEntry(url, Components.interfaces.nsICache.ACCESS_READ, false);
|
||||
if(cacheEntryDescriptor)
|
||||
return cacheEntryDescriptor.dataSize;
|
||||
}
|
||||
catch(ex) {}
|
||||
try
|
||||
{
|
||||
cacheEntryDescriptor = ftpCacheSession.openCacheEntry(url, Components.interfaces.nsICache.ACCESS_READ, false);
|
||||
if (cacheEntryDescriptor)
|
||||
return cacheEntryDescriptor.dataSize;
|
||||
}
|
||||
catch(ex) {}
|
||||
return -1;
|
||||
}
|
||||
|
||||
function setAlt(elem) {
|
||||
var altText = document.getElementById("image-alt-text");
|
||||
if (elem.hasAttribute("alt")) {
|
||||
if (elem.alt != "") {
|
||||
altText.value = elem.alt;
|
||||
altText.setAttribute("style","font-style:inherit");
|
||||
} else {
|
||||
altText.value = gMetadataBundle.getString("altTextBlank");
|
||||
altText.setAttribute("style","font-style:italic");
|
||||
}
|
||||
} else {
|
||||
altText.value = gMetadataBundle.getString("altTextMissing");
|
||||
altText.setAttribute("style","font-style:italic");
|
||||
}
|
||||
}
|
||||
@@ -1,226 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is this file as it was released on January 3, 2001.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Jonas Sicking.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2000
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Jonas Sicking <sicking@bigfoot.com> (Original Author)
|
||||
# Gervase Markham <gerv@gerv.net>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://browser/skin/pageInfo.css" type="text/css"?>
|
||||
<?xul-overlay href="chrome://global/content/dialogOverlay.xul"?>
|
||||
|
||||
<!DOCTYPE window SYSTEM "chrome://browser/locale/metaData.dtd" >
|
||||
|
||||
<window id="metadata"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&caption.label;"
|
||||
onload="onLoad()"
|
||||
class="dialog"
|
||||
minwidth="350"
|
||||
persist="screenX screenY"
|
||||
screenX="24" screenY="24">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/metaData.js"/>
|
||||
|
||||
<keyset id="dialogKeys"/>
|
||||
|
||||
<stringbundle src="chrome://browser/locale/metaData.properties" id="bundle_metadata"/>
|
||||
<stringbundle src="chrome://global/locale/languageNames.properties" id="bundle_languages"/>
|
||||
<stringbundle src="chrome://global/locale/regionNames.properties" id="bundle_regions"/>
|
||||
|
||||
<label id="no-properties" value="&no-properties.label;"/>
|
||||
|
||||
<vbox id="link-sec">
|
||||
<label value="&link-sec.label;"/>
|
||||
<separator class="groove"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row id="link-url">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-url.label; "/>
|
||||
<textbox readonly="true" id="link-url-text"/>
|
||||
</row>
|
||||
<row id="link-target">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-target.label; "/>
|
||||
<textbox readonly="true" id="link-target-text"/>
|
||||
</row>
|
||||
<row id="link-type">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-type.label; "/>
|
||||
<textbox readonly="true" id="link-type-text"/>
|
||||
</row>
|
||||
<row id="link-lang">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-lang.label; "/>
|
||||
<textbox readonly="true" id="link-lang-text"/>
|
||||
</row>
|
||||
<row id="link-rel">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-rel.label; "/>
|
||||
<textbox readonly="true" id="link-rel-text"/>
|
||||
</row>
|
||||
<row id="link-rev">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&link-rev.label; "/>
|
||||
<textbox readonly="true" id="link-rev-text"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator/>
|
||||
</vbox>
|
||||
<vbox id="image-sec">
|
||||
<label value="&image-sec.label;"/>
|
||||
<separator class="groove"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row id="image-url">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-url.label; "/>
|
||||
<textbox readonly="true" id="image-url-text"/>
|
||||
</row>
|
||||
<row id="image-width">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-width.label; "/>
|
||||
<textbox readonly="true" id="image-width-text"/>
|
||||
</row>
|
||||
<row id="image-height">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-height.label; "/>
|
||||
<textbox readonly="true" id="image-height-text"/>
|
||||
</row>
|
||||
<row id="image-filesize">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-filesize.label; "/>
|
||||
<textbox readonly="true" id="image-filesize-text"/>
|
||||
</row>
|
||||
<row id="image-alt">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-alt.label; "/>
|
||||
<textbox readonly="true" id="image-alt-text"/>
|
||||
</row>
|
||||
<row id="image-desc">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&image-desc.label; "/>
|
||||
<textbox readonly="true" id="image-desc-text"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator/>
|
||||
</vbox>
|
||||
<vbox id="insdel-sec">
|
||||
<label value="&insdel-sec.label;"/>
|
||||
<separator class="groove"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row id="insdel-cite">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&insdel-cite.label; "/>
|
||||
<textbox readonly="true" id="insdel-cite-text"/>
|
||||
</row>
|
||||
<row id="insdel-date">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&insdel-date.label; "/>
|
||||
<textbox readonly="true" id="insdel-date-text"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator/>
|
||||
</vbox>
|
||||
<vbox id="quote-sec">
|
||||
<label value=""e-sec.label;"/>
|
||||
<separator class="groove"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row id="quote-cite">
|
||||
<separator orient="vertical"/>
|
||||
<label value=""e-cite.label; "/>
|
||||
<textbox readonly="true" id="quote-cite-text"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator/>
|
||||
</vbox>
|
||||
<vbox id="misc-sec">
|
||||
<label value="&misc-sec.label;"/>
|
||||
<separator class="groove"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row id="misc-lang">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&misc-lang.label; "/>
|
||||
<textbox readonly="true" id="misc-lang-text"/>
|
||||
</row>
|
||||
<row id="misc-title">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&misc-title.label; "/>
|
||||
<textbox readonly="true" id="misc-title-text"/>
|
||||
</row>
|
||||
<row id="misc-tblsummary">
|
||||
<separator orient="vertical"/>
|
||||
<label value="&misc-tblsummary.label; "/>
|
||||
<textbox readonly="true" id="misc-tblsummary-text"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator/>
|
||||
</vbox>
|
||||
</window>
|
||||
|
Before Width: | Height: | Size: 8.8 KiB |
@@ -1,166 +0,0 @@
|
||||
# -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Michael Lowe <michael.lowe@bigfoot.com>
|
||||
# Blake Ross <blaker@netscape.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
var browser;
|
||||
var dialog = {};
|
||||
var pref = null;
|
||||
try {
|
||||
pref = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch);
|
||||
} catch (ex) {
|
||||
// not critical, remain silent
|
||||
}
|
||||
|
||||
function onLoad()
|
||||
{
|
||||
dialog.input = document.getElementById("dialog.input");
|
||||
dialog.open = document.documentElement.getButton("accept");
|
||||
dialog.openWhereList = document.getElementById("openWhereList");
|
||||
dialog.openTopWindow = document.getElementById("currentWindow");
|
||||
dialog.bundle = document.getElementById("openLocationBundle");
|
||||
|
||||
if ("arguments" in window && window.arguments.length >= 1)
|
||||
browser = window.arguments[0];
|
||||
|
||||
dialog.openWhereList.selectedItem = dialog.openTopWindow;
|
||||
|
||||
if (pref) {
|
||||
try {
|
||||
var useAutoFill = pref.getBoolPref("browser.urlbar.autoFill");
|
||||
if (useAutoFill)
|
||||
dialog.input.setAttribute("completedefaultindex", "true");
|
||||
} catch (ex) {}
|
||||
|
||||
try {
|
||||
var value = pref.getIntPref("general.open_location.last_window_choice");
|
||||
var element = dialog.openWhereList.getElementsByAttribute("value", value)[0];
|
||||
if (element)
|
||||
dialog.openWhereList.selectedItem = element;
|
||||
dialog.input.value = pref.getComplexValue("general.open_location.last_url",
|
||||
Components.interfaces.nsISupportsString).data;
|
||||
}
|
||||
catch(ex) {
|
||||
}
|
||||
if (dialog.input.value)
|
||||
dialog.input.select(); // XXX should probably be done automatically
|
||||
}
|
||||
|
||||
doEnabling();
|
||||
}
|
||||
|
||||
function doEnabling()
|
||||
{
|
||||
dialog.open.disabled = !dialog.input.value;
|
||||
}
|
||||
|
||||
function open()
|
||||
{
|
||||
var url;
|
||||
var postData = {};
|
||||
if (browser)
|
||||
url = browser.getShortcutOrURI(dialog.input.value, postData);
|
||||
else
|
||||
url = dialog.input.value;
|
||||
|
||||
try {
|
||||
switch (dialog.openWhereList.value) {
|
||||
case "0":
|
||||
browser.loadURI(url, null, postData.value);
|
||||
break;
|
||||
case "1":
|
||||
window.opener.delayedOpenWindow(getBrowserURL(), "all,dialog=no", url, postData);
|
||||
break;
|
||||
case "3":
|
||||
if (browser.getBrowser && browser.getBrowser().localName == "tabbrowser")
|
||||
browser.delayedOpenTab(url, null, null, postData.value);
|
||||
else
|
||||
browser.loadURI(url, null, postData.value); // Just do a normal load.
|
||||
break;
|
||||
}
|
||||
}
|
||||
catch(exception) {
|
||||
}
|
||||
|
||||
if (pref) {
|
||||
var str = Components.classes["@mozilla.org/supports-string;1"]
|
||||
.createInstance(Components.interfaces.nsISupportsString);
|
||||
str.data = dialog.input.value;
|
||||
pref.setComplexValue("general.open_location.last_url",
|
||||
Components.interfaces.nsISupportsString, str);
|
||||
pref.setIntPref("general.open_location.last_window_choice", dialog.openWhereList.value);
|
||||
}
|
||||
|
||||
// Delay closing slightly to avoid timing bug on Linux.
|
||||
window.close();
|
||||
return false;
|
||||
}
|
||||
|
||||
function createInstance(contractid, iidName)
|
||||
{
|
||||
var iid = Components.interfaces[iidName];
|
||||
return Components.classes[contractid].createInstance(iid);
|
||||
}
|
||||
|
||||
const nsIFilePicker = Components.interfaces.nsIFilePicker;
|
||||
function onChooseFile()
|
||||
{
|
||||
try {
|
||||
var fp = Components.classes["@mozilla.org/filepicker;1"].createInstance(nsIFilePicker);
|
||||
fp.init(window, dialog.bundle.getString("chooseFileDialogTitle"), nsIFilePicker.modeOpen);
|
||||
fp.appendFilters(nsIFilePicker.filterHTML | nsIFilePicker.filterText |
|
||||
nsIFilePicker.filterAll | nsIFilePicker.filterImages | nsIFilePicker.filterXML);
|
||||
|
||||
if (fp.show() == nsIFilePicker.returnOK && fp.fileURL.spec && fp.fileURL.spec.length > 0)
|
||||
dialog.input.value = fp.fileURL.spec;
|
||||
}
|
||||
catch(ex) {
|
||||
}
|
||||
doEnabling();
|
||||
}
|
||||
|
||||
function useUBHistoryItem(aMenuItem)
|
||||
{
|
||||
var urlbar = document.getElementById("dialog.input");
|
||||
urlbar.value = aMenuItem.getAttribute("label");
|
||||
urlbar.focus();
|
||||
doEnabling();
|
||||
}
|
||||
|
||||
@@ -1,91 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-1999
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@netscape.com>
|
||||
# Michael Lowe <michael.lowe@bigfoot.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
|
||||
<!DOCTYPE dialog SYSTEM "chrome://browser/locale/openLocation.dtd">
|
||||
|
||||
<dialog id="openLocation"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&caption.label;"
|
||||
onload="onLoad()"
|
||||
buttonlabelaccept="&openBtn.label;"
|
||||
buttoniconaccept="open"
|
||||
ondialogaccept="open()"
|
||||
style="width: 40em;"
|
||||
persist="screenX screenY"
|
||||
screenX="24" screenY="24">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/openLocation.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/utilityOverlay.js"/>
|
||||
|
||||
<stringbundle id="openLocationBundle" src="chrome://browser/locale/openLocation.properties"/>
|
||||
|
||||
<hbox>
|
||||
<separator orient="vertical" class="thin"/>
|
||||
<vbox flex="1">
|
||||
<description>&enter.label;</description>
|
||||
<separator class="thin"/>
|
||||
|
||||
<hbox align="center">
|
||||
<textbox id="dialog.input" flex="1" type="autocomplete"
|
||||
completeselectedindex="true"
|
||||
autocompletesearch="history"
|
||||
enablehistory="true"
|
||||
oninput="doEnabling();"/>
|
||||
<button label="&chooseFile.label;" oncommand="onChooseFile();"/>
|
||||
</hbox>
|
||||
<hbox align="center">
|
||||
<label value="&openWhere.label;"/>
|
||||
<menulist id="openWhereList">
|
||||
<menupopup>
|
||||
<menuitem value="0" id="currentWindow" label="&topWindow.label;"/>
|
||||
<menuitem value="1" label="&newWindow.label;"/>
|
||||
<menuitem value="3" label="&newTab.label;"/>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
<spacer flex="1"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</hbox>
|
||||
|
||||
</dialog>
|
||||
@@ -1,368 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-1999
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Simeon Morrison <smorrison@gte.com>
|
||||
# Chris McAfee <mcafee@netscape.com>
|
||||
# Daniel Brooks <db48x@yahoo.com>
|
||||
# Gervase Markham <gerv@gerv.net>
|
||||
# Florian QUEZE <f.qu@laposte.net>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://browser/skin/pageInfo.css" type="text/css"?>
|
||||
|
||||
<!DOCTYPE window [
|
||||
<!ENTITY % pageInfoDTD SYSTEM "chrome://browser/locale/pageInfo.dtd">
|
||||
%pageInfoDTD;
|
||||
]>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
#endif
|
||||
|
||||
<window id="main-window"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
windowtype="Browser:page-info"
|
||||
onload="onLoadPageInfo()"
|
||||
align="stretch"
|
||||
screenX="10" screenY="10"
|
||||
width="&pageInfoWindow.width;" height="&pageInfoWindow.height;"
|
||||
persist="screenX screenY width height sizemode">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/contentAreaUtils.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/pageInfo.js"/>
|
||||
|
||||
<stringbundle id="pageinfobundle" src="chrome://browser/locale/pageInfo.properties"/>
|
||||
|
||||
<commandset>
|
||||
<command id="cmd_close" oncommand="window.close();"/>
|
||||
<command id="cmd_help" oncommand="doHelpButton();"/>
|
||||
<command id="cmd_copy" oncommand="doCopy();"/>
|
||||
<command id="cmd_selectall" oncommand="doSelectAll();"/>
|
||||
</commandset>
|
||||
|
||||
<keyset>
|
||||
<key key="&closeWindow.key;" modifiers="accel" command="cmd_close"/>
|
||||
<key keycode="VK_ESCAPE" command="cmd_close"/>
|
||||
#ifdef XP_MACOSX
|
||||
<key key="." modifiers="meta" command="cmd_close"/>
|
||||
#endif
|
||||
<key keycode="VK_F1" command="cmd_help"/>
|
||||
<key key="©.key;" modifiers="accel" command="cmd_copy"/>
|
||||
<key key="&selectall.key;" modifiers="accel" command="cmd_selectall"/>
|
||||
<key key="&selectall.key;" modifiers="alt" command="cmd_selectall"/>
|
||||
</keyset>
|
||||
|
||||
<menupopup id="picontext">
|
||||
<menuitem label="&selectall.label;" command="cmd_selectall" accesskey="&selectall.accesskey;"/>
|
||||
<menuitem label="©.label;" command="cmd_copy" accesskey="©.accesskey;"/>
|
||||
</menupopup>
|
||||
|
||||
<tabbox id="tabbox" flex="1" class="spaced">
|
||||
<tabs id="tabs">
|
||||
<tab id="generalTab" label="&generalTab;" accesskey="&generalAccesskey;"/>
|
||||
<tab id="formsTab" label="&formsTab;" accesskey="&formsAccesskey;"
|
||||
oncommand="ensureSelection(formView)"/>
|
||||
<tab id="linksTab" label="&linksTab;" accesskey="&linksAccesskey;"
|
||||
oncommand="ensureSelection(linkView)"/>
|
||||
<tab id="mediaTab" label="&mediaTab;" accesskey="&mediaAccesskey;"
|
||||
oncommand="ensureSelection(imageView)"/>
|
||||
<!-- Others added by overlay -->
|
||||
</tabs>
|
||||
<tabpanels id="tabpanels" flex="1">
|
||||
|
||||
<!-- General page information -->
|
||||
<vbox>
|
||||
<textbox class="header" readonly="true" crop="end" id="titletext"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column style="width: .5em;"/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row>
|
||||
<label control="urltext" value="&generalURL;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="urltext"/>
|
||||
</row>
|
||||
<row>
|
||||
<separator class="thin"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="typetext" value="&generalType;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="typetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="modetext" value="&generalMode;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="modetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="sourcetext" value="&generalSource;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="sourcetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="encodingtext" value="&generalEncoding;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="encodingtext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="sizetext" value="&generalSize;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="sizetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="refertext" value="&generalReferrer;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="refertext"/>
|
||||
</row>
|
||||
<row>
|
||||
<separator class="thin"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="modifiedtext" value="&generalModified;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="modifiedtext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="expirestext" value="&generalExpires;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="expirestext"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<separator class="thin"/>
|
||||
<label id="metahead" control="metatree" class="header" value="&generalMeta;"/>
|
||||
<tree id="metatree" flex="1" contextmenu="picontext">
|
||||
<treecols>
|
||||
<treecol persist="hidden width" flex="1" id="meta-name" label="&generalMetaName;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol persist="hidden width" flex="4" id="meta-content" label="&generalMetaContent;"/>
|
||||
</treecols>
|
||||
<treechildren flex="1"/>
|
||||
</tree>
|
||||
</vbox>
|
||||
|
||||
<!-- Form information -->
|
||||
<vbox>
|
||||
<tree id="formtree" class="fixedsize" onselect="onFormSelect();" contextmenu="picontext">
|
||||
<treecols>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="1"
|
||||
width="1" id="form-name" label="&formName;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="3"
|
||||
width="3" id="form-method" label="&formMethod;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="2"
|
||||
width="2" id="form-action" label="&formAction;"/>
|
||||
</treecols>
|
||||
<treechildren flex="1"/>
|
||||
</tree>
|
||||
<splitter orient="vertical" collapse="after"/>
|
||||
<vbox flex="1">
|
||||
<textbox readonly="true" class="header" id="formname"/>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column style="width: .5em;"/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row>
|
||||
<label control="formenctype" value="&formEncoding;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="formenctype"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="formTarget" value="&formTarget;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" class="label" id="formtarget"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<label control="formpreview" class="header" value="&formFields;"/>
|
||||
<tree id="formpreview" flex="1" contextmenu="picontext">
|
||||
<treecols>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="3"
|
||||
width="3" id="field-label" label="&formLabel;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="3"
|
||||
width="3" id="field-field" label="&formFName;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="1"
|
||||
width="1" id="field-type" label="&formType;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="3"
|
||||
width="3" id="field-value" label="&formCValue;"/>
|
||||
</treecols>
|
||||
<treechildren flex="1"/>
|
||||
</tree>
|
||||
</vbox>
|
||||
</vbox>
|
||||
|
||||
<!-- Link info -->
|
||||
<vbox>
|
||||
<tree id="linktree" flex="1" ondraggesture="onBeginLinkDrag(event,'link-address','link-name')" contextmenu="picontext">
|
||||
<treecols>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="5"
|
||||
width="5" id="link-name" label="&linkName;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="7"
|
||||
width="7" id="link-address" label="&linkAddress;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="2"
|
||||
width="2" id="link-type" label="&linkType;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="2"
|
||||
width="2" id="link-target" label="&linkTarget;" hidden="true"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="1"
|
||||
width="1" id="link-acceskey" label="&linkAccessKey;" hidden="true"/>
|
||||
</treecols>
|
||||
<treechildren flex="1"/>
|
||||
</tree>
|
||||
</vbox>
|
||||
|
||||
<!-- Media information -->
|
||||
<vbox>
|
||||
<tree id="imagetree" class="fixedsize" onselect="onImageSelect();" ondraggesture="onBeginLinkDrag(event,'image-address','image-alt')" contextmenu="picontext">
|
||||
<treecols>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="10"
|
||||
width="10" id="image-address" label="&mediaAddress;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" persist="hidden width" flex="2"
|
||||
width="2" id="image-type" label="&mediaType;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" hidden="true" persist="hidden width" flex="4"
|
||||
width="4" id="image-alt" label="&mediaAltHeader;"/>
|
||||
<splitter class="tree-splitter"/>
|
||||
<treecol sortSeparators="true" hidden="true" persist="hidden width" flex="1"
|
||||
width="1" id="image-count" label="&mediaCount;"/>
|
||||
</treecols>
|
||||
<treechildren flex="1"/>
|
||||
</tree>
|
||||
<splitter collapse="after" orient="vertical"/>
|
||||
<vbox flex="1">
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column style="width: .5em;"/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row>
|
||||
<label control="imageurltext" value="&mediaURL;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imageurltext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagetitletext" value="&mediaTitle;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagetitletext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagealttext" value="&mediaAlt;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagealttext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagelongdesctext" value="&mediaLongdesc;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagelongdesctext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagetypetext" value="&generalType;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagetypetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagesourcetext" value="&generalSource;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagesourcetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imagesizetext" value="&generalSize;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imagesizetext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imageexpirestext" value="&generalExpires;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imageexpirestext"/>
|
||||
</row>
|
||||
<row>
|
||||
<label control="imageSize" value="&mediaDimensions;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="imageSize"/>
|
||||
</row>
|
||||
<row id="physRow" collapsed="true">
|
||||
<label control="physSize" value="&mediaPhysDimensions;"/>
|
||||
<separator/>
|
||||
<textbox readonly="true" crop="end" id="physSize"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<hbox align="end">
|
||||
<label control="thepreviewimage" value="&mediaPreview;" class="header"/>
|
||||
<spacer flex="1"/>
|
||||
<button label="&mediaSaveAs;" accesskey="&mediaSaveAs.accesskey;"
|
||||
icon="save" id="imagesaveasbutton" disabled="true"
|
||||
oncommand="saveMedia();"/>
|
||||
</hbox>
|
||||
<vbox class="inset iframe" flex="1" pack="center">
|
||||
<hbox id="theimagecontainer" pack="center">
|
||||
<image id="thepreviewimage"/>
|
||||
</hbox>
|
||||
<hbox id="brokenimagecontainer" pack="center" collapsed="true">
|
||||
<image id="brokenimage" src="resource:///res/broken-image.gif"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</vbox>
|
||||
</vbox>
|
||||
|
||||
<!-- Others added by overlay -->
|
||||
</tabpanels>
|
||||
</tabbox>
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
#include browserMountPoints.inc
|
||||
#endif
|
||||
|
||||
</window>
|
||||
@@ -1,113 +0,0 @@
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-1999
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt (hyatt@apple.com)
|
||||
# Dean Tessman (dean_tessman@hotmail.com)
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
var gSiteBox;
|
||||
var gUnblockButton;
|
||||
var gPageReport;
|
||||
|
||||
var permissionmanager =
|
||||
Components.classes["@mozilla.org/permissionmanager;1"]
|
||||
.getService(Components.interfaces.nsIPermissionManager);
|
||||
var nsIPermissionManager = Components.interfaces.nsIPermissionManager;
|
||||
|
||||
function onLoad()
|
||||
{
|
||||
gSiteBox = document.getElementById("siteBox");
|
||||
gUnblockButton = document.getElementById("unblockButton");
|
||||
gPageReport = opener.gBrowser.pageReport;
|
||||
|
||||
buildSiteBox();
|
||||
// select the first item using a delay, otherwise the listitems
|
||||
// don't paint as selected.
|
||||
setTimeout(selectFirstItem, 0);
|
||||
}
|
||||
|
||||
function selectFirstItem()
|
||||
{
|
||||
gSiteBox.selectedIndex = 0;
|
||||
}
|
||||
|
||||
function buildSiteBox()
|
||||
{
|
||||
for (var i = 0; i < gPageReport.length; i++) {
|
||||
var found = false;
|
||||
for (var j = 0; j < gSiteBox.childNodes.length; j++) {
|
||||
if (gSiteBox.childNodes[j].label == gPageReport[i]) {
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!found)
|
||||
gSiteBox.appendItem(gPageReport[i]);
|
||||
}
|
||||
}
|
||||
|
||||
function siteSelected()
|
||||
{
|
||||
gUnblockButton.disabled = (gSiteBox.selectedItems.length == 0);
|
||||
}
|
||||
|
||||
function whitelistSite()
|
||||
{
|
||||
var selectedItem = gSiteBox.selectedItems[0];
|
||||
if (!selectedItem)
|
||||
return;
|
||||
|
||||
var selectedIndex = gSiteBox.getIndexOfItem(selectedItem);
|
||||
|
||||
var uri = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(selectedItem.label, null, null);
|
||||
|
||||
permissionmanager.add(uri, "popup", nsIPermissionManager.ALLOW_ACTION);
|
||||
gSiteBox.removeChild(selectedItem);
|
||||
|
||||
if (gSiteBox.getRowCount() == 0) {
|
||||
// close if there are no other sites to whitelist
|
||||
window.close();
|
||||
return;
|
||||
}
|
||||
|
||||
// make sure a site is selected
|
||||
if (selectedIndex > gSiteBox.getRowCount() - 1)
|
||||
selectedIndex -= 1;
|
||||
gSiteBox.selectedIndex = selectedIndex;
|
||||
document.documentElement.getButton("accept").focus()
|
||||
}
|
||||
@@ -1,74 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-1999
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt (hyatt@apple.com)
|
||||
# Dean Tessman (dean_tessman@hotmail.com)
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
|
||||
<!DOCTYPE dialog [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
|
||||
%brandDTD;
|
||||
<!ENTITY % openDialogDTD SYSTEM "chrome://browser/locale/pageReport.dtd" >
|
||||
%openDialogDTD;
|
||||
]>
|
||||
|
||||
<dialog id="pageReport"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&caption.label;"
|
||||
onload="onLoad()"
|
||||
style="width: 40em;"
|
||||
buttons="accept"
|
||||
persist="screenX screenY"
|
||||
screenX="24" screenY="24">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/pageReport.js"/>
|
||||
|
||||
<description>
|
||||
&intro.label;
|
||||
</description>
|
||||
<listbox style="height:10em" id="siteBox" onselect="siteSelected();" flex="1"/>
|
||||
<separator class="thin"/>
|
||||
<hbox>
|
||||
<button label="&unblock.label;" id="unblockButton" oncommand="whitelistSite();"
|
||||
disabled="true" accesskey="&unblock.accesskey;" icon="yes"/>
|
||||
<spacer flex="1"/>
|
||||
<button dlgtype="accept" label="&done.label;" default="true" icon="close"
|
||||
oncommand="window.close();" accesskey="&done.accesskey;"/>
|
||||
</hbox>
|
||||
</dialog>
|
||||
@@ -1,77 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Communicator client code, released
|
||||
# March 31, 1998.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998-1999
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt (hyatt@apple.com)
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://browser/skin/" type="text/css"?>
|
||||
|
||||
<!DOCTYPE dialog [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
|
||||
%brandDTD;
|
||||
<!ENTITY % pageReportFirstTimeDTD SYSTEM "chrome://browser/locale/pageReportFirstTime.dtd" >
|
||||
%pageReportFirstTimeDTD;
|
||||
]>
|
||||
|
||||
<dialog id="pageReportFirstTime"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&caption.label;"
|
||||
onload="setTimeout(function() { window.sizeToContent(); }, 100);"
|
||||
style="width: 40em;"
|
||||
buttons="accept"
|
||||
persist="screenX screenY"
|
||||
screenX="24" screenY="24">
|
||||
|
||||
<description>
|
||||
&startDescription.label;
|
||||
</description>
|
||||
|
||||
<separator class="thin"/>
|
||||
|
||||
<hbox pack="center">
|
||||
<statusbar style="width:20em">
|
||||
<statusbarpanel flex="1" pack="left"><description>&done.label;</description></statusbarpanel>
|
||||
<statusbarpanel class="statusbarpanel-iconic" style="min-height:18px" id="page-report-button" blocked="true"/>
|
||||
</statusbar>
|
||||
</hbox>
|
||||
|
||||
<separator class="thin"/>
|
||||
|
||||
<description>
|
||||
&endDescription.label;
|
||||
</description>
|
||||
|
||||
</dialog>
|
||||
@@ -1,84 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Mike Connor.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Mike Connor <mconnor@steelgryphon.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
function restartApp() {
|
||||
var appStartup = Components.classes["@mozilla.org/toolkit/app-startup;1"]
|
||||
.getService(Components.interfaces.nsIAppStartup);
|
||||
appStartup.quit(appStartup.eForceQuit | appStartup.eRestart);
|
||||
}
|
||||
|
||||
function clearAllPrefs() {
|
||||
var prefService = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefService);
|
||||
prefService.resetUserPrefs();
|
||||
}
|
||||
|
||||
function restoreDefaultBookmarks() {
|
||||
var prefBranch = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch);
|
||||
prefBranch.setBoolPref("browser.bookmarks.restore_default_bookmarks", true);
|
||||
}
|
||||
|
||||
function deleteLocalstore() {
|
||||
const nsIDirectoryServiceContractID = "@mozilla.org/file/directory_service;1";
|
||||
const nsIProperties = Components.interfaces.nsIProperties;
|
||||
var directoryService = Components.classes[nsIDirectoryServiceContractID]
|
||||
.getService(nsIProperties);
|
||||
var localstoreFile = directoryService.get("LStoreS", Components.interfaces.nsIFile);
|
||||
if (localstoreFile.exists())
|
||||
localstoreFile.remove(false);
|
||||
}
|
||||
|
||||
function onOK() {
|
||||
try {
|
||||
if (document.getElementById("resetUserPrefs").checked)
|
||||
clearAllPrefs();
|
||||
if (document.getElementById("resetBookmarks").checked)
|
||||
restoreDefaultBookmarks();
|
||||
if (document.getElementById("resetToolbars").checked)
|
||||
deleteLocalstore();
|
||||
} catch(e) {
|
||||
}
|
||||
|
||||
restartApp();
|
||||
}
|
||||
|
||||
function onCancel() {
|
||||
var appStartup = Components.classes["@mozilla.org/toolkit/app-startup;1"]
|
||||
.getService(Components.interfaces.nsIAppStartup);
|
||||
appStartup.quit(appStartup.eForceQuit);
|
||||
}
|
||||
|
||||
@@ -1,83 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Mike Connor.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Mike Connor <mconnor@steelgryphon.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<!DOCTYPE prefwindow [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
|
||||
%brandDTD;
|
||||
<!ENTITY % safeModeDTD SYSTEM "chrome://browser/locale/safeMode.dtd" >
|
||||
%safeModeDTD;
|
||||
<!ENTITY % browserDTD SYSTEM "chrome://browser/locale/browser.dtd" >
|
||||
%browserDTD;
|
||||
]>
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/"?>
|
||||
|
||||
<dialog id="safeModeDialog"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&safeModeDialog.title;"
|
||||
buttons="accept,cancel,extra1"
|
||||
buttonlabelaccept="&changeAndRestartButton.label;"
|
||||
#ifdef XP_WIN
|
||||
buttonlabelcancel="&quitApplicationCmdWin.label;"
|
||||
#else
|
||||
buttonlabelcancel="&quitApplicationCmd.label;"
|
||||
#endif
|
||||
buttonlabelextra1="&continueButton.label;"
|
||||
width="&window.width;"
|
||||
ondialogaccept="onOK()"
|
||||
ondialogcancel="onCancel()"
|
||||
ondialogextra1="window.close()">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/safeMode.js"/>
|
||||
|
||||
<stringbundle id="preferencesBundle" src="chrome://browser/locale/preferences/preferences.properties"/>
|
||||
|
||||
<description>&safeModeDescription.label;</description>
|
||||
|
||||
<separator class="thin"/>
|
||||
|
||||
<label value="&safeModeDescription2.label;"/>
|
||||
<vbox>
|
||||
<checkbox id="disableThemes" label="&disableThemes.label;" accesskey="&disableThemes.accesskey;" hidden="true"/>
|
||||
<checkbox id="resetToolbars" label="&resetToolbars.label;" accesskey="&resetToolbars.accesskey;"/>
|
||||
<checkbox id="resetBookmarks" label="&resetBookmarks.label;" accesskey="&resetBookmarks.accesskey;"/>
|
||||
<checkbox id="resetUserPrefs" label="&resetUserPrefs.label;" accesskey="&resetUserPrefs.accesskey;"/>
|
||||
</vbox>
|
||||
|
||||
<separator class="thin"/>
|
||||
</dialog>
|
||||
@@ -1,342 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is the Firefox Sanitizer.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Ben Goodger.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@mozilla.org>
|
||||
# Giorgio Maone <g.maone@informaction.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
function Sanitizer() {}
|
||||
Sanitizer.prototype = {
|
||||
// warning to the caller: this one may raise an exception (e.g. bug #265028)
|
||||
clearItem: function (aItemName)
|
||||
{
|
||||
if (this.items[aItemName].canClear)
|
||||
this.items[aItemName].clear();
|
||||
},
|
||||
|
||||
canClearItem: function (aItemName)
|
||||
{
|
||||
return this.items[aItemName].canClear;
|
||||
},
|
||||
|
||||
_prefDomain: "privacy.item.",
|
||||
getNameFromPreference: function (aPreferenceName)
|
||||
{
|
||||
return aPreferenceName.substr(this._prefDomain.length);
|
||||
},
|
||||
|
||||
/**
|
||||
* Deletes privacy sensitive data in a batch, according to user preferences
|
||||
*
|
||||
* @returns null if everything's fine; an object in the form
|
||||
* { itemName: error, ... } on (partial) failure
|
||||
*/
|
||||
sanitize: function ()
|
||||
{
|
||||
var psvc = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefService);
|
||||
var branch = psvc.getBranch(this._prefDomain);
|
||||
var errors = null;
|
||||
for (var itemName in this.items) {
|
||||
var item = this.items[itemName];
|
||||
if ("clear" in item && item.canClear && branch.getBoolPref(itemName)) {
|
||||
// Some of these clear() may raise exceptions (see bug #265028)
|
||||
// to sanitize as much as possible, we catch and store them,
|
||||
// rather than fail fast.
|
||||
// Callers should check returned errors and give user feedback
|
||||
// about items that could not be sanitized
|
||||
try {
|
||||
item.clear();
|
||||
} catch(er) {
|
||||
if (!errors)
|
||||
errors = {};
|
||||
errors[itemName] = er;
|
||||
dump("Error sanitizing " + itemName + ": " + er + "\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
return errors;
|
||||
},
|
||||
|
||||
items: {
|
||||
cache: {
|
||||
clear: function ()
|
||||
{
|
||||
const cc = Components.classes;
|
||||
const ci = Components.interfaces;
|
||||
var cacheService = cc["@mozilla.org/network/cache-service;1"]
|
||||
.getService(ci.nsICacheService);
|
||||
|
||||
// Here we play dirty, trying to brutally wipe out all the cache files
|
||||
// even if the disk cache device has gone away (if it is still with us,
|
||||
// our removal attempt will fail because the directory is locked,
|
||||
// and we fall back to the "nice" way below)
|
||||
|
||||
var cacheDir;
|
||||
// Look at nsCacheProfilePrefObserver::ReadPrefs()
|
||||
// and nsDiskCacheDevice::SetCacheParentDirectory()
|
||||
// for details on how we guess the cache directory
|
||||
try {
|
||||
cacheDir = cc["@mozilla.org/preferences-service;1"]
|
||||
.getService(ci.nsIPrefBranch)
|
||||
.getComplexValue("browser.cache.disk.parent_directory",
|
||||
ci.nsILocalFile);
|
||||
} catch(er) {
|
||||
const dirServ = cc["@mozilla.org/file/directory_service;1"]
|
||||
.getService(ci.nsIProperties);
|
||||
try {
|
||||
cacheDir = dirServ.get("cachePDir",ci.nsILocalFile);
|
||||
} catch(er) {
|
||||
cacheDir = dirServ.get("ProfLD",ci.nsILocalFile);
|
||||
}
|
||||
}
|
||||
|
||||
if (cacheDir) {
|
||||
// Here we try to prevent the "phantom Cache.Trash" issue
|
||||
// reported in bug #296256
|
||||
cacheDir.append("Cache.Trash");
|
||||
try {
|
||||
cacheDir.remove(true);
|
||||
} catch(er) {}
|
||||
cacheDir = cacheDir.parent;
|
||||
cacheDir.append("Cache");
|
||||
try {
|
||||
cacheDir.remove(true);
|
||||
} catch(er) {}
|
||||
}
|
||||
|
||||
try {
|
||||
// The "nice" way
|
||||
cacheService.evictEntries(ci.nsICache.STORE_ANYWHERE);
|
||||
} catch(er) {}
|
||||
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
},
|
||||
|
||||
cookies: {
|
||||
clear: function ()
|
||||
{
|
||||
var cookieMgr = Components.classes["@mozilla.org/cookiemanager;1"]
|
||||
.getService(Components.interfaces.nsICookieManager);
|
||||
cookieMgr.removeAll();
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
var cookieMgr = Components.classes["@mozilla.org/cookiemanager;1"]
|
||||
.getService(Components.interfaces.nsICookieManager);
|
||||
return cookieMgr.enumerator.hasMoreElements();
|
||||
}
|
||||
},
|
||||
|
||||
history: {
|
||||
clear: function ()
|
||||
{
|
||||
var globalHistory = Components.classes["@mozilla.org/browser/global-history;2"]
|
||||
.getService(Components.interfaces.nsIBrowserHistory);
|
||||
globalHistory.removeAllPages();
|
||||
|
||||
try {
|
||||
var os = Components.classes["@mozilla.org/observer-service;1"]
|
||||
.getService(Components.interfaces.nsIObserverService);
|
||||
os.notifyObservers(null, "browser:purge-session-history", "");
|
||||
}
|
||||
catch (e) { }
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
var globalHistory = Components.classes["@mozilla.org/browser/global-history;2"]
|
||||
.getService(Components.interfaces.nsIBrowserHistory);
|
||||
return globalHistory.count != 0;
|
||||
}
|
||||
},
|
||||
|
||||
formdata: {
|
||||
clear: function ()
|
||||
{
|
||||
var formHistory = Components.classes["@mozilla.org/satchel/form-history;1"]
|
||||
.getService(Components.interfaces.nsIFormHistory);
|
||||
formHistory.removeAllEntries();
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
var formHistory = Components.classes["@mozilla.org/satchel/form-history;1"]
|
||||
.getService(Components.interfaces.nsIFormHistory);
|
||||
return formHistory.rowCount != 0;
|
||||
}
|
||||
},
|
||||
|
||||
downloads: {
|
||||
clear: function ()
|
||||
{
|
||||
var dlMgr = Components.classes["@mozilla.org/download-manager;1"]
|
||||
.getService(Components.interfaces.nsIDownloadManager);
|
||||
dlMgr.cleanUp();
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
var dlMgr = Components.classes["@mozilla.org/download-manager;1"]
|
||||
.getService(Components.interfaces.nsIDownloadManager);
|
||||
return dlMgr.canCleanUp;
|
||||
}
|
||||
},
|
||||
|
||||
passwords: {
|
||||
clear: function ()
|
||||
{
|
||||
var pwmgr = Components.classes["@mozilla.org/passwordmanager;1"]
|
||||
.getService(Components.interfaces.nsIPasswordManager);
|
||||
var e = pwmgr.enumerator;
|
||||
var passwds = [];
|
||||
while (e.hasMoreElements()) {
|
||||
var passwd = e.getNext().QueryInterface(Components.interfaces.nsIPassword);
|
||||
passwds.push(passwd);
|
||||
}
|
||||
|
||||
for (var i = 0; i < passwds.length; ++i)
|
||||
pwmgr.removeUser(passwds[i].host, passwds[i].user);
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
var pwmgr = Components.classes["@mozilla.org/passwordmanager;1"]
|
||||
.getService(Components.interfaces.nsIPasswordManager);
|
||||
return pwmgr.enumerator.hasMoreElements();
|
||||
}
|
||||
},
|
||||
|
||||
sessions: {
|
||||
clear: function ()
|
||||
{
|
||||
// clear all auth tokens
|
||||
var sdr = Components.classes["@mozilla.org/security/sdr;1"]
|
||||
.getService(Components.interfaces.nsISecretDecoderRing);
|
||||
sdr.logoutAndTeardown();
|
||||
|
||||
// clear plain HTTP auth sessions
|
||||
var authMgr = Components.classes['@mozilla.org/network/http-auth-manager;1']
|
||||
.getService(Components.interfaces.nsIHttpAuthManager);
|
||||
authMgr.clearAll();
|
||||
},
|
||||
|
||||
get canClear()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
// "Static" members
|
||||
Sanitizer.prefDomain = "privacy.sanitize.";
|
||||
Sanitizer.prefPrompt = "promptOnSanitize";
|
||||
Sanitizer.prefShutdown = "sanitizeOnShutdown";
|
||||
Sanitizer.prefDidShutdown = "didShutdownSanitize";
|
||||
|
||||
Sanitizer._prefs = null;
|
||||
Sanitizer.__defineGetter__("prefs", function()
|
||||
{
|
||||
return Sanitizer._prefs ? Sanitizer._prefs
|
||||
: Sanitizer._prefs = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefService)
|
||||
.getBranch(Sanitizer.prefDomain);
|
||||
});
|
||||
|
||||
// Shows sanitization UI
|
||||
Sanitizer.showUI = function(aParentWindow)
|
||||
{
|
||||
var ww = Components.classes["@mozilla.org/embedcomp/window-watcher;1"]
|
||||
.getService(Components.interfaces.nsIWindowWatcher);
|
||||
#ifdef XP_MACOSX
|
||||
ww.openWindow(null, // make this an app-modal window on Mac
|
||||
#else
|
||||
ww.openWindow(aParentWindow,
|
||||
#endif
|
||||
"chrome://browser/content/sanitize.xul",
|
||||
"Sanitize",
|
||||
"chrome,titlebar,centerscreen,modal",
|
||||
null);
|
||||
};
|
||||
|
||||
/**
|
||||
* Deletes privacy sensitive data in a batch, optionally showing the
|
||||
* sanitize UI, according to user preferences
|
||||
*
|
||||
* @returns null if everything's fine (no error or displayed UI, which
|
||||
* should handle errors);
|
||||
* an object in the form { itemName: error, ... } on (partial) failure
|
||||
*/
|
||||
Sanitizer.sanitize = function(aParentWindow)
|
||||
{
|
||||
if (Sanitizer.prefs.getBoolPref(Sanitizer.prefPrompt)) {
|
||||
Sanitizer.showUI(aParentWindow);
|
||||
return null;
|
||||
}
|
||||
return new Sanitizer().sanitize();
|
||||
};
|
||||
|
||||
Sanitizer.onStartup = function()
|
||||
{
|
||||
// we check for unclean exit with pending sanitization
|
||||
Sanitizer._checkAndSanitize();
|
||||
};
|
||||
|
||||
Sanitizer.onShutdown = function()
|
||||
{
|
||||
// we check if sanitization is needed and perform it
|
||||
Sanitizer._checkAndSanitize();
|
||||
};
|
||||
|
||||
// this is called on startup and shutdown, to perform pending sanitizations
|
||||
Sanitizer._checkAndSanitize = function()
|
||||
{
|
||||
const prefs = Sanitizer.prefs;
|
||||
if (prefs.getBoolPref(Sanitizer.prefShutdown) &&
|
||||
!prefs.prefHasUserValue(Sanitizer.prefDidShutdown)) {
|
||||
// this is a shutdown or a startup after an unclean exit
|
||||
Sanitizer.sanitize(null) || // sanitize() returns null on full success
|
||||
prefs.setBoolPref(Sanitizer.prefDidShutdown, true);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1,179 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is the Firefox Sanitizer.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Ben Goodger.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@mozilla.org>
|
||||
# Giorgio Maone <g.maone@informaction.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/"?>
|
||||
|
||||
<!DOCTYPE prefwindow [
|
||||
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
|
||||
<!ENTITY % sanitizeDTD SYSTEM "chrome://browser/locale/sanitize.dtd">
|
||||
%brandDTD;
|
||||
%sanitizeDTD;
|
||||
]>
|
||||
|
||||
<prefwindow id="SanitizeDialog" type="child"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
dlgbuttons="accept,cancel"
|
||||
title="&sanitizeDialog.title;"
|
||||
style="width: 30em !important;"
|
||||
ondialogaccept="gSanitizePromptDialog.sanitize();">
|
||||
|
||||
<prefpane id="SanitizeDialogPane" onpaneload="gSanitizePromptDialog.init();">
|
||||
<stringbundle id="bundleBrowser" src="chrome://browser/locale/browser.properties"/>
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/sanitize.js"/>
|
||||
<script type="application/x-javascript">
|
||||
<![CDATA[
|
||||
var gSanitizePromptDialog = {
|
||||
init: function ()
|
||||
{
|
||||
var s = new Sanitizer();
|
||||
var sanitizePreferences = document.getElementById("sanitizePreferences");
|
||||
for (var i = 0; i < sanitizePreferences.childNodes.length; ++i) {
|
||||
var preference = sanitizePreferences.childNodes[i];
|
||||
var name = s.getNameFromPreference(preference.name);
|
||||
if (!s.canClearItem(name))
|
||||
preference.disabled = true;
|
||||
}
|
||||
|
||||
var bundleBrowser = document.getElementById("bundleBrowser");
|
||||
document.documentElement.getButton("accept").label = bundleBrowser.getString("sanitizeButton");
|
||||
},
|
||||
|
||||
sanitize: function ()
|
||||
{
|
||||
var s = new Sanitizer();
|
||||
var sanitizePreferences = document.getElementById("sanitizePreferences");
|
||||
var preference, name;
|
||||
for (var i = 0; i < sanitizePreferences.childNodes.length; ++i) {
|
||||
preference = sanitizePreferences.childNodes[i];
|
||||
if (preference.value) {
|
||||
name = s.getNameFromPreference(preference.name);
|
||||
try {
|
||||
s.clearItem(name);
|
||||
} catch(er) {
|
||||
dump(er + " sanitizing " + name);
|
||||
// TODO: give user feedback about partially failed sanitization
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
sanitizePasswords: function ()
|
||||
{
|
||||
var preference = document.getElementById("privacy.item.passwords");
|
||||
var promptPref = document.getElementById("privacy.sanitize.promptOnSanitize");
|
||||
if (preference.value)
|
||||
promptPref.value = true;
|
||||
promptPref.disabled = preference.value;
|
||||
|
||||
return this.onReadGeneric();
|
||||
},
|
||||
|
||||
onReadSanitizePasswords: function ()
|
||||
{
|
||||
return this.sanitizePasswords();
|
||||
},
|
||||
|
||||
onReadGeneric: function ()
|
||||
{
|
||||
var preferences = document.getElementById("sanitizePreferences");
|
||||
var found = false;
|
||||
for (var i = 0; i < preferences.childNodes.length; ++i) {
|
||||
var preference = preferences.childNodes[i];
|
||||
if (preference.value && !preference.disabled) {
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
try {
|
||||
document.documentElement.getButton("accept").disabled = !found;
|
||||
}
|
||||
catch (e) { }
|
||||
return undefined;
|
||||
}
|
||||
};
|
||||
]]>
|
||||
</script>
|
||||
|
||||
<preferences id="sanitizePreferences">
|
||||
<preference id="privacy.item.history" name="privacy.item.history" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.formdata" name="privacy.item.formdata" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.passwords" name="privacy.item.passwords" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.downloads" name="privacy.item.downloads" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.cookies" name="privacy.item.cookies" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.cache" name="privacy.item.cache" type="bool" readonly="true"/>
|
||||
<preference id="privacy.item.sessions" name="privacy.item.sessions" type="bool" readonly="true"/>
|
||||
</preferences>
|
||||
<preferences>
|
||||
<preference id="privacy.sanitize.promptOnSanitize" name="privacy.sanitize.promptOnSanitize" type="bool" instantApply="true"/>
|
||||
</preferences>
|
||||
|
||||
<groupbox orient="vertical" align="start">
|
||||
<caption label="&sanitizeItems.label;"/>
|
||||
|
||||
<checkbox label="&itemHistory.label;" accesskey="&itemHistory.accesskey;"
|
||||
preference="privacy.item.history"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
<checkbox label="&itemFormData.label;" accesskey="&itemFormData.accesskey;"
|
||||
preference="privacy.item.formdata"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
<checkbox label="&itemPasswords.label;" accesskey="&itemPasswords.accesskey;"
|
||||
preference="privacy.item.passwords"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadSanitizePasswords();"/>
|
||||
<checkbox label="&itemDownloads.label;" accesskey="&itemDownloads.accesskey;"
|
||||
preference="privacy.item.downloads"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
<checkbox label="&itemCookies.label;" accesskey="&itemCookies.accesskey;"
|
||||
preference="privacy.item.cookies"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
<checkbox label="&itemCache.label;" accesskey="&itemCache.accesskey;"
|
||||
preference="privacy.item.cache"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
<checkbox label="&itemSessions.label;" accesskey="&itemSessions.accesskey;"
|
||||
preference="privacy.item.sessions"
|
||||
onsyncfrompreference="return gSanitizePromptDialog.onReadGeneric();"/>
|
||||
</groupbox>
|
||||
|
||||
<groupbox orient="vertical" align="start">
|
||||
<checkbox id="promptOnSanitize" label="&promptOnSanitize.label;"
|
||||
accesskey="&promptOnSanitize.accesskey;"
|
||||
preference="privacy.sanitize.promptOnSanitize"/>
|
||||
</groupbox>
|
||||
</prefpane>
|
||||
</prefwindow>
|
||||
@@ -1,495 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# -*- Mode: HTML -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org browser.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Joe Hewitt.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2003
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Pierre Chanial V 2.0 (p_ch@verizon.net)
|
||||
# Gavin Sharp (gavin@gavinsharp.com)
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<bindings id="SearchBindings"
|
||||
xmlns="http://www.mozilla.org/xbl"
|
||||
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
xmlns:xbl="http://www.mozilla.org/xbl">
|
||||
|
||||
<binding id="searchbar-base">
|
||||
<resources>
|
||||
<stylesheet src="chrome://browser/content/searchbarBindings.css"/>
|
||||
<stylesheet src="chrome://browser/skin/searchbar.css"/>
|
||||
</resources>
|
||||
</binding>
|
||||
|
||||
<binding id="searchbar" extends="chrome://browser/content/search.xml#searchbar-base">
|
||||
<content>
|
||||
<xul:stringbundle src="chrome://browser/locale/searchbar.properties"/>
|
||||
<xul:textbox class="searchbar-textbox" type="autocomplete" flex="1"
|
||||
autocompletepopup="PopupAutoComplete"
|
||||
autocompletesearch="form-history"
|
||||
autocompletesearchparam="searchbar-history"
|
||||
completeselectedindex="true"
|
||||
tabscrolling="true"
|
||||
onfocus="URLBarFocusHandler(event, this);"
|
||||
onmousedown="URLBarMouseDownHandler(event, this);"
|
||||
onclick="URLBarClickHandler(event, this);"
|
||||
xbl:inherits="disableautocomplete,searchengine,src">
|
||||
<xul:button class="searchbar-dropmarker" type="menu"
|
||||
id="searchbar-dropmarker" popup="_child" xbl:inherits="src">
|
||||
<xul:menupopup anonid="searchbar-popup" position="after_start"
|
||||
datasources="rdf:internetsearch"
|
||||
ref="NC:SearchEngineRoot"
|
||||
oncommand="this.parentNode.parentNode.onEnginePopupCommand(event);"
|
||||
onpopupshowing="this.parentNode.parentNode.onEnginePopupShowing(event);"
|
||||
onpopuphidden="this.parentNode.parentNode.onEnginePopupHidden(event);">
|
||||
<xul:template>
|
||||
<xul:menuitem type="checkbox"
|
||||
uri="rdf:*" value="rdf:*"
|
||||
src="rdf:http://home.netscape.com/NC-rdf#Icon"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</xul:template>
|
||||
</xul:menupopup>
|
||||
</xul:button>
|
||||
</xul:textbox>
|
||||
</content>
|
||||
<implementation>
|
||||
<field name="mStringBundle"> document.getAnonymousNodes(this)[0] </field>
|
||||
<field name="mTextbox"> document.getAnonymousNodes(this)[1] </field>
|
||||
<method name="focus">
|
||||
<body><![CDATA[
|
||||
this.mTextbox.focus();
|
||||
]]></body>
|
||||
</method>
|
||||
<method name="select">
|
||||
<body><![CDATA[
|
||||
this.mTextbox.select();
|
||||
]]></body>
|
||||
</method>
|
||||
</implementation>
|
||||
</binding>
|
||||
|
||||
<binding id="searchbar-textbox" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete">
|
||||
<implementation>
|
||||
|
||||
<constructor><![CDATA[
|
||||
if (this.parentNode.parentNode.parentNode.localName ==
|
||||
"toolbarpaletteitem")
|
||||
return;
|
||||
setTimeout(function(a) { a.initialize(); }, 0, this);
|
||||
]]></constructor>
|
||||
|
||||
<destructor><![CDATA[
|
||||
// Because XBL and the customize toolbar code interacts poorly,
|
||||
// there may not be anything to remove here
|
||||
try {
|
||||
this.controllers.removeController(this.searchbarController);
|
||||
} catch (ex) { }
|
||||
]]></destructor>
|
||||
|
||||
<property name="mContextMenu" readonly="true">
|
||||
<getter>
|
||||
var textBox = document.getAnonymousElementByAttribute(this,
|
||||
"anonid", "textbox-input-box");
|
||||
return document.getAnonymousElementByAttribute(textBox,
|
||||
"anonid", "input-box-contextmenu");
|
||||
</getter>
|
||||
</property>
|
||||
|
||||
<method name="initialize">
|
||||
<body><![CDATA[
|
||||
this.rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"]
|
||||
.getService(Components.interfaces.nsIRDFService);
|
||||
this.internetSearchDS = this.rdfService.GetDataSource("rdf:internetsearch");
|
||||
this.formHistSvc = Components
|
||||
.classes["@mozilla.org/satchel/form-history;1"]
|
||||
.getService(Components.interfaces.nsIFormHistory);
|
||||
|
||||
this.prefService =
|
||||
Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch2);
|
||||
|
||||
this._initializeEngine();
|
||||
|
||||
var element;
|
||||
element = document.createElementNS(XUL_NS, "menuseparator");
|
||||
this.mContextMenu.appendChild(element);
|
||||
element = document.createElementNS(XUL_NS, "menuitem");
|
||||
element.setAttribute("label", this.mStringBundle
|
||||
.getString("cmd_clearHistory"));
|
||||
element.setAttribute("accesskey", this.mStringBundle
|
||||
.getString("cmd_clearHistory_accesskey"));
|
||||
element.setAttribute("cmd", "cmd_clearhistory");
|
||||
this.mContextMenu.appendChild(element);
|
||||
this.controllers.appendController(this.searchbarController);
|
||||
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="_initializeEngine">
|
||||
<body><![CDATA[
|
||||
var selectedEngineName = null;
|
||||
try {
|
||||
selectedEngineName =
|
||||
this.prefService
|
||||
.getComplexValue("browser.search.selectedEngine",
|
||||
this.nsIPrefLocalizedString).data;
|
||||
} catch (ex) { }
|
||||
|
||||
// try to set the engine by name
|
||||
this.currentEngineName = selectedEngineName;
|
||||
|
||||
// check to see whether it failed
|
||||
if (!this.currentEngine)
|
||||
this.currentEngine = this.getDefaultEngine();
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<field name="nsIPrefLocalizedString">
|
||||
Components.interfaces.nsIPrefLocalizedString;
|
||||
</field>
|
||||
<field name="mStringBundle"> this.parentNode.mStringBundle </field>
|
||||
<field name="rdfService"/>
|
||||
<field name="internetSearchDS"/>
|
||||
<field name="formHistSvc"/>
|
||||
|
||||
<method name="openSearch">
|
||||
<body>
|
||||
<![CDATA[
|
||||
if (!this.popupOpen) { // Don't open search popup if history popup is open
|
||||
document.getAnonymousElementByAttribute(this.parentNode,
|
||||
"id", "searchbar-dropmarker").click();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
]]>
|
||||
</body>
|
||||
</method>
|
||||
|
||||
<property name="currentEngine"
|
||||
onget="return this.parentNode.getAttribute('searchengine');">
|
||||
<setter><![CDATA[
|
||||
|
||||
if (!val) {
|
||||
if (this.parentNode)
|
||||
this.parentNode.removeAttribute("searchengine");
|
||||
return;
|
||||
}
|
||||
|
||||
this.parentNode.setAttribute("searchengine", val);
|
||||
const kNC_Icon = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#Icon");
|
||||
var rEngine = this.rdfService.GetResource(val);
|
||||
|
||||
this.parentNode.setAttribute("src", this.readRDFString(rEngine, kNC_Icon));
|
||||
|
||||
const kNC_Name = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#Name");
|
||||
var pls = Components.classes["@mozilla.org/pref-localizedstring;1"]
|
||||
.createInstance(this.nsIPrefLocalizedString);
|
||||
pls.data = this.readRDFString(rEngine, kNC_Name);
|
||||
|
||||
this.prefService.setComplexValue("browser.search.selectedEngine",
|
||||
this.nsIPrefLocalizedString, pls);
|
||||
|
||||
// XXX Why did mStringBundle say that formatStringFromName is not a method?
|
||||
var stringBundleService = Components.classes["@mozilla.org/intl/stringbundle;1"]
|
||||
.getService(Components.interfaces.nsIStringBundleService);
|
||||
var localeService = Components.classes["@mozilla.org/intl/nslocaleservice;1"]
|
||||
.getService(Components.interfaces.nsILocaleService);
|
||||
var bundle = stringBundleService.createBundle("chrome://browser/locale/searchbar.properties",
|
||||
localeService.getApplicationLocale());
|
||||
var toolTipText = bundle.formatStringFromName("searchtip", [pls], 1);
|
||||
this.setAttribute("tooltiptext", toolTipText);
|
||||
]]></setter>
|
||||
</property>
|
||||
|
||||
<property name="currentEngineName"
|
||||
onget="return this.parentNode.getAttribute('searchenginename');"
|
||||
onset="this.setEngineByName(val);"/>
|
||||
|
||||
<method name="setEngineByName">
|
||||
<parameter name="aName"/>
|
||||
<body><![CDATA[
|
||||
// XXX this shouldn't be necessary, but it avoids errors
|
||||
// because the searchbar isn't currently destroyed when
|
||||
// removed from the toolbar
|
||||
if (!this.parentNode) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const kNC_Root = this.rdfService.GetResource("NC:SearchEngineRoot");
|
||||
const kNC_Child = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#child");
|
||||
const kNC_Name = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#Name");
|
||||
|
||||
var arcs = this.internetSearchDS.GetTargets(kNC_Root, kNC_Child, true);
|
||||
while (arcs.hasMoreElements()) {
|
||||
var rEngine = arcs.getNext().QueryInterface(Components.interfaces.nsIRDFResource);
|
||||
var name = this.readRDFString(rEngine, kNC_Name);
|
||||
if (name == aName) {
|
||||
this.currentEngine = rEngine.Value;
|
||||
this.parentNode.setAttribute("searchenginename", name);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
this.currentEngine = null;
|
||||
this.parentNode.removeAttribute("searchenginename")
|
||||
return false;
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="getDefaultEngine">
|
||||
<body><![CDATA[
|
||||
var defaultName = this.prefService
|
||||
.getComplexValue("browser.search.defaultenginename",
|
||||
this.nsIPrefLocalizedString).data;
|
||||
|
||||
const kNC_Root = this.rdfService.GetResource("NC:SearchEngineRoot");
|
||||
const kNC_child = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#child");
|
||||
const kNC_Name = this.rdfService.GetResource("http://home.netscape.com/NC-rdf#Name");
|
||||
|
||||
var arcs = this.internetSearchDS.GetTargets(kNC_Root, kNC_child, true);
|
||||
while (arcs.hasMoreElements()) {
|
||||
var rEngine = arcs.getNext().QueryInterface(Components.interfaces.nsIRDFResource);
|
||||
var name = this.readRDFString(rEngine, kNC_Name);
|
||||
if (name == defaultName)
|
||||
return rEngine.Value;
|
||||
}
|
||||
return null;
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="readRDFString">
|
||||
<parameter name="aRes"/>
|
||||
<parameter name="aProp"/>
|
||||
<body><![CDATA[
|
||||
var n = this.internetSearchDS.GetTarget(aRes, aProp, true);
|
||||
return n ? n.QueryInterface(Components.interfaces.nsIRDFLiteral).Value : null;
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
// overload |onTextEntered| in autocomplete.xml
|
||||
<method name="onTextEntered">
|
||||
<parameter name="aEvent"/>
|
||||
<body><![CDATA[
|
||||
// Save the current value in the form history
|
||||
if (this.value && !this.hasAttribute("disableautocomplete"))
|
||||
this.formHistSvc.addEntry(this.getAttribute(
|
||||
"autocompletesearchparam"), this.value);
|
||||
|
||||
var ISEARCHSVC = Components.classes["@mozilla.org/rdf/datasource;1?name=internetsearch"]
|
||||
.getService(Components.interfaces.nsIInternetSearchService);
|
||||
//XXX Bug 269994: Add in dummy search text "ABC" if the field is empty to ensure a result
|
||||
var searchURL = ISEARCHSVC.GetInternetSearchURL(this.currentEngine,
|
||||
this.value? encodeURIComponent(this.value):"ABC",
|
||||
0, 0, {value:0});
|
||||
|
||||
// if the search box is empty, let's load the host
|
||||
if (!this.value) {
|
||||
var uri = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(searchURL, null, null);
|
||||
|
||||
try {
|
||||
searchURL = uri.host;
|
||||
} catch (ex) {}
|
||||
}
|
||||
var evt = aEvent || this.mEnterEvent;
|
||||
SearchLoadURL(searchURL, (evt && evt.altKey));
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="onEnginePopupCommand">
|
||||
<parameter name="aEvent"/>
|
||||
<body><![CDATA[
|
||||
var target = aEvent.target
|
||||
if (target.getAttribute("anonid") == "addengine-menuitem") {
|
||||
var regionBundle = document.getElementById("bundle_browser_region");
|
||||
loadURI(regionBundle.getString("searchEnginesURL"), null, null);
|
||||
} else {
|
||||
this.currentEngine = target.id;
|
||||
this.focus();
|
||||
this.select();
|
||||
}
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="onEnginePopupShowing">
|
||||
<parameter name="aEvent"/>
|
||||
<body><![CDATA[
|
||||
var target = aEvent.target;
|
||||
var element = document.getAnonymousElementByAttribute(this.parentNode,
|
||||
"anonid", "addengine-menuitem");
|
||||
if (element)
|
||||
return;
|
||||
|
||||
element = document.createElementNS(XUL_NS, "menuseparator");
|
||||
target.appendChild(element);
|
||||
element = document.createElementNS(XUL_NS, "menuitem");
|
||||
element.setAttribute("label", this.mStringBundle
|
||||
.getString("cmd_addEngine"));
|
||||
element.setAttribute("accesskey", this.mStringBundle
|
||||
.getString("cmd_addEngine_accesskey"));
|
||||
element.setAttribute("anonid", "addengine-menuitem");
|
||||
target.appendChild(element);
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="onEnginePopupHidden">
|
||||
<parameter name="aEvent"/>
|
||||
<body><![CDATA[
|
||||
var target = aEvent.target;
|
||||
var element = document.getAnonymousElementByAttribute(this.parentNode,
|
||||
"anonid", "addengine-menuitem");
|
||||
if (element) {
|
||||
target.removeChild(target.lastChild);
|
||||
target.removeChild(target.lastChild);
|
||||
}
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<!-- nsIController -->
|
||||
<field name="searchbarController" readonly="true"><![CDATA[
|
||||
({
|
||||
mOuter: this,
|
||||
|
||||
supportsCommand: function (aCommand)
|
||||
{
|
||||
return aCommand == "cmd_clearhistory";
|
||||
},
|
||||
|
||||
isCommandEnabled: function (aCommand)
|
||||
{
|
||||
return this.mOuter.formHistSvc.nameExists(
|
||||
this.mOuter.getAttribute("autocompletesearchparam"));
|
||||
},
|
||||
|
||||
doCommand: function (aCommand)
|
||||
{
|
||||
this.mOuter.formHistSvc.removeEntriesForName(
|
||||
this.mOuter.getAttribute("autocompletesearchparam"));
|
||||
this.mOuter.value = "";
|
||||
}
|
||||
})
|
||||
]]></field>
|
||||
|
||||
<!-- DND Observer -->
|
||||
<field name="searchbarDNDObserver" readonly="true"><![CDATA[
|
||||
({
|
||||
mOuter: this,
|
||||
|
||||
onDrop: function (aEvent, aXferData, aDragSession)
|
||||
{
|
||||
var data = transferUtils.retrieveURLFromData(aXferData.data,
|
||||
aXferData.flavour.contentType);
|
||||
if (data) {
|
||||
this.mOuter.value = data;
|
||||
this.mOuter.onTextEntered(aEvent);
|
||||
}
|
||||
},
|
||||
|
||||
getSupportedFlavours: function ()
|
||||
{
|
||||
var flavourSet = new FlavourSet();
|
||||
|
||||
flavourSet.appendFlavour("text/unicode");
|
||||
flavourSet.appendFlavour("text/x-moz-url");
|
||||
flavourSet.appendFlavour("application/x-moz-file", "nsIFile");
|
||||
return flavourSet;
|
||||
}
|
||||
})
|
||||
]]></field>
|
||||
|
||||
</implementation>
|
||||
|
||||
<handlers>
|
||||
|
||||
<handler event="keypress" keycode="vk_up" modifiers="accel" phase="capturing">
|
||||
<![CDATA[
|
||||
var currentEngine = this.currentEngine;
|
||||
if (currentEngine) {
|
||||
var searchEngineMenuitem = document.getAnonymousElementByAttribute(this.parentNode, "id", currentEngine);
|
||||
var newEngine = searchEngineMenuitem.previousSibling;
|
||||
if (newEngine && newEngine.localName == "menuitem")
|
||||
this.currentEngine = newEngine.id;
|
||||
}
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
]]>
|
||||
</handler>
|
||||
|
||||
<handler event="keypress" keycode="vk_down" modifiers="alt" phase="capturing"
|
||||
action="return this.openSearch();"/>
|
||||
|
||||
<handler event="keypress" keycode="vk_up" modifiers="alt" phase="capturing"
|
||||
action="return this.openSearch();"/>
|
||||
|
||||
#ifndef XP_MACOSX
|
||||
<handler event="keypress" keycode="vk_f4" phase="capturing"
|
||||
action="return this.openSearch();"/>
|
||||
#endif
|
||||
|
||||
<handler event="keypress" keycode="vk_down" modifiers="accel" phase="capturing">
|
||||
<![CDATA[
|
||||
var currentEngine = this.currentEngine;
|
||||
if (currentEngine) {
|
||||
var searchEngineMenuitem = document.getAnonymousElementByAttribute(this.parentNode, "id", currentEngine);
|
||||
|
||||
var newEngine = searchEngineMenuitem.nextSibling;
|
||||
|
||||
if (newEngine && newEngine.localName == "menuitem")
|
||||
this.currentEngine = newEngine.id;
|
||||
}
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
]]>
|
||||
</handler>
|
||||
|
||||
<handler event="dragdrop" phase="capturing">
|
||||
nsDragAndDrop.drop(event, this.searchbarDNDObserver);
|
||||
</handler>
|
||||
|
||||
</handlers>
|
||||
|
||||
</binding>
|
||||
|
||||
<binding id="searchbar-dropmarker" extends="chrome://browser/content/search.xml#searchbar-base">
|
||||
<content>
|
||||
<xul:stack flex="1">
|
||||
<xul:hbox align="center">
|
||||
<xul:image class="searchbar-engine-image" xbl:inherits="src"/>
|
||||
</xul:hbox>
|
||||
<xul:image class="searchbar-dropmarker-image"/>
|
||||
</xul:stack>
|
||||
<children/>
|
||||
</content>
|
||||
</binding>
|
||||
|
||||
</bindings>
|
||||
@@ -1,53 +0,0 @@
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
#if 0
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is Mozilla Search Dialog.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Gavin Sharp <gavin@gavinsharp.com>.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2005
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
#endif
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#searchEngineList {
|
||||
min-height: 24px;
|
||||
}
|
||||
|
||||
.engine-icon > .menulist-label-box > .menulist-icon,
|
||||
.engine-icon > .menu-iconic-left > .menu-iconic-icon {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
min-height: 16px;
|
||||
}
|
||||
|
||||
.engine-icon > .menu-iconic-left {
|
||||
display: -moz-box;
|
||||
min-height: 16px;
|
||||
}
|
||||
@@ -1,211 +0,0 @@
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
#if 0
|
||||
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
-
|
||||
- The contents of this file are subject to the Mozilla Public License Version
|
||||
- 1.1 (the "License"); you may not use this file except in compliance with
|
||||
- the License. You may obtain a copy of the License at
|
||||
- http://www.mozilla.org/MPL/
|
||||
-
|
||||
- Software distributed under the License is distributed on an "AS IS" basis,
|
||||
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
- for the specific language governing rights and limitations under the
|
||||
- License.
|
||||
-
|
||||
- The Original Code is Mozilla Search Dialog.
|
||||
-
|
||||
- The Initial Developer of the Original Code is
|
||||
- Gavin Sharp <gavin@gavinsharp.com>.
|
||||
- Portions created by the Initial Developer are Copyright (C) 2005
|
||||
- the Initial Developer. All Rights Reserved.
|
||||
-
|
||||
- Contributor(s):
|
||||
- Pierre Chanial <p_ch@verizon.net>
|
||||
-
|
||||
- Alternatively, the contents of this file may be used under the terms of
|
||||
- either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
- in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
- of those above. If you wish to allow use of your version of this file only
|
||||
- under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
- use your version of this file under the terms of the MPL, indicate your
|
||||
- decision by deleting the provisions above and replace them with the notice
|
||||
- and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
- the provisions above, a recipient may use your version of this file under
|
||||
- the terms of any one of the MPL, the GPL or the LGPL.
|
||||
-
|
||||
#endif
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
var gDialog = {};
|
||||
var gSelectedEngineIndex;
|
||||
|
||||
const kTabPref = "browser.tabs.opentabfor.searchdialog";
|
||||
const kEnginePref = "browser.search.selectedEngineInDialog";
|
||||
const kDefEnginePref = "browser.search.defaultenginename";
|
||||
const nsIPLS = Components.interfaces.nsIPrefLocalizedString;
|
||||
const kXUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
|
||||
|
||||
function onLoad() {
|
||||
setTimeout(onAfterLoad, 0);
|
||||
}
|
||||
|
||||
function onAfterLoad() {
|
||||
|
||||
gDialog.list = document.getElementById("searchEngineList");
|
||||
gDialog.list.addEventListener("ValueChange", onEnginesListValueChange, false);
|
||||
gDialog.input = document.getElementById("searchInput");
|
||||
gDialog.newtab = document.getElementById("searchInNewTab");
|
||||
gDialog.searchbundle = document.getElementById("searchbarBundle");
|
||||
gDialog.browserbundle = document.getElementById("browserBundle");
|
||||
|
||||
var el = document.getAnonymousElementByAttribute(gDialog.input, "anonid",
|
||||
"textbox-input-box");
|
||||
gDialog.contextmenu = document.getAnonymousElementByAttribute(el,
|
||||
"anonid", "input-box-contextmenu");
|
||||
|
||||
var pref = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch2);
|
||||
|
||||
var selectedEngine;
|
||||
var tabChecked = false;
|
||||
try {
|
||||
selectedEngine = pref.getComplexValue(kEnginePref, nsIPLS).data;
|
||||
} catch (ex) {
|
||||
selectedEngine = pref.getComplexValue(kDefEnginePref, nsIPLS).data;
|
||||
}
|
||||
try {
|
||||
tabChecked = pref.getBoolPref(kTabPref);
|
||||
} catch (ex) { }
|
||||
|
||||
gDialog.newtab.setAttribute("checked", tabChecked);
|
||||
|
||||
for (var i=0; i < gDialog.list.menupopup.childNodes.length; i++) {
|
||||
var label = gDialog.list.menupopup.childNodes[i].getAttribute("label");
|
||||
if (label == selectedEngine)
|
||||
gDialog.list.selectedIndex = i;
|
||||
}
|
||||
|
||||
// Make sure we have a selected item
|
||||
if (gDialog.list.selectedIndex == -1)
|
||||
gDialog.list.selectedIndex = 0;
|
||||
|
||||
gSelectedEngineIndex = gDialog.list.selectedIndex;
|
||||
|
||||
// Add "Clear Search History" item to the text box context menu
|
||||
var sep = document.createElementNS(kXUL_NS, "menuseparator");
|
||||
gDialog.contextmenu.appendChild(sep);
|
||||
|
||||
var element = document.createElementNS(kXUL_NS, "menuitem");
|
||||
|
||||
var label = gDialog.searchbundle.getString("cmd_clearHistory");
|
||||
var accesskey = gDialog.searchbundle.getString("cmd_clearHistory_accesskey");
|
||||
element.setAttribute("label", label);
|
||||
element.setAttribute("accesskey", accesskey);
|
||||
element.setAttribute("cmd", "cmd_clearhistory");
|
||||
|
||||
gDialog.contextmenu.appendChild(element);
|
||||
gDialog.input.controllers.appendController(clearHistoryController);
|
||||
}
|
||||
|
||||
function onEnginesListValueChange() {
|
||||
if (gDialog.list.value == "addengines") {
|
||||
var url = gDialog.browserbundle.getString("searchEnginesURL");
|
||||
window.opener.openNewWindowWith(url, null, false);
|
||||
gDialog.list.selectedIndex = gSelectedEngineIndex;
|
||||
} else {
|
||||
gSelectedEngineIndex = gDialog.list.selectedIndex;
|
||||
}
|
||||
}
|
||||
|
||||
function updateAddEnginesItem(aAdd) {
|
||||
// Remove the old item if it exists
|
||||
var elem = document.getElementById("addenginemenuitem");
|
||||
var sep = document.getElementById("addenginesep");
|
||||
if (elem)
|
||||
gDialog.list.menupopup.removeChild(elem);
|
||||
if (sep)
|
||||
gDialog.list.menupopup.removeChild(sep);
|
||||
|
||||
if (aAdd) {
|
||||
// Add "Add Engines" item to the drop down
|
||||
var sep = document.createElementNS(kXUL_NS, "menuseparator");
|
||||
sep.setAttribute("id", "addenginesep");
|
||||
gDialog.list.menupopup.appendChild(sep);
|
||||
|
||||
var label = gDialog.searchbundle.getString("cmd_addEngine");
|
||||
var newItem = gDialog.list.appendItem(label, "addengines");
|
||||
newItem.setAttribute("id", "addenginemenuitem");
|
||||
newItem.setAttribute("class", "menuitem-iconic engine-icon");
|
||||
}
|
||||
}
|
||||
|
||||
function onDialogAccept() {
|
||||
var searchText = gDialog.input.value;
|
||||
var engine = gDialog.list.value;
|
||||
var searchURL;
|
||||
|
||||
var searchSvc =
|
||||
Components.classes["@mozilla.org/rdf/datasource;1?name=internetsearch"]
|
||||
.getService(Components.interfaces.nsIInternetSearchService);
|
||||
|
||||
// XXX Bug 269994: Use dummy string if there is no user entered string
|
||||
searchURL = searchSvc.GetInternetSearchURL(engine,
|
||||
searchText ? encodeURIComponent(searchText):"A",
|
||||
0, 0, {value:0});
|
||||
|
||||
if (searchText) {
|
||||
// Add item to form history
|
||||
var frmHistSvc = Components.classes["@mozilla.org/satchel/form-history;1"]
|
||||
.getService(Components.interfaces.nsIFormHistory);
|
||||
frmHistSvc.addEntry("searchbar-history", searchText);
|
||||
} else {
|
||||
try {
|
||||
// Get the engine's base URL
|
||||
searchURL = makeURI(searchURL).host;
|
||||
} catch (ex) {}
|
||||
}
|
||||
|
||||
setPrefs();
|
||||
gDialog.input.controllers.removeController(clearHistoryController);
|
||||
|
||||
window.opener.delayedSearchLoadURL(searchURL, gDialog.newtab.checked);
|
||||
|
||||
// Delay closing slightly to avoid timing bug on Linux.
|
||||
window.close();
|
||||
return false;
|
||||
}
|
||||
|
||||
function setPrefs() {
|
||||
var pref = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch2);
|
||||
|
||||
var pls = Components.classes["@mozilla.org/pref-localizedstring;1"]
|
||||
.createInstance(nsIPLS);
|
||||
|
||||
var name = gDialog.list.selectedItem.getAttribute("label");
|
||||
pls.data = name;
|
||||
|
||||
pref.setComplexValue(kEnginePref, nsIPLS, pls);
|
||||
pref.setBoolPref(kTabPref, gDialog.newtab.checked);
|
||||
}
|
||||
|
||||
var clearHistoryController = {
|
||||
frmHistSvc: Components.classes["@mozilla.org/satchel/form-history;1"]
|
||||
.getService(Components.interfaces.nsIFormHistory),
|
||||
|
||||
autocompleteSearchParam: "searchbar-history",
|
||||
|
||||
supportsCommand: function (aCommand) {
|
||||
return aCommand == "cmd_clearhistory";
|
||||
},
|
||||
|
||||
isCommandEnabled: function (aCommand) {
|
||||
return this.frmHistSvc.nameExists(this.autocompleteSearchParam);
|
||||
},
|
||||
|
||||
doCommand: function (aCommand) {
|
||||
this.frmHistSvc.removeEntriesForName(this.autocompleteSearchParam);
|
||||
gDialog.input.value = "";
|
||||
}
|
||||
}
|
||||
@@ -1,110 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- ***** BEGIN LICENSE BLOCK *****
|
||||
#if 0
|
||||
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
-
|
||||
- The contents of this file are subject to the Mozilla Public License Version
|
||||
- 1.1 (the "License"); you may not use this file except in compliance with
|
||||
- the License. You may obtain a copy of the License at
|
||||
- http://www.mozilla.org/MPL/
|
||||
-
|
||||
- Software distributed under the License is distributed on an "AS IS" basis,
|
||||
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
- for the specific language governing rights and limitations under the
|
||||
- License.
|
||||
-
|
||||
- The Original Code is Mozilla Search Dialog.
|
||||
-
|
||||
- The Initial Developer of the Original Code is
|
||||
- Gavin Sharp <gavin@gavinsharp.com>.
|
||||
- Portions created by the Initial Developer are Copyright (C) 2005
|
||||
- the Initial Developer. All Rights Reserved.
|
||||
-
|
||||
- Contributor(s):
|
||||
-
|
||||
- Alternatively, the contents of this file may be used under the terms of
|
||||
- either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
- in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
- of those above. If you wish to allow use of your version of this file only
|
||||
- under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
- use your version of this file under the terms of the MPL, indicate your
|
||||
- decision by deleting the provisions above and replace them with the notice
|
||||
- and other provisions required by the LGPL or the GPL. If you do not delete
|
||||
- the provisions above, a recipient may use your version of this file under
|
||||
- the terms of any one of the MPL, the GPL or the LGPL.
|
||||
-
|
||||
#endif
|
||||
- ***** END LICENSE BLOCK ***** -->
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://browser/content/searchDialog.css"?>
|
||||
|
||||
<!DOCTYPE dialog SYSTEM "chrome://browser/locale/searchDialog.dtd">
|
||||
|
||||
<dialog id="searchDialog"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
title="&searchCaption.label;"
|
||||
onload="onLoad()"
|
||||
ondialogaccept="onDialogAccept()"
|
||||
buttonlabelaccept="&searchButton.label;"
|
||||
persist="screenX screenY width height"
|
||||
screenX="24" screenY="24"
|
||||
style="&searchDialog.style;">
|
||||
|
||||
<stringbundle id="searchbarBundle"
|
||||
src="chrome://browser/locale/searchbar.properties"/>
|
||||
<stringbundle id="browserBundle"
|
||||
src="chrome://browser-region/locale/region.properties"/>
|
||||
<script type="application/x-javascript"
|
||||
src="chrome://browser/content/searchDialog.js"/>
|
||||
<script type="application/x-javascript"
|
||||
src="chrome://global/content/contentAreaUtils.js"/>
|
||||
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row align="center">
|
||||
<label value="&searchFor.label;"
|
||||
accesskey="&searchFor.accesskey;" control="searchInput"/>
|
||||
<textbox id="searchInput"
|
||||
class="padded"
|
||||
type="autocomplete"
|
||||
autocompletepopup="PopupAutoComplete"
|
||||
autocompletesearch="form-history"
|
||||
autocompletesearchparam="searchbar-history"
|
||||
completeselectedindex="true"
|
||||
tabscrolling="true"/>
|
||||
</row>
|
||||
<row align="center">
|
||||
<label value="&searchWith.label;"
|
||||
accesskey="&searchWith.accesskey;" control="searchEngineList"/>
|
||||
<menulist id="searchEngineList" flex="1"
|
||||
onselect="addEngines();">
|
||||
<menupopup id="searchEnginePopup" position="after_start"
|
||||
datasources="rdf:internetsearch"
|
||||
ref="NC:SearchEngineRoot"
|
||||
onpopupshowing="updateAddEnginesItem(true);"
|
||||
onpopuphiding="updateAddEnginesItem(false);">
|
||||
<template>
|
||||
<menuitem type="checkbox"
|
||||
class="menuitem-iconic engine-icon"
|
||||
uri="rdf:*" value="rdf:*"
|
||||
src="rdf:http://home.netscape.com/NC-rdf#Icon"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</template>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
</row>
|
||||
<row>
|
||||
<spacer/>
|
||||
<checkbox id="searchInNewTab" label="&searchInNewTab.label;"
|
||||
accesskey="&searchInNewTab.accesskey;"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
</dialog>
|
||||
@@ -1,11 +0,0 @@
|
||||
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
|
||||
|
||||
.searchbar-textbox {
|
||||
-moz-binding: url("chrome://browser/content/search.xml#searchbar-textbox");
|
||||
}
|
||||
|
||||
.searchbar-dropmarker {
|
||||
-moz-binding: url("chrome://browser/content/search.xml#searchbar-dropmarker");
|
||||
-moz-user-focus: none;
|
||||
}
|
||||
|
||||
@@ -1,50 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<overlay id="softwareUpdateOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<window id="updates">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
</overlay>
|
||||
@@ -1,524 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Alec Flett <alecf@netscape.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
/**
|
||||
* Communicator Shared Utility Library
|
||||
* for shared application glue for the Communicator suite of applications
|
||||
**/
|
||||
|
||||
var goPrefWindow = 0;
|
||||
var gBidiUI = false;
|
||||
|
||||
function getBrowserURL()
|
||||
{
|
||||
return "chrome://browser/content/browser.xul";
|
||||
}
|
||||
|
||||
function goToggleToolbar( id, elementID )
|
||||
{
|
||||
var toolbar = document.getElementById(id);
|
||||
var element = document.getElementById(elementID);
|
||||
if (toolbar)
|
||||
{
|
||||
var isHidden = toolbar.hidden;
|
||||
toolbar.hidden = !isHidden;
|
||||
document.persist(id, 'hidden');
|
||||
if (element) {
|
||||
element.setAttribute("checked", isHidden ? "true" : "false");
|
||||
document.persist(elementID, 'checked');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// urlPref: lets each application have its own throbber URL. example: "messenger.throbber.url"
|
||||
// event: lets shift+click open it in a new window, etc.
|
||||
function goClickThrobber( urlPref, e )
|
||||
{
|
||||
var url;
|
||||
try {
|
||||
var pref = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch);
|
||||
url = pref.getComplexValue(urlPref, Components.interfaces.nsIPrefLocalizedString).data;
|
||||
}
|
||||
|
||||
catch(e) {
|
||||
url = null;
|
||||
}
|
||||
|
||||
if ( url )
|
||||
openUILink(url, e);
|
||||
}
|
||||
|
||||
function getTopWin()
|
||||
{
|
||||
var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService();
|
||||
var windowManagerInterface = windowManager.QueryInterface( Components.interfaces.nsIWindowMediator);
|
||||
var topWindowOfType = windowManagerInterface.getMostRecentWindow( "navigator:browser" );
|
||||
|
||||
if (topWindowOfType) {
|
||||
return topWindowOfType;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function openTopWin( url )
|
||||
{
|
||||
openUILink(url, {})
|
||||
}
|
||||
|
||||
|
||||
|
||||
function getBoolPref ( prefname, def )
|
||||
{
|
||||
try {
|
||||
var pref = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch);
|
||||
return pref.getBoolPref(prefname);
|
||||
}
|
||||
catch(er) {
|
||||
return def;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// openUILink handles clicks on UI elements that cause URLs to load.
|
||||
function openUILink( url, e, ignoreButton, ignoreAlt )
|
||||
{
|
||||
var where = whereToOpenLink(e, ignoreButton, ignoreAlt);
|
||||
openUILinkIn(url, where);
|
||||
}
|
||||
|
||||
|
||||
/* whereToOpenLink() looks at an event to decide where to open a link.
|
||||
*
|
||||
* The event may be a mouse event (click, double-click, middle-click) or keypress event (enter).
|
||||
*
|
||||
* On Windows, the modifiers are:
|
||||
* Ctrl new tab, selected
|
||||
* Shift new window
|
||||
* Ctrl+Shift new tab, in background
|
||||
* Alt save
|
||||
*
|
||||
* You can swap Ctrl and Ctrl+shift by toggling the hidden pref
|
||||
* browser.tabs.loadBookmarksInBackground (not browser.tabs.loadInBackground, which
|
||||
* is for content area links).
|
||||
*
|
||||
* Middle-clicking is the same as Ctrl+clicking (it opens a new tab) and it is
|
||||
* subject to the shift modifier and pref in the same way.
|
||||
*
|
||||
* Exceptions:
|
||||
* - Alt is ignored for menu items selected using the keyboard so you don't accidentally save stuff.
|
||||
* (Currently, the Alt isn't sent here at all for menu items, but that will change in bug 126189.)
|
||||
* - Alt is hard to use in context menus, because pressing Alt closes the menu.
|
||||
* - Alt can't be used on the bookmarks toolbar because Alt is used for "treat this as something draggable".
|
||||
* - The button is ignored for the middle-click-paste-URL feature, since it's always a middle-click.
|
||||
*/
|
||||
function whereToOpenLink( e, ignoreButton, ignoreAlt )
|
||||
{
|
||||
if (e == null)
|
||||
e = { shiftKey:false, ctrlKey:false, metaKey:false, altKey:false, button:0 };
|
||||
|
||||
var shift = e.shiftKey;
|
||||
var ctrl = e.ctrlKey;
|
||||
var meta = e.metaKey;
|
||||
var alt = e.altKey && !ignoreAlt;
|
||||
|
||||
// ignoreButton allows "middle-click paste" to use function without always opening in a new window.
|
||||
var middle = !ignoreButton && e.button == 1;
|
||||
var middleUsesTabs = getBoolPref("browser.tabs.opentabfor.middleclick", true);
|
||||
|
||||
// Don't do anything special with right-mouse clicks. They're probably clicks on context menu items.
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
if (meta || (middle && middleUsesTabs)) {
|
||||
#else
|
||||
if (ctrl || (middle && middleUsesTabs)) {
|
||||
#endif
|
||||
if (shift)
|
||||
return "tabshifted";
|
||||
else
|
||||
return "tab";
|
||||
}
|
||||
else if (alt) {
|
||||
return "save";
|
||||
}
|
||||
else if (shift || (middle && !middleUsesTabs)) {
|
||||
return "window";
|
||||
}
|
||||
else {
|
||||
return "current";
|
||||
}
|
||||
}
|
||||
|
||||
/* openUILinkIn opens a URL in a place specified by the parameter |where|.
|
||||
*
|
||||
* |where| can be:
|
||||
* "current" current tab (if there aren't any browser windows, then in a new window instead)
|
||||
* "tab" new tab (if there aren't any browser windows, then in a new window instead)
|
||||
* "tabshifted" same as "tab" but in background if default is to select new tabs, and vice versa
|
||||
* "window" new window
|
||||
* "save" save to disk (with no filename hint!)
|
||||
*/
|
||||
function openUILinkIn( url, where )
|
||||
{
|
||||
if (!where)
|
||||
return;
|
||||
|
||||
if ((url == null) || (url == ""))
|
||||
return;
|
||||
// xlate the URL if necessary
|
||||
if (url.indexOf("urn:") == 0) {
|
||||
url = xlateURL(url); // does RDF urn expansion
|
||||
}
|
||||
// avoid loading "", since this loads a directory listing
|
||||
if (url == "") {
|
||||
url = "about:blank";
|
||||
}
|
||||
|
||||
if (where == "save") {
|
||||
saveURL(url, null, null, true);
|
||||
return;
|
||||
}
|
||||
|
||||
var w = (where == "window") ? null : getTopWin();
|
||||
if (!w) {
|
||||
openDialog(getBrowserURL(), "_blank", "chrome,all,dialog=no", url);
|
||||
return;
|
||||
}
|
||||
var browser = w.document.getElementById("content");
|
||||
|
||||
switch (where) {
|
||||
case "current":
|
||||
browser.loadURI(url);
|
||||
w.content.focus();
|
||||
break;
|
||||
case "tabshifted":
|
||||
case "tab":
|
||||
var tab = browser.addTab(url);
|
||||
|
||||
// We check the pref here, rather than in whereToOpenLink, because an "open link in tab"
|
||||
// context menu item could call openUILinkwhere directly.
|
||||
if ((where == "tab") ^ getBoolPref("browser.tabs.loadBookmarksInBackground", false)) {
|
||||
browser.selectedTab = tab;
|
||||
w.content.focus();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Used as an onclick handler for UI elements with link-like behavior.
|
||||
// e.g. onclick="checkForMiddleClick(this, event);"
|
||||
function checkForMiddleClick(node, event)
|
||||
{
|
||||
if (event.button == 1) {
|
||||
/* Execute the node's oncommand.
|
||||
*
|
||||
* Using eval() because of bug 246720. Would like to use node.oncommand(event).
|
||||
*
|
||||
* Since we're using eval():
|
||||
*
|
||||
* |event| is correct because the name of this function's formal parameter matches
|
||||
* the automatic name of the formal parameter for oncommand, |event|.
|
||||
*
|
||||
* |this| is incorrect. To make it correct, we would have to use Function.call.
|
||||
*/
|
||||
eval(node.getAttribute("oncommand"));
|
||||
|
||||
// If the middle-click was on part of a menu, close the menu.
|
||||
// (Menus close automatically with left-click but not with middle-click.)
|
||||
closeMenus(event.target);
|
||||
}
|
||||
}
|
||||
|
||||
// Closes all popups that are ancestors of the node.
|
||||
function closeMenus(node)
|
||||
{
|
||||
if ("tagName" in node) {
|
||||
if (node.namespaceURI == "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
&& (node.tagName == "menupopup" || node.tagName == "popup"))
|
||||
node.hidePopup();
|
||||
|
||||
closeMenus(node.parentNode);
|
||||
}
|
||||
}
|
||||
|
||||
// update menu items that rely on focus
|
||||
function goUpdateGlobalEditMenuItems()
|
||||
{
|
||||
goUpdateCommand('cmd_undo');
|
||||
goUpdateCommand('cmd_redo');
|
||||
goUpdateCommand('cmd_cut');
|
||||
goUpdateCommand('cmd_copy');
|
||||
goUpdateCommand('cmd_paste');
|
||||
goUpdateCommand('cmd_selectAll');
|
||||
goUpdateCommand('cmd_delete');
|
||||
if (gBidiUI)
|
||||
goUpdateCommand('cmd_switchTextDirection');
|
||||
}
|
||||
|
||||
// update menu items that rely on the current selection
|
||||
function goUpdateSelectEditMenuItems()
|
||||
{
|
||||
goUpdateCommand('cmd_cut');
|
||||
goUpdateCommand('cmd_copy');
|
||||
goUpdateCommand('cmd_delete');
|
||||
goUpdateCommand('cmd_selectAll');
|
||||
}
|
||||
|
||||
// update menu items that relate to undo/redo
|
||||
function goUpdateUndoEditMenuItems()
|
||||
{
|
||||
goUpdateCommand('cmd_undo');
|
||||
goUpdateCommand('cmd_redo');
|
||||
}
|
||||
|
||||
// update menu items that depend on clipboard contents
|
||||
function goUpdatePasteMenuItems()
|
||||
{
|
||||
goUpdateCommand('cmd_paste');
|
||||
}
|
||||
|
||||
// Gather all descendent text under given document node.
|
||||
function gatherTextUnder ( root )
|
||||
{
|
||||
var text = "";
|
||||
var node = root.firstChild;
|
||||
var depth = 1;
|
||||
while ( node && depth > 0 ) {
|
||||
// See if this node is text.
|
||||
if ( node.nodeType == Node.TEXT_NODE ) {
|
||||
// Add this text to our collection.
|
||||
text += " " + node.data;
|
||||
} else if ( node instanceof HTMLImageElement) {
|
||||
// If it has an alt= attribute, use that.
|
||||
var altText = node.getAttribute( "alt" );
|
||||
if ( altText && altText != "" ) {
|
||||
text = altText;
|
||||
break;
|
||||
}
|
||||
}
|
||||
// Find next node to test.
|
||||
// First, see if this node has children.
|
||||
if ( node.hasChildNodes() ) {
|
||||
// Go to first child.
|
||||
node = node.firstChild;
|
||||
depth++;
|
||||
} else {
|
||||
// No children, try next sibling.
|
||||
if ( node.nextSibling ) {
|
||||
node = node.nextSibling;
|
||||
} else {
|
||||
// Last resort is our next oldest uncle/aunt.
|
||||
node = node.parentNode.nextSibling;
|
||||
depth--;
|
||||
}
|
||||
}
|
||||
}
|
||||
// Strip leading whitespace.
|
||||
text = text.replace( /^\s+/, "" );
|
||||
// Strip trailing whitespace.
|
||||
text = text.replace( /\s+$/, "" );
|
||||
// Compress remaining whitespace.
|
||||
text = text.replace( /\s+/g, " " );
|
||||
return text;
|
||||
}
|
||||
|
||||
function getShellService()
|
||||
{
|
||||
var shell = null;
|
||||
try {
|
||||
shell = Components.classes["@mozilla.org/browser/shell-service;1"]
|
||||
.getService(Components.interfaces.nsIShellService);
|
||||
} catch (e) {dump("*** e = " + e + "\n");}
|
||||
return shell;
|
||||
}
|
||||
|
||||
function isBidiEnabled() {
|
||||
var rv = false;
|
||||
|
||||
try {
|
||||
var localeService = Components.classes["@mozilla.org/intl/nslocaleservice;1"]
|
||||
.getService(Components.interfaces.nsILocaleService);
|
||||
var systemLocale = localeService.getSystemLocale().getCategory("NSILOCALE_CTYPE").substr(0,3);
|
||||
|
||||
switch (systemLocale) {
|
||||
case "ar-":
|
||||
case "he-":
|
||||
case "fa-":
|
||||
case "ur-":
|
||||
case "syr":
|
||||
rv = true;
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
// check the overriding pref
|
||||
if (!rv)
|
||||
rv = getBoolPref("bidi.browser.ui");
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
function openAboutDialog()
|
||||
{
|
||||
#ifdef XP_MACOSX
|
||||
var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
|
||||
.getService(Components.interfaces.nsIWindowMediator);
|
||||
var win = wm.getMostRecentWindow("Browser:About");
|
||||
if (win)
|
||||
win.focus();
|
||||
else {
|
||||
// XXXmano: define minimizable=no although it does nothing on OS X
|
||||
// (see Bug 287162); remove this comment once Bug 287162 is fixed...
|
||||
window.open("chrome://browser/content/aboutDialog.xul", "About",
|
||||
"chrome, resizable=no, minimizable=no");
|
||||
}
|
||||
#else
|
||||
window.openDialog("chrome://browser/content/aboutDialog.xul", "About", "modal,centerscreen,chrome,resizable=no");
|
||||
#endif
|
||||
}
|
||||
|
||||
function openPreferences(paneID)
|
||||
{
|
||||
var instantApply = getBoolPref("browser.preferences.instantApply", false);
|
||||
var features = "chrome,titlebar,toolbar,centerscreen" + (instantApply ? ",dialog=no" : ",modal");
|
||||
|
||||
var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
|
||||
.getService(Components.interfaces.nsIWindowMediator);
|
||||
var win = wm.getMostRecentWindow("Browser:Preferences");
|
||||
if (win) {
|
||||
win.focus();
|
||||
if (paneID) {
|
||||
var pane = win.document.getElementById(paneID);
|
||||
win.document.documentElement.showPane(pane);
|
||||
}
|
||||
}
|
||||
else
|
||||
openDialog("chrome://browser/content/preferences/preferences.xul",
|
||||
"Preferences", features, paneID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Opens the release notes page for this version of the application.
|
||||
* @param event
|
||||
* The DOM Event that caused this function to be called, used to
|
||||
* determine where the release notes page should be displayed based
|
||||
* on modifiers (e.g. Ctrl = new tab)
|
||||
*/
|
||||
function openReleaseNotes(event)
|
||||
{
|
||||
var appInfo = Components.classes["@mozilla.org/xre/app-info;1"]
|
||||
.getService(Components.interfaces.nsIXULAppInfo);
|
||||
var regionBundle = document.getElementById("bundle_browser_region");
|
||||
var relnotesURL = regionBundle.getFormattedString("releaseNotesURL", [appInfo.version]);
|
||||
openUILink(relnotesURL, event, false, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* Opens the update manager and checks for updates to the application.
|
||||
*/
|
||||
function checkForUpdates()
|
||||
{
|
||||
var um =
|
||||
Components.classes["@mozilla.org/updates/update-manager;1"].
|
||||
getService(Components.interfaces.nsIUpdateManager);
|
||||
var prompter =
|
||||
Components.classes["@mozilla.org/updates/update-prompt;1"].
|
||||
createInstance(Components.interfaces.nsIUpdatePrompt);
|
||||
|
||||
// If there's an update ready to be applied, show the "Update Downloaded"
|
||||
// UI instead and let the user know they have to restart the browser for
|
||||
// the changes to be applied.
|
||||
if (um.activeUpdate && um.activeUpdate.state == "pending")
|
||||
prompter.showUpdateDownloaded(um.activeUpdate);
|
||||
else
|
||||
prompter.checkForUpdates();
|
||||
}
|
||||
|
||||
function buildHelpMenu()
|
||||
{
|
||||
var updates =
|
||||
Components.classes["@mozilla.org/updates/update-service;1"].
|
||||
getService(Components.interfaces.nsIApplicationUpdateService);
|
||||
var um =
|
||||
Components.classes["@mozilla.org/updates/update-manager;1"].
|
||||
getService(Components.interfaces.nsIUpdateManager);
|
||||
|
||||
// Disable the UI if the update enabled pref has been locked by the
|
||||
// administrator or if we cannot update for some other reason
|
||||
var checkForUpdates = document.getElementById("checkForUpdates");
|
||||
var canUpdate = updates.canUpdate;
|
||||
checkForUpdates.setAttribute("disabled", !canUpdate);
|
||||
if (!canUpdate)
|
||||
return;
|
||||
|
||||
var strings = document.getElementById("bundle_browser");
|
||||
var activeUpdate = um.activeUpdate;
|
||||
|
||||
// If there's an active update, substitute its name into the label
|
||||
// we show for this item, otherwise display a generic label.
|
||||
function getStringWithUpdateName(key) {
|
||||
if (activeUpdate && activeUpdate.name)
|
||||
return strings.getFormattedString(key, [activeUpdate.name]);
|
||||
return strings.getString(key + "Fallback");
|
||||
}
|
||||
|
||||
// By default, show "Check for Updates..."
|
||||
var key = "default";
|
||||
if (activeUpdate) {
|
||||
switch (activeUpdate.state) {
|
||||
case "downloading":
|
||||
// If we're downloading an update at present, show the text:
|
||||
// "Downloading Firefox x.x..." otherwise we're paused, and show
|
||||
// "Resume Downloading Firefox x.x..."
|
||||
key = updates.isDownloading ? "downloading" : "resume";
|
||||
break;
|
||||
case "pending":
|
||||
// If we're waiting for the user to restart, show: "Apply Downloaded
|
||||
// Updates Now..."
|
||||
key = "pending";
|
||||
break;
|
||||
}
|
||||
}
|
||||
checkForUpdates.label = getStringWithUpdateName("updatesItem_" + key);
|
||||
if (um.activeUpdate && updates.isDownloading)
|
||||
checkForUpdates.setAttribute("loading", "true");
|
||||
else
|
||||
checkForUpdates.removeAttribute("loading");
|
||||
}
|
||||
|
||||
@@ -1,58 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<overlay id="viewSourceOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/baseMenuOverlay.xul"?>
|
||||
|
||||
<window id="viewSource">
|
||||
<commandset id="baseMenuCommandSet"/>
|
||||
<keyset id="baseMenuKeyset"/>
|
||||
<stringbundleset id="stringbundleset"/>
|
||||
</window>
|
||||
|
||||
<menubar id="viewSource-main-menubar">
|
||||
#ifdef XP_MACOSX
|
||||
<menu id="windowMenu"/>
|
||||
<menupopup id="menu_ToolsPopup"/>
|
||||
#endif
|
||||
<menu id="helpMenu"/>
|
||||
</menubar>
|
||||
|
||||
</overlay>
|
||||
@@ -1,109 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# David Hyatt.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt <hyatt@mozilla.org>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
var panelProgressListener = {
|
||||
onProgressChange : function (aWebProgress, aRequest,
|
||||
aCurSelfProgress, aMaxSelfProgress,
|
||||
aCurTotalProgress, aMaxTotalProgress) {
|
||||
},
|
||||
|
||||
onStateChange : function(aWebProgress, aRequest, aStateFlags, aStatus)
|
||||
{
|
||||
if (!aRequest)
|
||||
return;
|
||||
|
||||
//ignore local/resource:/chrome: files
|
||||
if (aStatus == NS_NET_STATUS_READ_FROM || aStatus == NS_NET_STATUS_WROTE_TO)
|
||||
return;
|
||||
|
||||
const nsIWebProgressListener = Components.interfaces.nsIWebProgressListener;
|
||||
const nsIChannel = Components.interfaces.nsIChannel;
|
||||
if (aStateFlags & nsIWebProgressListener.STATE_START &&
|
||||
aStateFlags & nsIWebProgressListener.STATE_IS_NETWORK) {
|
||||
window.parent.document.getElementById('sidebar-throbber').setAttribute("loading", "true");
|
||||
}
|
||||
else if (aStateFlags & nsIWebProgressListener.STATE_STOP &&
|
||||
aStateFlags & nsIWebProgressListener.STATE_IS_NETWORK) {
|
||||
window.parent.document.getElementById('sidebar-throbber').removeAttribute("loading");
|
||||
}
|
||||
}
|
||||
,
|
||||
|
||||
onLocationChange : function(aWebProgress, aRequest, aLocation) {
|
||||
},
|
||||
|
||||
onStatusChange : function(aWebProgress, aRequest, aStatus, aMessage) {
|
||||
},
|
||||
|
||||
onSecurityChange : function(aWebProgress, aRequest, aState) {
|
||||
},
|
||||
|
||||
QueryInterface : function(aIID)
|
||||
{
|
||||
if (aIID.equals(Components.interfaces.nsIWebProgressListener) ||
|
||||
aIID.equals(Components.interfaces.nsISupportsWeakReference) ||
|
||||
aIID.equals(Components.interfaces.nsISupports))
|
||||
return this;
|
||||
throw Components.results.NS_NOINTERFACE;
|
||||
}
|
||||
};
|
||||
|
||||
var gLoadFired = false;
|
||||
function loadWebPanel(aURI) {
|
||||
var panelBrowser = document.getElementById('web-panels-browser');
|
||||
if (gLoadFired)
|
||||
panelBrowser.webNavigation.loadURI(aURI, nsIWebNavigation.LOAD_FLAGS_NONE, null, null, null);
|
||||
panelBrowser.setAttribute("cachedurl", aURI);
|
||||
}
|
||||
|
||||
function load()
|
||||
{
|
||||
var panelBrowser = document.getElementById('web-panels-browser');
|
||||
panelBrowser.webProgress.addProgressListener(panelProgressListener, Components.interfaces.nsIWebProgress.NOTIFY_ALL);
|
||||
if (panelBrowser.getAttribute("cachedurl"))
|
||||
panelBrowser.webNavigation.loadURI(panelBrowser.getAttribute("cachedurl"), nsIWebNavigation.LOAD_FLAGS_NONE, null, null, null);
|
||||
gNavigatorBundle = document.getElementById("bundle_browser");
|
||||
|
||||
gLoadFired = true;
|
||||
}
|
||||
|
||||
function unload()
|
||||
{
|
||||
var panelBrowser = document.getElementById('web-panels-browser');
|
||||
panelBrowser.webProgress.removeProgressListener(panelProgressListener);
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org Code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# David Hyatt.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2001
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# David Hyatt <hyatt@mozilla.org>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://browser/skin/" type="text/css"?>
|
||||
|
||||
<!DOCTYPE window SYSTEM "chrome://browser/locale/browser.dtd">
|
||||
|
||||
<page id="webpanels-window"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
onload="load()" onunload="unload()">
|
||||
<script type="application/x-javascript" src="chrome://global/content/nsTransferable.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/nsDragAndDrop.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/utilityOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://global/content/contentAreaUtils.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/browser.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/web-panels.js"/>
|
||||
|
||||
<stringbundleset id="stringbundleset">
|
||||
<stringbundle id="bundle_browser" src="chrome://browser/locale/browser.properties"/>
|
||||
</stringbundleset>
|
||||
|
||||
<popupset id="mainPopupSet">
|
||||
#include browser-context.inc
|
||||
</popupset>
|
||||
|
||||
|
||||
<browser id="web-panels-browser" persist="cachedurl" type="content" flex="1"
|
||||
context="contentAreaContextMenu"
|
||||
onclick="return window.parent.contentAreaClick(event, true);"/>
|
||||
</page>
|
||||
@@ -1,63 +0,0 @@
|
||||
browser.jar:
|
||||
% content browser %content/browser/ xpcnativewrappers=yes
|
||||
% overlay chrome://browser/content/pageInfo.xul chrome://pippki/content/PageInfoOverlay.xul
|
||||
#ifdef XP_MACOSX
|
||||
% overlay chrome://mozapps/content/downloads/downloads.xul chrome://browser/content/downloadManagerOverlay.xul
|
||||
% overlay chrome://mozapps/content/extensions/extensions.xul?type=extensions chrome://browser/content/extensionsManagerOverlay.xul
|
||||
% overlay chrome://mozapps/content/extensions/extensions.xul?type=themes chrome://browser/content/extensionsManagerOverlay.xul
|
||||
% overlay chrome://global/content/console.xul chrome://browser/content/jsConsoleOverlay.xul
|
||||
% overlay chrome://mozapps/content/update/updates.xul chrome://browser/content/softwareUpdateOverlay.xul
|
||||
#endif
|
||||
% overlay chrome://global/content/viewSource.xul chrome://browser/content/viewSourceOverlay.xul
|
||||
% overlay chrome://global/content/viewPartialSource.xul chrome://browser/content/viewSourceOverlay.xul
|
||||
* content/browser/aboutDialog.xul (content/aboutDialog.xul)
|
||||
* content/browser/aboutDialog.js (content/aboutDialog.js)
|
||||
* content/browser/aboutDialog.css (content/aboutDialog.css)
|
||||
content/browser/browser.css (content/browser.css)
|
||||
* content/browser/browser.js (content/browser.js)
|
||||
* content/browser/browser.xul (content/browser.xul)
|
||||
* content/browser/credits.xhtml (content/credits.xhtml)
|
||||
* content/browser/metaData.js (content/metaData.js)
|
||||
* content/browser/metaData.xul (content/metaData.xul)
|
||||
content/browser/monitor.png (content/monitor.png)
|
||||
* content/browser/openLocation.js (content/openLocation.js)
|
||||
* content/browser/openLocation.xul (content/openLocation.xul)
|
||||
* content/browser/pageInfo.js (content/pageInfo.js)
|
||||
* content/browser/pageInfo.xul (content/pageInfo.xul)
|
||||
* content/browser/pageReport.js (content/pageReport.js)
|
||||
* content/browser/pageReport.xul (content/pageReport.xul)
|
||||
* content/browser/pageReportFirstTime.xul (content/pageReportFirstTime.xul)
|
||||
* content/browser/safeMode.js (content/safeMode.js)
|
||||
* content/browser/safeMode.xul (content/safeMode.xul)
|
||||
* content/browser/sanitize.js (content/sanitize.js)
|
||||
* content/browser/sanitize.xul (content/sanitize.xul)
|
||||
* content/browser/search.xml (content/search.xml)
|
||||
* content/browser/searchDialog.js (content/searchDialog.js)
|
||||
* content/browser/searchDialog.xul (content/searchDialog.xul)
|
||||
* content/browser/searchDialog.css (content/searchDialog.css)
|
||||
* content/browser/searchbarBindings.css (content/searchbarBindings.css)
|
||||
* content/browser/utilityOverlay.js (content/utilityOverlay.js)
|
||||
* content/browser/web-panels.js (content/web-panels.js)
|
||||
* content/browser/web-panels.xul (content/web-panels.xul)
|
||||
* content/browser/baseMenuOverlay.xul (content/baseMenuOverlay.xul)
|
||||
# XXX: We should exclude this one as well (bug 71895)
|
||||
* content/browser/hiddenWindow.xul (content/hiddenWindow.xul)
|
||||
#ifdef XP_MACOSX
|
||||
* content/browser/macBrowserOverlay.xul (content/macBrowserOverlay.xul)
|
||||
* content/browser/downloadManagerOverlay.xul (content/downloadManagerOverlay.xul)
|
||||
* content/browser/extensionsManagerOverlay.xul (content/extensionsManagerOverlay.xul)
|
||||
* content/browser/jsConsoleOverlay.xul (content/jsConsoleOverlay.xul)
|
||||
* content/browser/softwareUpdateOverlay.xul (content/softwareUpdateOverlay.xul)
|
||||
#endif
|
||||
* content/browser/viewSourceOverlay.xul (content/viewSourceOverlay.xul)
|
||||
#ifdef MOZ_USE_GENERIC_BRANDING
|
||||
% content branding %content/branding/ xpcnativewrappers=yes
|
||||
content/branding/about.png (branding/about.png)
|
||||
content/branding/aboutCredits.png (branding/aboutCredits.png)
|
||||
content/branding/aboutFooter.png (branding/aboutFooter.png)
|
||||
content/branding/searchconfig.properties (branding/searchconfig.properties)
|
||||
content/branding/icon64.png (branding/icon64.png)
|
||||
#ifdef XP_WIN
|
||||
content/branding/uninstall.properties (branding/uninstall.properties)
|
||||
#endif
|
||||
#endif
|
||||
@@ -1,69 +0,0 @@
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is the Mozilla Browser code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2002
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Brian Ryner <bryner@brianryner.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE = browsercomps
|
||||
XPIDL_MODULE = browsercompsbase
|
||||
|
||||
XPIDLSRCS = \
|
||||
nsIBrowserHandler.idl \
|
||||
nsIBrowserGlue.idl \
|
||||
$(NULL)
|
||||
|
||||
EXTRA_PP_COMPONENTS = \
|
||||
nsBrowserContentHandler.js \
|
||||
nsBrowserGlue.js \
|
||||
$(NULL)
|
||||
|
||||
DIRS = \
|
||||
bookmarks \
|
||||
dirprovider \
|
||||
migration \
|
||||
history \
|
||||
preferences \
|
||||
shell \
|
||||
sidebar \
|
||||
build \
|
||||
$(NULL)
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
@@ -1,48 +0,0 @@
|
||||
#
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
DIRS = public src
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
@@ -1,264 +0,0 @@
|
||||
/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Ben Goodger <ben@netscape.com> (Original Author)
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
/**
|
||||
* Add Bookmark Dialog.
|
||||
* ====================
|
||||
*
|
||||
* This is a generic bookmark dialog that allows for bookmark addition
|
||||
* and folder selection. It can be opened with various parameters that
|
||||
* result in appearance/purpose differences and initial state.
|
||||
*
|
||||
* Use: Open with 'openDialog', with the flags
|
||||
* 'centerscreen,chrome,dialog=no,resizable=yes'
|
||||
*
|
||||
* Parameters:
|
||||
* Apart from the standard openDialog parameters, this dialog can
|
||||
* be passed additional information, which gets mapped to the
|
||||
* window.arguments array:
|
||||
*
|
||||
* window.arguments[0]: Bookmark Name. The value to be prefilled
|
||||
* into the "Name: " field (if visible).
|
||||
* window.arguments[1]: Bookmark URL: The location of the bookmark.
|
||||
* The value to be filled in the "Location: "
|
||||
* field (if visible).
|
||||
* window.arguments[2]: Bookmark Folder. The RDF Resource URI of the
|
||||
* folder that this bookmark should be created in.
|
||||
* window.arguments[3]: Bookmark Charset. The charset that should be
|
||||
* used when adding a bookmark to the specified
|
||||
* URL. (Usually the charset of the current
|
||||
* document when launching this window).
|
||||
* window.arguments[4]: The mode of operation. See notes for details.
|
||||
* window.arguments[6]: If the bookmark should become a web panel.
|
||||
*
|
||||
* Mode of Operation Notes:
|
||||
* ------------------------
|
||||
* This dialog can be opened in four different ways by using a parameter
|
||||
* passed through the call to openDialog. The 'mode' of operation
|
||||
* of the window is expressed in window.arguments[4]. The valid modes are:
|
||||
*
|
||||
* 1) <default> (no fifth open parameter).
|
||||
* Opens this dialog with the bookmark Name, URL and folder selection
|
||||
* components visible.
|
||||
* 2) "newBookmark" (fifth open parameter = String("newBookmark"))
|
||||
* Opens the dialog as in (1) above except the folder selection tree
|
||||
* is hidden. This type of mode is useful when the creation folder
|
||||
* is pre-determined.
|
||||
* 3) "selectFolder" (fifth open parameter = String("selectFolder"))
|
||||
* Opens the dialog as in (1) above except the Name/Location section
|
||||
* is hidden, and the dialog takes on the utility of a Folder chooser.
|
||||
* Used when the user must select a Folder for some purpose.
|
||||
*/
|
||||
|
||||
var gFld_Name = null;
|
||||
var gFld_URL = null;
|
||||
var gFolderTree = null;
|
||||
|
||||
var gBookmarkCharset = null;
|
||||
|
||||
var gSelectItemObserver = null;
|
||||
|
||||
var gCreateInFolder = "NC:NewBookmarkFolder";
|
||||
|
||||
function Startup()
|
||||
{
|
||||
initServices();
|
||||
initBMService();
|
||||
gFld_Name = document.getElementById("name");
|
||||
gFld_URL = document.getElementById("url");
|
||||
var bookmarkView = document.getElementById("bookmarks-view");
|
||||
|
||||
var shouldSetOKButton = true;
|
||||
if ("arguments" in window) {
|
||||
var ind;
|
||||
var folderItem = null;
|
||||
var arg;
|
||||
if (window.arguments.length < 5)
|
||||
arg = null;
|
||||
else
|
||||
arg = window.arguments[4];
|
||||
switch (arg) {
|
||||
case "selectFolder":
|
||||
// If we're being opened as a folder selection window
|
||||
document.getElementById("bookmarknamegrid").setAttribute("hidden", "true");
|
||||
document.getElementById("createinseparator").setAttribute("hidden", "true");
|
||||
document.getElementById("nameseparator").setAttribute("hidden", "true");
|
||||
sizeToFit();
|
||||
document.title = document.documentElement.getAttribute("title-selectFolder");
|
||||
shouldSetOKButton = false;
|
||||
if (window.arguments[2])
|
||||
folderItem = RDF.GetResource(window.arguments[2]);
|
||||
if (folderItem) {
|
||||
ind = bookmarkView.treeBuilder.getIndexOfResource(folderItem);
|
||||
bookmarkView.treeBoxObject.view.selection.select(ind);
|
||||
}
|
||||
break;
|
||||
case "newBookmark":
|
||||
setupFields();
|
||||
if (window.arguments[2])
|
||||
gCreateInFolder = window.arguments[2];
|
||||
document.getElementById("folderbox").setAttribute("hidden", "true");
|
||||
sizeToFit();
|
||||
break;
|
||||
default:
|
||||
// Regular Add Bookmark
|
||||
setupFields();
|
||||
if (window.arguments[2]) {
|
||||
gCreateInFolder = window.arguments[2];
|
||||
folderItem = bookmarkView.rdf.GetResource(gCreateInFolder);
|
||||
if (folderItem) {
|
||||
ind = bookmarkView.treeBuilder.getIndexOfResource(folderItem);
|
||||
bookmarkView.treeBoxObject.view.selection.select(ind);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (shouldSetOKButton)
|
||||
onFieldInput();
|
||||
if (document.getElementById("bookmarknamegrid").hasAttribute("hidden")) {
|
||||
bookmarkView.tree.focus();
|
||||
if (bookmarkView.currentIndex == -1)
|
||||
bookmarkView.treeBoxObject.view.selection.select(0);
|
||||
}
|
||||
else {
|
||||
gFld_Name.select();
|
||||
gFld_Name.focus();
|
||||
}
|
||||
}
|
||||
|
||||
function sizeToFit()
|
||||
{
|
||||
var dialogElement = document.documentElement;
|
||||
dialogElement.removeAttribute("persist");
|
||||
dialogElement.removeAttribute("height");
|
||||
dialogElement.removeAttribute("width");
|
||||
dialogElement.setAttribute("style", dialogElement.getAttribute("style"));
|
||||
sizeToContent();
|
||||
}
|
||||
|
||||
function setupFields()
|
||||
{
|
||||
// New bookmark in predetermined folder.
|
||||
gFld_Name.value = window.arguments[0] || "";
|
||||
gFld_URL.value = window.arguments[1] || "";
|
||||
onFieldInput();
|
||||
gFld_Name.select();
|
||||
gFld_Name.focus();
|
||||
gBookmarkCharset = window.arguments[3] || null;
|
||||
}
|
||||
|
||||
function onFieldInput()
|
||||
{
|
||||
const ok = document.documentElement.getButton("accept");
|
||||
ok.disabled = gFld_URL.value == "" ||
|
||||
gFld_Name.value == "";
|
||||
}
|
||||
|
||||
function onOK()
|
||||
{
|
||||
if (!document.getElementById("folderbox").hasAttribute("hidden")) {
|
||||
var bookmarkView = document.getElementById("bookmarks-view");
|
||||
var currentIndex = bookmarkView.currentIndex;
|
||||
if (currentIndex != -1)
|
||||
gCreateInFolder = bookmarkView.treeBuilder.getResourceAtIndex(currentIndex).Value;
|
||||
}
|
||||
// In Select Folder Mode, do nothing but tell our caller what
|
||||
// folder was selected.
|
||||
if (window.arguments.length > 4 && window.arguments[4] == "selectFolder")
|
||||
window.arguments[5].target = BookmarksUtils.getTargetFromFolder(bookmarkView.treeBuilder.getResourceAtIndex(currentIndex));
|
||||
else {
|
||||
// Otherwise add a bookmark to the selected folder.
|
||||
var rFolder = RDF.GetResource(gCreateInFolder);
|
||||
try {
|
||||
RDFC.Init(BMDS, rFolder);
|
||||
}
|
||||
catch (e) {
|
||||
// No "NC:NewBookmarkFolder" exists, just append to the root.
|
||||
rFolder = RDF.GetResource("NC:BookmarksRoot");
|
||||
RDFC.Init(BMDS, rFolder);
|
||||
}
|
||||
|
||||
// if no URL was provided, do nothing
|
||||
if (!gFld_URL.value)
|
||||
return;
|
||||
|
||||
var url, rSource;
|
||||
|
||||
url = getNormalizedURL(gFld_URL.value);
|
||||
rSource = BMDS.createBookmark(gFld_Name.value, url, null, null, gBookmarkCharset, false, "");
|
||||
if (window.arguments.length > 4 && window.arguments[4] == "newBookmark") {
|
||||
window.arguments[5].newBookmark = rSource;
|
||||
}
|
||||
var selection = BookmarksUtils.getSelectionFromResource(rSource);
|
||||
var target = BookmarksUtils.getTargetFromFolder(rFolder);
|
||||
BookmarksUtils.insertAndCheckSelection("newbookmark", selection, target);
|
||||
}
|
||||
}
|
||||
|
||||
function getNormalizedURL(url)
|
||||
{
|
||||
// Check to see if the item is a local directory path, and if so, convert
|
||||
// to a file URL so that aggregation with rdf:files works
|
||||
try {
|
||||
const kLF = Components.classes["@mozilla.org/file/local;1"]
|
||||
.createInstance(Components.interfaces.nsILocalFile);
|
||||
kLF.initWithPath(url);
|
||||
if (kLF.exists()) {
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
var fileHandler = ioService.getProtocolHandler("file")
|
||||
.QueryInterface(Components.interfaces.nsIFileProtocolHandler);
|
||||
|
||||
url = fileHandler.getURLSpecFromFile(kLF);
|
||||
}
|
||||
}
|
||||
catch (e) {
|
||||
}
|
||||
|
||||
return url;
|
||||
}
|
||||
|
||||
function createNewFolder ()
|
||||
{
|
||||
var bookmarksView = document.getElementById("bookmarks-view");
|
||||
var resource = bookmarksView.treeBuilder.getResourceAtIndex(bookmarksView.currentIndex);
|
||||
var target = BookmarksUtils.getTargetFromFolder(resource);
|
||||
BookmarksCommand.createNewFolder(target);
|
||||
}
|
||||
|
||||
@@ -1,111 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- -*- Mode: HTML; indent-tabs-mode: nil; -*- -->
|
||||
<!--
|
||||
|
||||
***** BEGIN LICENSE BLOCK *****
|
||||
Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
|
||||
The contents of this file are subject to the Mozilla Public License Version
|
||||
1.1 (the "License"); you may not use this file except in compliance with
|
||||
the License. You may obtain a copy of the License at
|
||||
http://www.mozilla.org/MPL/
|
||||
|
||||
Software distributed under the License is distributed on an "AS IS" basis,
|
||||
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
for the specific language governing rights and limitations under the
|
||||
License.
|
||||
|
||||
The Original Code is mozilla.org code.
|
||||
|
||||
The Initial Developer of the Original Code is
|
||||
Netscape Communications Corporation.
|
||||
Portions created by the Initial Developer are Copyright (C) 1998
|
||||
the Initial Developer. All Rights Reserved.
|
||||
|
||||
Contributor(s):
|
||||
Ben Goodger <ben@netscape.com> (Original Author)
|
||||
|
||||
Alternatively, the contents of this file may be used under the terms of
|
||||
either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
of those above. If you wish to allow use of your version of this file only
|
||||
under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
use your version of this file under the terms of the MPL, indicate your
|
||||
decision by deleting the provisions above and replace them with the notice
|
||||
and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
the provisions above, a recipient may use your version of this file under
|
||||
the terms of any one of the MPL, the GPL or the LGPL.
|
||||
|
||||
***** END LICENSE BLOCK ***** -->
|
||||
|
||||
<?xml-stylesheet href="chrome://browser/skin/"?>
|
||||
<?xml-stylesheet href="chrome://browser/content/bookmarks/bookmarks.css"?>
|
||||
|
||||
<!DOCTYPE dialog SYSTEM "chrome://browser/locale/bookmarks/addBookmark.dtd">
|
||||
|
||||
<dialog id="newBookmarkDialog" style="width: 36em; height: 18em;"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
ondialogaccept="return onOK(event)"
|
||||
title="&newBookmark.title;" title-selectFolder="&selectFolder.label;"
|
||||
onload="Startup();"
|
||||
persist="screenX screenY width height"
|
||||
screenX="24" screenY="24">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/addBookmark.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/bookmarks.js"/>
|
||||
|
||||
<broadcaster id="showaddgroup" hidden="true"/>
|
||||
|
||||
<separator id="nameseparator" class="thin"/>
|
||||
|
||||
<grid id="bookmarknamegrid">
|
||||
<columns>
|
||||
<column/>
|
||||
<column flex="5"/>
|
||||
<column flex="1"/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row align="center">
|
||||
<label value="&name.label;" accesskey="&name.accesskey;" control="name"/>
|
||||
<textbox id="name" oninput="onFieldInput();"/>
|
||||
<spacer/>
|
||||
</row>
|
||||
<row>
|
||||
<separator class="thin"/>
|
||||
<separator class="thin"/>
|
||||
<spacer/>
|
||||
</row>
|
||||
<row align="center">
|
||||
<label value="&url.label;" accesskey="&url.accesskey;" control="url"/>
|
||||
<textbox id="url" oninput="onFieldInput();"/>
|
||||
<spacer/>
|
||||
</row>
|
||||
<row observes="showaddgroup">
|
||||
<separator class="thin"/>
|
||||
<separator class="thin"/>
|
||||
<spacer/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
|
||||
<separator id="createinseparator"/>
|
||||
|
||||
<vbox id="folderbox" flex="1">
|
||||
<separator/>
|
||||
<hbox flex="1">
|
||||
<label id="movetolabel" value="&moveto.label;"/>
|
||||
<hbox flex="1">
|
||||
<bookmarks-tree id="bookmarks-view" flex="1" type="folders"/>
|
||||
<vbox>
|
||||
<button label="&button.newfolder.label;" accesskey="&button.newfolder.accesskey;"
|
||||
oncommand="createNewFolder();" icon="open"/>
|
||||
</vbox>
|
||||
</hbox>
|
||||
</hbox>
|
||||
</vbox>
|
||||
|
||||
<separator/>
|
||||
|
||||
</dialog>
|
||||
@@ -1,332 +0,0 @@
|
||||
# -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@netscape.com> (Original Author)
|
||||
# David Hyatt <hyatt@mozilla.org>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
/**
|
||||
* Add Bookmark Dialog.
|
||||
* ====================
|
||||
*
|
||||
* This is a generic bookmark dialog that allows for bookmark addition
|
||||
* and folder selection. It can be opened with various parameters that
|
||||
* result in appearance/purpose differences and initial state.
|
||||
*
|
||||
* Use: Open with 'openDialog', with the flags
|
||||
* 'centerscreen,chrome,dialog=no,resizable=yes'
|
||||
*
|
||||
* Parameters:
|
||||
* Apart from the standard openDialog parameters, this dialog can
|
||||
* be passed additional information, which is contained in the
|
||||
* wArg object:
|
||||
*
|
||||
* wArg.name : Bookmark Name. The value to be prefilled
|
||||
* into the "Name: " field (if visible).
|
||||
* wArg.description : Bookmark description. The value to be added
|
||||
* : to the boomarks description field.
|
||||
* wArg.url : Bookmark URL: The location of the bookmark.
|
||||
* The value to be filled in the "Location: "
|
||||
* field (if visible).
|
||||
* wArg.folderURI : Bookmark Folder. The RDF Resource URI of the
|
||||
* folder that this bookmark should be created in.
|
||||
* wArg.charset : Bookmark Charset. The charset that should be
|
||||
* used when adding a bookmark to the specified
|
||||
* URL. (Usually the charset of the current
|
||||
* document when launching this window).
|
||||
* wArg.bBookmarkAllTabs : True if "Bookmark All Tabs" option is chosen,
|
||||
* false otherwise.
|
||||
* wArg.objGroup[] : If adding a group of tabs, this is an array
|
||||
* of wArg objects with name, URL and charset
|
||||
* properties, one for each group member.
|
||||
* wArg.bWebPanel : If the bookmark should become a web panel.
|
||||
* wArg.keyword : A suggested keyword for the bookmark. If this
|
||||
* argument is supplied, the keyword row is made
|
||||
* visible.
|
||||
* wArg.bNeedKeyword : Whether or not a keyword is required to add
|
||||
* the bookmark.
|
||||
* wArg.postData : PostData to be saved with this bookmark,
|
||||
* in the format a string of name=value pairs
|
||||
* separated by CRLFs.
|
||||
* wArg.feedURL : feed URL for Livemarks (turns bookmark
|
||||
* into Livemark)
|
||||
*/
|
||||
|
||||
var gSelectedFolder;
|
||||
var gName;
|
||||
var gKeyword;
|
||||
var gKeywordRow;
|
||||
var gExpander;
|
||||
var gMenulist;
|
||||
var gBookmarksTree;
|
||||
var gKeywordRequired;
|
||||
var gSuggestedKeyword;
|
||||
var gRequiredFields = [];
|
||||
var gPostData;
|
||||
var gArg = window.arguments[0];
|
||||
|
||||
# on windows, sizeToContent is buggy (see bug 227951), we''ll use resizeTo
|
||||
# instead and cache the bookmarks tree view size.
|
||||
var WSucks;
|
||||
|
||||
function Startup()
|
||||
{
|
||||
initServices();
|
||||
initBMService();
|
||||
gName = document.getElementById("name");
|
||||
gRequiredFields.push(gName);
|
||||
gKeywordRow = document.getElementById("keywordRow");
|
||||
gKeyword = document.getElementById("keyword");
|
||||
gExpander = document.getElementById("expander");
|
||||
gMenulist = document.getElementById("select-menu");
|
||||
gBookmarksTree = document.getElementById("folder-tree");
|
||||
gName.value = gArg.name;
|
||||
gName.select();
|
||||
gName.focus();
|
||||
gSuggestedKeyword = gArg.keyword;
|
||||
gKeywordRequired = gArg.bNeedKeyword;
|
||||
if (!gSuggestedKeyword && !gKeywordRequired) {
|
||||
gKeywordRow.hidden = true;
|
||||
} else {
|
||||
if (gSuggestedKeyword)
|
||||
gKeyword.value = gSuggestedKeyword;
|
||||
if (gKeywordRequired)
|
||||
gRequiredFields.push(gKeyword);
|
||||
}
|
||||
sizeToContent();
|
||||
onFieldInput();
|
||||
initTitle();
|
||||
gExpander.setAttribute("tooltiptext", gExpander.getAttribute("tooltiptextdown"));
|
||||
gPostData = gArg.postData;
|
||||
|
||||
if ("feedURL" in gArg) {
|
||||
var strings = document.getElementById("bookmarksBundle");
|
||||
document.title = strings.getString("addLiveBookmarkTitle");
|
||||
}
|
||||
|
||||
# read the persisted attribute. If it is not present, set a default height.
|
||||
WSucks = parseInt(gBookmarksTree.getAttribute("height"));
|
||||
if (!WSucks)
|
||||
WSucks = 150;
|
||||
|
||||
// fix no more persisted class attribute in old profiles
|
||||
var localStore = RDF.GetDataSource("rdf:local-store");
|
||||
var rAttribute = RDF.GetResource("class");
|
||||
var rElement = RDF.GetResource("chrome://browser/content/bookmarks/addBookmark2.xul#expander");
|
||||
var rDialog = RDF.GetResource("chrome://browser/content/bookmarks/addBookmark2.xul");
|
||||
var rPersist = RDF.GetResource(gNC_NS+"persist");
|
||||
|
||||
var rOldValue = localStore.GetTarget(rElement, rAttribute, true);
|
||||
if (rOldValue) {
|
||||
localStore.Unassert(rElement, rAttribute, rOldValue, true);
|
||||
localStore.Unassert(rDialog, rPersist, rElement, true);
|
||||
gExpander.setAttribute("class", "down");
|
||||
}
|
||||
|
||||
// Select the specified folder after the window is made visible
|
||||
function initMenulist() {
|
||||
if ("folderURI" in gArg) {
|
||||
var folderItem = document.getElementById(gArg.folderURI);
|
||||
if (folderItem)
|
||||
gMenulist.selectedItem = folderItem;
|
||||
}
|
||||
gSelectedFolder = RDF.GetResource(gMenulist.selectedItem.id);
|
||||
}
|
||||
setTimeout(initMenulist, 0);
|
||||
var btfMenuItem = document.getElementById("btfMenuItem");
|
||||
btfMenuItem.setAttribute("id", BMSVC.getBookmarksToolbarFolder().Value);
|
||||
}
|
||||
|
||||
function initTitle()
|
||||
{
|
||||
if(gArg.bBookmarkAllTabs)
|
||||
document.title = document.getElementById("bookmarksBundle").getString("bookmarkAllTabsTitle");
|
||||
else
|
||||
document.title = document.getElementById("bookmarksBundle").getString("bookmarkCurTabTitle");
|
||||
}
|
||||
|
||||
function onFieldInput()
|
||||
{
|
||||
var ok = document.documentElement.getButton("accept");
|
||||
ok.disabled = false;
|
||||
for (var i = 0; i < gRequiredFields.length; ++i) {
|
||||
if (gRequiredFields[i].value == "") {
|
||||
ok.disabled = true;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function onOK()
|
||||
{
|
||||
RDFC.Init(BMDS, gSelectedFolder);
|
||||
|
||||
var url, rSource;
|
||||
var livemarkFeed = gArg.feedURL;
|
||||
if (gArg.bBookmarkAllTabs) {
|
||||
rSource = BMDS.createFolder(gName.value);
|
||||
const groups = gArg.objGroup;
|
||||
for (var i = 0; i < groups.length; ++i) {
|
||||
url = getNormalizedURL(groups[i].url);
|
||||
BMDS.createBookmarkInContainer(groups[i].name, url, gKeyword.value,
|
||||
groups[i].description, groups[i].charset,
|
||||
gPostData, rSource, -1);
|
||||
}
|
||||
} else if (livemarkFeed != null) {
|
||||
url = getNormalizedURL(gArg.url);
|
||||
rSource = BMDS.createLivemark(gName.value, url, livemarkFeed,
|
||||
gArg.description);
|
||||
} else {
|
||||
url = getNormalizedURL(gArg.url);
|
||||
rSource = BMDS.createBookmark(gName.value, url, gKeyword.value,
|
||||
gArg.description, gArg.charset,
|
||||
gPostData);
|
||||
}
|
||||
|
||||
var selection = BookmarksUtils.getSelectionFromResource(rSource);
|
||||
var target = BookmarksUtils.getTargetFromFolder(gSelectedFolder);
|
||||
BookmarksUtils.insertAndCheckSelection("newbookmark", selection, target);
|
||||
|
||||
if (gArg.bWebPanel && rSource) {
|
||||
// Assert that we're a web panel.
|
||||
BMDS.Assert(rSource, RDF.GetResource(gNC_NS+"WebPanel"),
|
||||
RDF.GetLiteral("true"), true);
|
||||
}
|
||||
|
||||
// in insertSelection, the ds flush is delayed. It will never be performed,
|
||||
// since this dialog is destroyed before.
|
||||
// We have to flush manually
|
||||
var remoteDS = BMDS.QueryInterface(Components.interfaces.nsIRDFRemoteDataSource);
|
||||
remoteDS.Flush();
|
||||
}
|
||||
|
||||
function getNormalizedURL(url)
|
||||
{
|
||||
// Check to see if the item is a local directory path, and if so, convert
|
||||
// to a file URL so that aggregation with rdf:files works
|
||||
try {
|
||||
const kLF = Components.classes["@mozilla.org/file/local;1"]
|
||||
.createInstance(Components.interfaces.nsILocalFile);
|
||||
kLF.initWithPath(url);
|
||||
if (kLF.exists()) {
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
var fileHandler = ioService.getProtocolHandler("file")
|
||||
.QueryInterface(Components.interfaces.nsIFileProtocolHandler);
|
||||
|
||||
url = fileHandler.getURLSpecFromFile(kLF);
|
||||
}
|
||||
}
|
||||
catch (e) {
|
||||
}
|
||||
|
||||
return url;
|
||||
}
|
||||
|
||||
function selectMenulistFolder(aEvent)
|
||||
{
|
||||
gSelectedFolder = RDF.GetResource(aEvent.target.id);
|
||||
if (!gBookmarksTree.collapsed)
|
||||
selectFolder(gSelectedFolder);
|
||||
}
|
||||
|
||||
function selectTreeFolder()
|
||||
{
|
||||
var resource = gBookmarksTree.currentResource;
|
||||
if (resource == gSelectedFolder)
|
||||
return;
|
||||
gSelectedFolder = resource;
|
||||
var menuitem = document.getElementById(gSelectedFolder.Value);
|
||||
gMenulist.selectedItem = menuitem;
|
||||
if (!menuitem) {
|
||||
gMenulist.removeItemAt(gMenulist.firstChild.childNodes.length-1);
|
||||
var newItem = gMenulist.appendItem(BookmarksUtils.getProperty(gSelectedFolder, gNC_NS+"Name"), gSelectedFolder.Value);
|
||||
newItem.setAttribute("class", "menuitem-iconic folder-icon");
|
||||
newItem.setAttribute("id", gSelectedFolder.Value);
|
||||
gMenulist.selectedItem = newItem;
|
||||
}
|
||||
}
|
||||
|
||||
function selectFolder(aFolder)
|
||||
{
|
||||
gBookmarksTree.treeBoxObject.view.selection.selectEventsSuppressed = true;
|
||||
gBookmarksTree.treeBoxObject.view.selection.clearSelection();
|
||||
gBookmarksTree.selectResource(aFolder);
|
||||
var index = gBookmarksTree.currentIndex;
|
||||
gBookmarksTree.treeBoxObject.ensureRowIsVisible(index);
|
||||
gBookmarksTree.treeBoxObject.view.selection.selectEventsSuppressed = false;
|
||||
# triggers a select event that will provoke a call to selectTreeFolder()
|
||||
}
|
||||
|
||||
function expandTree()
|
||||
{
|
||||
setFolderTreeHeight();
|
||||
var willCollapse = !gBookmarksTree.collapsed;
|
||||
gExpander.setAttribute("class",willCollapse?"down":"up");
|
||||
gExpander.setAttribute("tooltiptext", gExpander.getAttribute("tooltiptext"+(willCollapse?"down":"up")));
|
||||
if (willCollapse) {
|
||||
document.documentElement.buttons = "accept,cancel";
|
||||
WSucks = gBookmarksTree.boxObject.height;
|
||||
} else {
|
||||
document.documentElement.buttons = "accept,cancel,extra2";
|
||||
# always open the bookmark root folder
|
||||
if (!gBookmarksTree.treeBoxObject.view.isContainerOpen(0))
|
||||
gBookmarksTree.treeBoxObject.view.toggleOpenState(0);
|
||||
selectFolder(gSelectedFolder);
|
||||
gBookmarksTree.focus();
|
||||
}
|
||||
gBookmarksTree.collapsed = willCollapse;
|
||||
resizeTo(window.outerWidth, window.outerHeight+(willCollapse?-WSucks:+WSucks));
|
||||
}
|
||||
|
||||
function setFolderTreeHeight()
|
||||
{
|
||||
var isCollapsed = gBookmarksTree.collapsed;
|
||||
if (!isCollapsed)
|
||||
gBookmarksTree.setAttribute("height", gBookmarksTree.boxObject.height);
|
||||
}
|
||||
|
||||
function newFolder()
|
||||
{
|
||||
gBookmarksTree.focus();
|
||||
// we should use goDoCommand, but the current way of inserting
|
||||
// resources do not insert in folders.
|
||||
//goDoCommand("cmd_bm_newfolder");
|
||||
var target = BookmarksUtils.getTargetFromFolder(gSelectedFolder);
|
||||
var folder = BookmarksCommand.createNewFolder(target);
|
||||
if (!BMSVC.isBookmarkedResource(folder))
|
||||
return; // new folder cancelled
|
||||
selectFolder(folder);
|
||||
}
|
||||
@@ -1,127 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
# -*- Mode: HTML; indent-tabs-mode: nil; -*- -->
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Netscape Communications Corporation.
|
||||
# Portions created by the Initial Developer are Copyright (C) 1998
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <ben@netscape.com> (Original Author)
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/"?>
|
||||
<?xml-stylesheet href="chrome://global/skin/arrow.css" type="text/css"?>
|
||||
<?xml-stylesheet href="chrome://browser/content/bookmarks/bookmarks.css"?>
|
||||
<?xml-stylesheet href="chrome://browser/skin/bookmarks/addBookmark.css"?>
|
||||
|
||||
<!DOCTYPE dialog [
|
||||
<!ENTITY % addBookmarkDTD SYSTEM "chrome://browser/locale/bookmarks/addBookmark.dtd">
|
||||
%addBookmarkDTD;
|
||||
<!ENTITY % bookmarksDTD SYSTEM "chrome://browser/locale/bookmarks/bookmarks.dtd">
|
||||
%bookmarksDTD;
|
||||
]>
|
||||
|
||||
<dialog id="addBookmarkDialog"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
ondialogextra2="newFolder()"
|
||||
ondialogaccept="return onOK(event)"
|
||||
buttons="accept,cancel"
|
||||
buttonlabelextra2="&button.newfolder.label;" buttonaccesskeyextra2="&button.newfolder.accesskey;"
|
||||
#ifdef XP_UNIX
|
||||
buttonlabelaccept="&acceptButton.label;"
|
||||
#endif
|
||||
buttoniconaccept="add"
|
||||
buttoniconextra2="open"
|
||||
title-selectFolder="&selectFolder.label;"
|
||||
onload="Startup();"
|
||||
onunload="setFolderTreeHeight();"
|
||||
persist="screenX screenY width">
|
||||
|
||||
<script type="application/x-javascript" src="chrome://global/content/globalOverlay.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/bookmarks.js"/>
|
||||
<script type="application/x-javascript" src="chrome://browser/content/bookmarks/addBookmark2.js"/>
|
||||
|
||||
<stringbundle id="bookmarksBundle"
|
||||
src="chrome://browser/locale/bookmarks/bookmarks.properties"/>
|
||||
|
||||
<separator id="nameseparator" class="thin"/>
|
||||
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column flex="1"/>
|
||||
<column/>
|
||||
</columns>
|
||||
<rows>
|
||||
<row align="center">
|
||||
<label value="&name.label;" accesskey="&name.accesskey;" control="name"/>
|
||||
<textbox id="name" oninput="onFieldInput();"/>
|
||||
</row>
|
||||
<row align="center" id="keywordRow">
|
||||
<label value="&keyword.label;" accesskey="&keyword.accesskey;" control="keyword"/>
|
||||
<textbox id="keyword" oninput="onFieldInput();"/>
|
||||
</row>
|
||||
<row align="center">
|
||||
<label id="createinlabel" value="&createin.label;" accesskey="&createin.accesskey;" control="select-menu"/>
|
||||
<menulist id="select-menu" class="folder-icon"
|
||||
oncommand="selectMenulistFolder(event);">
|
||||
<menupopup datasources="rdf:bookmarks" ref="NC:LastModifiedFoldersRoot">
|
||||
<menuitem class="menuitem-iconic folder-icon"
|
||||
label="&bookmarksRoot.label;"
|
||||
id="NC:BookmarksRoot"/>
|
||||
<menuitem class="menuitem-iconic folder-icon"
|
||||
label="&bookmarksToolbar.label;"
|
||||
id="btfMenuItem"/>
|
||||
<menuseparator/>
|
||||
<template>
|
||||
<!-- this parent="menupopup" here seems to prevent the template builder from recursing. -->
|
||||
<rule parent="menupopup">
|
||||
<menuitem uri="rdf:*" class="menuitem-iconic folder-icon"
|
||||
label="rdf:http://home.netscape.com/NC-rdf#Name"/>
|
||||
</rule>
|
||||
</template>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
<button id="expander" class="down" oncommand="expandTree();"
|
||||
tooltiptextdown="&expanderDown.tooltip;"
|
||||
tooltiptextup="&expanderUp.tooltip;"/>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
|
||||
<separator class="thin"/>
|
||||
|
||||
<bookmarks-tree id="folder-tree" flex="1" type="folders" collapsed="true"
|
||||
seltype="single" persist="height" rows="6"
|
||||
onselect="selectTreeFolder();"/>
|
||||
</dialog>
|
||||
@@ -1,16 +0,0 @@
|
||||
bookmarks-tree, bookmarks-tree[type="multi-column"] {
|
||||
-moz-binding: url("chrome://browser/content/bookmarks/bookmarksTree.xml#bookmarks-tree-full");
|
||||
}
|
||||
|
||||
bookmarks-tree[type="single-column"] {
|
||||
-moz-binding: url("chrome://browser/content/bookmarks/bookmarksTree.xml#bookmarks-tree-name");
|
||||
}
|
||||
|
||||
bookmarks-tree[type="folders"] {
|
||||
-moz-binding: url("chrome://browser/content/bookmarks/bookmarksTree.xml#bookmarks-tree-folders");
|
||||
}
|
||||
|
||||
treechildren::-moz-tree-image(Name) {
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||