Bug 710239 - Minimonth and Timepicker mousewheel support is broken [Error: NSUIEvent is not defined] r=philipp

This commit is contained in:
Stefan Sitter 2011-12-13 23:03:12 +01:00
Родитель 78c2b72da7
Коммит 124deb94f4
2 изменённых файлов: 8 добавлений и 8 удалений

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

@ -267,9 +267,9 @@
if (yearPopup) {
let monthList = yearPopup.getElementsByAttribute("class", "minimonth-list");
if (monthList && monthList.length > 0) {
if (event.detail == NSUIEvent.SCROLL_PAGE_UP) {
if (event.detail == UIEvent.SCROLL_PAGE_UP) {
this.moveYears('up', monthList.length);
} else if (event.detail == NSUIEvent.SCROLL_PAGE_DOWN) {
} else if (event.detail == UIEvent.SCROLL_PAGE_DOWN) {
this.moveYears('down', monthList.length);
} else if (event.detail < 0) {
this.moveYears('up', 1);
@ -1167,9 +1167,9 @@
return;
}
var rows = event.detail;
if (rows == NSUIEvent.SCROLL_PAGE_UP) {
if (rows == UIEvent.SCROLL_PAGE_UP) {
rows = -1;
} else if (rows == NSUIEvent.SCROLL_PAGE_DOWN) {
} else if (rows == UIEvent.SCROLL_PAGE_DOWN) {
rows = 1;
} else {
// In this case event.detail contains the default number of lines

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

@ -605,9 +605,9 @@
<handler event="DOMMouseScroll">
<![CDATA[
var rows = event.detail;
if (rows == NSUIEvent.SCROLL_PAGE_UP) {
if (rows == UIEvent.SCROLL_PAGE_UP) {
rows = -1;
} else if (rows == NSUIEvent.SCROLL_PAGE_DOWN) {
} else if (rows == UIEvent.SCROLL_PAGE_DOWN) {
rows = 1;
} else {
// In this case event.detail contains the default number of lines
@ -635,9 +635,9 @@
<handler event="DOMMouseScroll">
<![CDATA[
var rows = event.detail;
if (rows == NSUIEvent.SCROLL_PAGE_UP) {
if (rows == UIEvent.SCROLL_PAGE_UP) {
rows = -1;
} else if (rows == NSUIEvent.SCROLL_PAGE_DOWN) {
} else if (rows == UIEvent.SCROLL_PAGE_DOWN) {
rows = 1;
} else {
// In this case event.detail contains the default number of lines