summaryrefslogtreecommitdiffstats
path: root/editor/libeditor
diff options
context:
space:
mode:
Diffstat (limited to 'editor/libeditor')
-rw-r--r--editor/libeditor/HTMLEditorDataTransfer.cpp1
-rw-r--r--editor/libeditor/HTMLStyleEditor.cpp1
-rw-r--r--editor/libeditor/moz.build2
-rw-r--r--editor/libeditor/tests/test_dom_input_event_on_htmleditor.html20
-rw-r--r--editor/libeditor/tests/test_dom_input_event_on_texteditor.html20
5 files changed, 13 insertions, 31 deletions
diff --git a/editor/libeditor/HTMLEditorDataTransfer.cpp b/editor/libeditor/HTMLEditorDataTransfer.cpp
index c56fbead7..37b4fad2c 100644
--- a/editor/libeditor/HTMLEditorDataTransfer.cpp
+++ b/editor/libeditor/HTMLEditorDataTransfer.cpp
@@ -9,6 +9,7 @@
#include <string.h>
#include "HTMLEditUtils.h"
+#include "TextEditRules.h"
#include "TextEditUtils.h"
#include "WSRunObject.h"
#include "mozilla/dom/DataTransfer.h"
diff --git a/editor/libeditor/HTMLStyleEditor.cpp b/editor/libeditor/HTMLStyleEditor.cpp
index 6a1ffe8b4..c81ca1c53 100644
--- a/editor/libeditor/HTMLStyleEditor.cpp
+++ b/editor/libeditor/HTMLStyleEditor.cpp
@@ -6,6 +6,7 @@
#include "mozilla/HTMLEditor.h"
#include "HTMLEditUtils.h"
+#include "TextEditRules.h"
#include "TextEditUtils.h"
#include "TypeInState.h"
#include "mozilla/Assertions.h"
diff --git a/editor/libeditor/moz.build b/editor/libeditor/moz.build
index 998ef3d39..516b3c2d8 100644
--- a/editor/libeditor/moz.build
+++ b/editor/libeditor/moz.build
@@ -30,7 +30,7 @@ EXPORTS.mozilla += [
'TextEditRules.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'ChangeAttributeTransaction.cpp',
'ChangeStyleTransaction.cpp',
'CompositionTransaction.cpp',
diff --git a/editor/libeditor/tests/test_dom_input_event_on_htmleditor.html b/editor/libeditor/tests/test_dom_input_event_on_htmleditor.html
index d1716a228..dc8790750 100644
--- a/editor/libeditor/tests/test_dom_input_event_on_htmleditor.html
+++ b/editor/libeditor/tests/test_dom_input_event_on_htmleditor.html
@@ -67,21 +67,11 @@ function runTests()
"input event is fired on unexpected element: " + aEvent.target.tagName);
ok(!aEvent.cancelable, "input event must not be cancelable");
ok(aEvent.bubbles, "input event must be bubbles");
- if (SpecialPowers.getBoolPref("dom.event.highrestimestamp.enabled")) {
- var duration = Math.abs(window.performance.now() - aEvent.timeStamp);
- ok(duration < 30 * 1000,
- "perhaps, timestamp wasn't set correctly :" + aEvent.timeStamp +
- " (expected it to be within 30s of the current time but it " +
- "differed by " + duration + "ms)");
- } else {
- var eventTime = new Date(aEvent.timeStamp);
- var duration = Math.abs(Date.now() - aEvent.timeStamp);
- ok(duration < 30 * 1000,
- "perhaps, timestamp wasn't set correctly :" +
- eventTime.toLocaleString() +
- " (expected it to be within 30s of the current time but it " +
- "differed by " + duration + "ms)");
- }
+ var duration = Math.abs(window.performance.now() - aEvent.timeStamp);
+ ok(duration < 30 * 1000,
+ "perhaps, timestamp wasn't set correctly :" + aEvent.timeStamp +
+ " (expected it to be within 30s of the current time but it " +
+ "differed by " + duration + "ms)");
inputEvent = aEvent;
};
diff --git a/editor/libeditor/tests/test_dom_input_event_on_texteditor.html b/editor/libeditor/tests/test_dom_input_event_on_texteditor.html
index b1395e99c..abdd5f5d0 100644
--- a/editor/libeditor/tests/test_dom_input_event_on_texteditor.html
+++ b/editor/libeditor/tests/test_dom_input_event_on_texteditor.html
@@ -41,21 +41,11 @@ function runTests()
"input event is fired on unexpected element: " + aEvent.target.tagName);
ok(!aEvent.cancelable, "input event must not be cancelable");
ok(aEvent.bubbles, "input event must be bubbles");
- if (SpecialPowers.getBoolPref("dom.event.highrestimestamp.enabled")) {
- var duration = Math.abs(window.performance.now() - aEvent.timeStamp);
- ok(duration < 30 * 1000,
- "perhaps, timestamp wasn't set correctly :" + aEvent.timeStamp +
- " (expected it to be within 30s of the current time but it " +
- "differed by " + duration + "ms)");
- } else {
- var eventTime = new Date(aEvent.timeStamp);
- var duration = Math.abs(Date.now() - aEvent.timeStamp);
- ok(duration < 30 * 1000,
- "perhaps, timestamp wasn't set correctly :" +
- eventTime.toLocaleString() +
- " (expected it to be within 30s of the current time but it " +
- "differed by " + duration + "ms)");
- }
+ var duration = Math.abs(window.performance.now() - aEvent.timeStamp);
+ ok(duration < 30 * 1000,
+ "perhaps, timestamp wasn't set correctly :" + aEvent.timeStamp +
+ " (expected it to be within 30s of the current time but it " +
+ "differed by " + duration + "ms)");
inputEvent = aEvent;
};