Advanced Edit: Font element cannot contain events

VERIFIED FIXED in mozilla0.9.4

Status

()

Core
Editor
P3
normal
VERIFIED FIXED
17 years ago
17 years ago

People

(Reporter: rubydoo123, Assigned: Charles Manske)

Tracking

Trunk
mozilla0.9.4
x86
Other
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

17 years ago
the Advanced edit for FONT needs to have event choices removed from events tab
(Reporter)

Updated

17 years ago
Priority: -- → P3
Target Milestone: --- → mozilla1.0
(Assignee)

Comment 1

17 years ago
No JS events at all? This is a new rule. Are there any other elements that
can't have any events?
We should simply disable the JS tab in this case.
Status: NEW → ASSIGNED
Target Milestone: mozilla1.0 → mozilla0.9.4
(Assignee)

Comment 2

17 years ago
*** Bug 88945 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 3

17 years ago
*** Bug 88925 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 4

17 years ago
*** Bug 89448 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 5

17 years ago
Expanding this bug to cover all elements that shouldn't have JS events
Summary: Advanced Edit: Font element cannot contain events → Advanced Edit: Font, applet, isindex, and iframe elements cannot contain events
(Assignee)

Comment 6

17 years ago
Fixed by adding a new signal string to tell us not to allow editing JS Events
Add this code to EdAEJSAttributes.js in the method BuildJSEAttributeNameList():

+      // Since we don't allow user-editable JS events yet (but we will soon)
+      // simply remove the JS tab to not allow adding JS events
+      if (attNames[0] == "noJSEvents")
+      {
+        var tab = document.getElementById("tabJSE");
+        if (tab)
+          tab.parentNode.removeChild(tab);
+
+        return;
+      }
... 
-  // Always add core JS events
+  // Always add core JS events unless we aborted above
(rest is the same as before)

In EdAEAttributes.js, add this to tell us what elements to not set events on:
+
+// Elements that don't have core JSEvents:
+gJSAttr.font =
+[
+
"noJSEvents"
+];
+
+gJSAttr.applet =
+[
+
"noJSEvents"
+];
+
+gJSAttr.isindex =
+[
+
"noJSEvents"
+];
+
+gJSAttr.iframe =
+[
+
"noJSEvents"
+];

 
Keywords: review
Whiteboard: FIX IN HAND, need r=, sr=
(Assignee)

Comment 7

17 years ago
Hmm, that diff is confused by tab characters in the source. The new element
entries look like this using 2 spaces instead of tabs:

// Elements that don't have JSEvents:
gJSAttr.font =
[
  "noJSEvents"
];

gJSAttr.applet =
[
  "noJSEvents"
];

gJSAttr.isindex =
[
  "noJSEvents"
];

gJSAttr.iframe =
[
  "noJSEvents"
];

Keywords: review
Summary: Advanced Edit: Font, applet, isindex, and iframe elements cannot contain events → Advanced Edit: Font element cannot contain events
Whiteboard: FIX IN HAND, need r=, sr=
(Assignee)

Comment 8

17 years ago
Fixed with other Advanced Editor dialog fixes last week.
Status: ASSIGNED → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → FIXED

Comment 9

17 years ago
Verified on 8-30 Build
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.