Bug 401668 - calendar-unifinder.css changes text color in Thunderbird. r=philipp

This commit is contained in:
mschroeder%mozilla.x-home.org 2007-11-06 10:59:46 +00:00
Родитель 7643444f95
Коммит caae7cfe1b
4 изменённых файлов: 17 добавлений и 22 удалений

Просмотреть файл

@ -52,7 +52,6 @@
* This is a hacked in interface to the unifinder. We will need to
* improve this to make it usable in general.
*/
var gUnifinderTreeName = "unifinder-search-results-listbox";
var kEventStatusOrder = ["TENTATIVE", "CONFIRMED", "CANCELLED"];
// Set this to true when the calendar event tree is clicked to allow for
@ -76,7 +75,7 @@ function resetAllowSelection() {
*/
doingSelection = false;
var searchTree = document.getElementById(gUnifinderTreeName);
var searchTree = document.getElementById("unifinder-search-results-tree");
searchTree.view.selection.selectEventsSuppressed = false;
searchTree.addEventListener("select", unifinderOnSelect, true);
}
@ -91,7 +90,7 @@ function selectSelectedEventsInTree(aEventsToSelect) {
if (aEventsToSelect === false) {
aEventsToSelect = currentView().getSelectedItems({});
}
var searchTree = document.getElementById(gUnifinderTreeName);
var searchTree = document.getElementById("unifinder-search-results-tree");
/**
* The following is a brutal hack, caused by
@ -202,7 +201,7 @@ var unifinderObserver = {
items = items.filter(this.dateFilter);
gEventArray = gEventArray.concat(items);
gEventArray.sort(compareEvents);
var tree = document.getElementById("unifinder-search-results-listbox");
var tree = document.getElementById("unifinder-search-results-tree");
for each (var item in items) {
var row = tree.eventView.getRowOfCalendarEvent(item);
tree.treeBoxObject.rowCountChanged(row, 1);
@ -216,7 +215,7 @@ var unifinderObserver = {
items = [aItem];
}
items = items.filter(this.dateFilter);
var tree = document.getElementById("unifinder-search-results-listbox");
var tree = document.getElementById("unifinder-search-results-tree");
for each (var item in items) {
var row = tree.eventView.getRowOfCalendarEvent(item);
gEventArray.splice(row, 1);
@ -315,7 +314,7 @@ function unifinderDoubleClickEvent(event) {
* Get the calendar from the given event
*/
function getCalendarEventFromEvent(event) {
var tree = document.getElementById(gUnifinderTreeName);
var tree = document.getElementById("unifinder-search-results-tree");
var row = tree.treeBoxObject.getRowAt(event.clientX, event.clientY);
if (row != -1 && row < tree.view.rowCount) {
@ -340,7 +339,7 @@ function unifinderOnSelect(event) {
var calendarEvent;
// Get the selected events from the tree
var tree = document.getElementById(gUnifinderTreeName);
var tree = document.getElementById("unifinder-search-results-tree");
var start = new Object();
var end = new Object();
var numRanges = tree.view.selection.getRangeCount();
@ -370,10 +369,6 @@ function unifinderOnSelect(event) {
onSelectionChanged({detail: arrayOfEvents});
}
function unifinderToDoHasFocus() {
return document.getElementById(ToDogUnifinderTreeName).treeBoxObject.focused;
}
/**
* This is called from the unifinder when a key is pressed in the search field
*/
@ -448,7 +443,7 @@ var unifinderTreeView = {
this.sortDirection = col.element.getAttribute("sortDirection");
if (sortActive != "true") {
var unifinder = document.getElementById("unifinder-search-results-listbox");
var unifinder = document.getElementById("unifinder-search-results-tree");
var treeCols = unifinder.getElementsByTagName("treecol");
for (var i = 0; i < treeCols.length; i++) {
treeCols[i].removeAttribute("sortActive");
@ -467,7 +462,7 @@ var unifinderTreeView = {
this.sortStartedTime = new Date().getTime(); // for null/0 dates in sort
gEventArray.sort(compareEvents);
document.getElementById(gUnifinderTreeName).view = this;
document.getElementById("unifinder-search-results-tree").view = this;
},
setTree: function uTV_setTree(tree) { this.tree = tree; },
@ -761,7 +756,7 @@ function refreshEventTreeInternal(eventArray) {
}
gEventArray = gEventArray.filter(dateFilter);
var unifinderTree = document.getElementById(gUnifinderTreeName);
var unifinderTree = document.getElementById("unifinder-search-results-tree");
var arrayOfTreeCols = unifinderTree.getElementsByTagName("treecol");
for (var i = 0; i < arrayOfTreeCols.length; i++) {

Просмотреть файл

@ -95,7 +95,7 @@
<textbox id="unifinder-search-field" onkeypress="searchKeyPress( this, event )" flex="1"/>
</box>
</hbox>
<tree id="unifinder-search-results-listbox" flex="1"
<tree id="unifinder-search-results-tree" flex="1"
onselect="unifinderOnSelect( event ); onSelectionChanged()"
onkeypress="unifinderKeyPress(event)"
enableColumnDrag="true">
@ -139,7 +139,7 @@
</treecols>
<!-- on mousedown here happens before onclick above -->
<treechildren tooltip="eventTreeTooltip" class="unifinder-class"
<treechildren tooltip="eventTreeTooltip"
onkeypress="if (event.keyCode == 13) unifinderEditCommand();"
ondragover="return( false );"
ondblclick="unifinderDoubleClickEvent( event )"

Просмотреть файл

@ -58,16 +58,16 @@
}
/* only format Unifinder lists */
treechildren.unifinder-class::-moz-tree-row {
#unifinder-search-results-tree > treechildren::-moz-tree-row {
border-bottom: 1px dotted #AAA;
}
treechildren::-moz-tree-cell-text(selected) {
#unifinder-search-results-tree > treechildren::-moz-tree-cell-text(selected) {
color: HighlightText;
}
/* workaround to avoid Window Flick */
#unifinder-search-results-listbox {
#unifinder-search-results-tree {
/* increased to display scrollbar and at least 2 lines */
min-height : 92px ;
/* remove margin to match Thunderbird's layout */

Просмотреть файл

@ -58,16 +58,16 @@
}
/* only format Unifinder lists */
treechildren.unifinder-class::-moz-tree-row {
#unifinder-search-results-tree > treechildren::-moz-tree-row {
border-bottom: 1px dotted #AAA;
}
treechildren::-moz-tree-cell-text(selected) {
#unifinder-search-results-tree > treechildren::-moz-tree-cell-text(selected) {
color: HighlightText;
}
/* workaround to avoid Window Flick */
#unifinder-search-results-listbox {
#unifinder-search-results-tree {
/* increased to display scrollbar and at least 2 lines */
min-height : 92px ;
/* remove margin to match Thunderbird's layout */