Bug 452657 - Remove richview from toolkit. r=dtownsend

This commit is contained in:
Robert Strong 2008-09-01 13:38:42 -07:00
parent f52a1a26d4
commit 0bc3b8e923
17 changed files with 4 additions and 299 deletions

View File

@ -16,7 +16,6 @@ toolkit.jar:
* content/mozapps/preferences/removemp.xul (preferences/removemp.xul)
content/mozapps/preferences/preferences.css (preferences/preferences.css)
* content/mozapps/preferences/preferences.xml (preferences/preferences.xml)
* content/mozapps/shared/richview.xml (shared/content/richview.xml)
content/mozapps/plugins/pluginInstallerWizard.xul (plugins/content/pluginInstallerWizard.xul)
content/mozapps/plugins/pluginInstallerWizard.js (plugins/content/pluginInstallerWizard.js)
content/mozapps/plugins/pluginInstallerWizard.css (plugins/content/pluginInstallerWizard.css)

View File

@ -1,205 +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 the Rich ScrollView.
#
# The Initial Developer of the Original Code is Ben Goodger.
# Portions created by the Initial Developer are Copyright (C) 2003-2004
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Ben Goodger <ben@mozilla.org> (Google Inc.)
#
# 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="richViewBindings"
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="richview-item">
<implementation>
<method name="fireEvent">
<parameter name="aEventType"/>
<body>
<![CDATA[
var e = document.createEvent("Events");
e.initEvent(this.eventPrefix + aEventType, false, true);
this.dispatchEvent(e);
]]>
</body>
</method>
<property name="disabled" onget="return this.getAttribute('disabled') == 'true'"
onset="this.setAttribute('disabled', val); return val;"/>
</implementation>
</binding>
<binding id="richview">
<implementation>
<method name="fireEvent">
<parameter name="aEventType"/>
<body>
<![CDATA[
var e = document.createEvent("Events");
var eventType = "richview-" + aEventType;
e.initEvent(eventType, false, true);
this.dispatchEvent(e);
var handler = this.getAttribute("onrichview-" + aEventType);
if (handler != "") {
var fn = new Function("event", handler);
fn(e);
}
document.commandDispatcher.updateCommands(eventType);
]]>
</body>
</method>
<field name="_selected">null</field>
<property name="selected">
<setter>
<![CDATA[
if (this._selected)
this._selected.removeAttribute("selected");
this._selected = val;
if (this._selected)
this._selected.setAttribute("selected", "true");
this.fireEvent("select");
]]>
</setter>
<getter>
<![CDATA[
return this._selected;
]]>
</getter>
</property>
<method name="selectForwardInternal">
<parameter name="aElement"/>
<body>
<![CDATA[
for (var temp = aElement; temp; temp = temp.nextSibling) {
if ("fireEvent" in temp && !temp.hidden) {
this.selected = temp;
break;
}
}
]]>
</body>
</method>
<method name="selectBackwardInternal">
<parameter name="aElement"/>
<body>
<![CDATA[
for (var temp = aElement; temp; temp = temp.previousSibling) {
if ("fireEvent" in temp && !temp.hidden) {
this.selected = temp;
break;
}
}
]]>
</body>
</method>
<method name="selectionForward">
<parameter name="aEvent"/>
<body>
<![CDATA[
if (this.selected)
this.selectForwardInternal(this.selected.nextSibling);
else {
if (this.hasChildNodes())
this.selectForwardInternal(this.firstChild);
}
]]>
</body>
</method>
<method name="selectionBackward">
<parameter name="aEvent"/>
<body>
<![CDATA[
if (this.selected)
this.selectBackwardInternal(this.selected.previousSibling);
else {
if (this.hasChildNodes())
this.selectBackwardInternal(this.lastChild);
}
]]>
</body>
</method>
<property name="children">
<getter>
<![CDATA[
var childNodes = [];
for (var i = 0; i < this.childNodes.length; ++i) {
if ("fireEvent" in this.childNodes[i])
childNodes.push(this.childNodes[i]);
}
return childNodes;
]]>
</getter>
</property>
</implementation>
<handlers>
<handler event="click">
<![CDATA[
if (event.ctrlKey) {
this.selected = null;
return;
}
if (event.target == this)
this.selected = null
else
this.selected = event.target;
]]>
</handler>
<handler event="dblclick" action="if (this.selected &amp;&amp; event.button == 0) this.selected.fireEvent('open');"/>
<handler event="keypress" keycode="VK_ENTER" action="if (this.selected) this.selected.fireEvent('open');"/>
<handler event="keypress" keycode="VK_RETURN" action="if (this.selected) this.selected.fireEvent('open');"/>
<handler event="keypress" keycode="VK_UP" action="this.selectionBackward(event);"/>
<handler event="keypress" keycode="VK_LEFT" action="this.selectionBackward(event);"/>
<handler event="keypress" keycode="VK_DOWN" action="this.selectionForward(event);"/>
<handler event="keypress" keycode="VK_RIGHT" action="this.selectionForward(event);"/>
<handler event="keypress" keycode="VK_UP" modifiers="meta" action="this.selected = null;"/>
<handler event="keypress" keycode="VK_DOWN" modifiers="meta" action="this.selected = null;"/>
<handler event="keypress" keycode="VK_LEFT" modifiers="meta" action="this.selected = null;"/>
<handler event="keypress" keycode="VK_RIGHT" modifiers="meta" action="this.selected = null;"/>
<handler event="keypress" keycode="VK_DELETE" action="if (this.selected) this.selected.fireEvent('remove');"/>
</handlers>
</binding>
</bindings>

View File

@ -106,7 +106,7 @@
/* ..... selected state ..... */
.console-row[selected="true"] {
background-image: url("chrome://mozapps/skin/shared/itemSelected.png");
background-image: url("chrome://global/skin/console/itemSelected.png");
}
.console-row-code[selected="true"],

View File

@ -24,11 +24,6 @@ classic.jar:
skin/classic/mozapps/plugins/pluginGeneric-16.png (plugins/pluginGeneric-16.png)
skin/classic/mozapps/profile/profileicon.png (profile/profileicon.png)
skin/classic/mozapps/profile/profileSelection.css (profile/profileSelection.css)
skin/classic/mozapps/shared/itemFader.png (shared/itemFader.png)
skin/classic/mozapps/shared/itemSelected.png (shared/itemSelected.png)
skin/classic/mozapps/shared/viewFader.png (shared/viewFader.png)
skin/classic/mozapps/shared/richview.css (shared/richview.css)
skin/classic/mozapps/shared/richview.xml (shared/richview.xml)
skin/classic/mozapps/update/warning.gif (update/warning.gif)
skin/classic/mozapps/update/updates.css (update/updates.css)
skin/classic/mozapps/update/update.png (update/update.png)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 849 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

View File

@ -1,21 +0,0 @@
/* Generic RichView */
view {
margin: 10px 10px 5px 10px;
-moz-appearance: listbox;
-moz-user-focus: normal;
}
.richviewInner2 {
background-image: url("chrome://mozapps/skin/shared/viewFader.png");
padding: 0px;
}
.richviewInner1 {
background-color: Window;
background-image: inherit;
background-attachment: fixed;
background-repeat: no-repeat;
background-position: bottom right;
}

View File

@ -1,22 +0,0 @@
<?xml version="1.0"?>
<bindings id="richviewSkinBindings"
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="richview" extends="chrome://mozapps/content/shared/richview.xml#richview">
<resources>
<stylesheet src="chrome://mozapps/skin/shared/richview.css"/>
</resources>
<content>
<xul:vbox flex="1" class="richviewInner1">
<xul:vbox flex="1" class="richviewInner2">
<children/>
</xul:vbox>
</xul:vbox>
</content>
</binding>
</bindings>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 849 B

View File

@ -106,7 +106,7 @@
/* ..... selected state ..... */
.console-row[selected="true"] {
background-image: url("chrome://mozapps/skin/shared/itemSelected.png");
background-image: url("chrome://global/skin/console/itemSelected.png");
}
.console-row-code[selected="true"],

View File

Before

Width:  |  Height:  |  Size: 459 B

After

Width:  |  Height:  |  Size: 459 B

View File

@ -77,6 +77,7 @@ classic.jar:
skin/classic/global/console/bullet-warning.png (console/bullet-warning.png)
skin/classic/global/console/console-error-caret.gif (console/console-error-caret.gif)
skin/classic/global/console/console-error-dash.gif (console/console-error-dash.gif)
skin/classic/global/console/itemSelected.png (console/itemSelected.png)
* skin/classic/global/dirListing/dirListing.css (dirListing/dirListing.css)
skin/classic/global/dirListing/folder.png (dirListing/folder.png)
skin/classic/global/dirListing/local.png (dirListing/local.png)
@ -240,6 +241,7 @@ classic.jar:
skin/classic/aero/global/console/bullet-warning.png (console/bullet-warning-aero.png)
skin/classic/aero/global/console/console-error-caret.gif (console/console-error-caret.gif)
skin/classic/aero/global/console/console-error-dash.gif (console/console-error-dash.gif)
skin/classic/aero/global/console/itemSelected.png (console/itemSelected.png)
* skin/classic/aero/global/dirListing/dirListing.css (dirListing/dirListing.css)
skin/classic/aero/global/dirListing/folder.png (dirListing/folder-aero.png)
skin/classic/aero/global/dirListing/local.png (dirListing/local-aero.png)

View File

@ -30,11 +30,6 @@ classic.jar:
skin/classic/mozapps/plugins/pluginInstallerWizard.css (plugins/pluginInstallerWizard.css)
skin/classic/mozapps/profile/profileicon.png (profile/profileicon.png)
skin/classic/mozapps/profile/profileSelection.css (profile/profileSelection.css)
skin/classic/mozapps/shared/itemFader.png (shared/itemFader.png)
skin/classic/mozapps/shared/itemSelected.png (shared/itemSelected.png)
skin/classic/mozapps/shared/richview.css (shared/richview.css)
skin/classic/mozapps/shared/richview.xml (shared/richview.xml)
skin/classic/mozapps/shared/viewFader.png (shared/viewFader.png)
skin/classic/mozapps/update/extensionalert.png (update/extensionalert.png)
skin/classic/mozapps/update/update.png (update/update.png)
skin/classic/mozapps/update/warning.gif (update/warning.gif)
@ -73,11 +68,6 @@ classic.jar:
skin/classic/aero/mozapps/plugins/pluginInstallerWizard.css (plugins/pluginInstallerWizard.css)
skin/classic/aero/mozapps/profile/profileicon.png (profile/profileicon-aero.png)
skin/classic/aero/mozapps/profile/profileSelection.css (profile/profileSelection.css)
skin/classic/aero/mozapps/shared/itemFader.png (shared/itemFader.png)
skin/classic/aero/mozapps/shared/itemSelected.png (shared/itemSelected.png)
skin/classic/aero/mozapps/shared/richview.css (shared/richview.css)
skin/classic/aero/mozapps/shared/richview.xml (shared/richview.xml)
skin/classic/aero/mozapps/shared/viewFader.png (shared/viewFader.png)
skin/classic/aero/mozapps/update/extensionalert.png (update/extensionalert-aero.png)
skin/classic/aero/mozapps/update/update.png (update/update-aero.png)
skin/classic/aero/mozapps/update/warning.gif (update/warning.gif)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 267 B

View File

@ -1,13 +0,0 @@
/* Generic RichView */
view {
margin: 10px 10px 5px 10px;
-moz-appearance: listbox;
-moz-user-focus: normal;
background-color: Window;
}
.richviewInner {
background-image: url("chrome://mozapps/skin/shared/viewFader.png");
padding: 0px;
}

View File

@ -1,20 +0,0 @@
<?xml version="1.0"?>
<bindings id="richviewSkinBindings"
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="richview" extends="chrome://mozapps/content/shared/richview.xml#richview">
<resources>
<stylesheet src="chrome://mozapps/skin/shared/richview.css"/>
</resources>
<content>
<xul:vbox flex="1" class="richviewInner">
<children/>
</xul:vbox>
</content>
</binding>
</bindings>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 267 B