Controller for html content stealing command update from window

VERIFIED FIXED in M14

Status

()

defect
P3
normal
VERIFIED FIXED
20 years ago
11 years ago

People

(Reporter: hangas, Assigned: hangas)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [PDT+] 2/11)

(Assignee)

Description

20 years ago
The controller attached to globalWindow to handle browser content (any html 
content) is attached to the window rather than the content so it is winning out 
over the default controller attached to the window from JS in the Mail/News 
window.  This globalWindow controller returns true for Copy and Select All so 
these menu items appear enabled for the entire window even though focus may be on 
an item that does not support either function.
(Assignee)

Updated

20 years ago
Blocks: 25139
(Assignee)

Comment 1

20 years ago
Nominate for beta1 because of the pdt+ bug that depends on this bug.
Keywords: beta1

Comment 2

20 years ago
Hangas, this is your bug, not sfraser's.  You should use insertControllerAt 
rather than appendController, and put yourself at position 0.

Comment 3

20 years ago
based on hyatt's comment, assigning to hangas
Assignee: sfraser → hangas

Updated

20 years ago
Whiteboard: [PDT+]
(Assignee)

Comment 4

20 years ago
Marking completion date of 2/11.
Status: NEW → ASSIGNED
Whiteboard: [PDT+] → [PDT+] 2/11
Target Milestone: M14
(Assignee)

Comment 5

20 years ago
I tried:
top.controllers.insertControllerAt(0, DefaultController);
but that did not help.  globalWindow controller still keeping Copy and Select All 
enabled when thread pane has focus.  Sending to Hyatt for further suggestions.
Assignee: hangas → hyatt
Status: ASSIGNED → NEW
Whiteboard: [PDT+] 2/11 → [PDT+]

Comment 6

20 years ago
Fix your JS.

A glance at widgetGlue shows you always returning true for your selectAll in 
isCommandEnabled of the default controller.

You're also not claiming that you support the copy command on the default 
controller, which will cause us to defer to the next controller in the chain.  
This is the correct behavior.  You need to say that you support copy and wish
to keep it disabled.

Yet another option, if you don't think you want or like the default command 
controller we put in all DOM windows, is to just remove it all together.  You 
can call removeControllerAt(0) to remove the controller from the array.

Comment 7

20 years ago
reassigning.
Assignee: hyatt → hangas
(Assignee)

Comment 8

20 years ago
Cool.  This is almost as good as documentation :-).
Status: NEW → ASSIGNED
(Assignee)

Updated

20 years ago
Whiteboard: [PDT+] → [PDT+] 2/11
(Assignee)

Comment 9

20 years ago
Fix checked in.  This can be tested by setting focus on the thread pane and 
choosing Select All.  If the messages are all selected then it is working, if 
nothing happens then it is broken again.
Status: ASSIGNED → RESOLVED
Last Resolved: 20 years ago
Resolution: --- → FIXED

Comment 10

19 years ago
qa -> lchiang to verify in mail
QA Contact: paulmac → lchiang

Updated

19 years ago
QA Contact: lchiang → laurel

Comment 11

19 years ago
OK using:
2000-02-15-09m14 commercial build NT 4.0
2000-02-15-09m14 commercial build Mac OS 9.0
2000-02-15-09m14 mozilla build linux rh6.0
Status: RESOLVED → VERIFIED

Updated

11 years ago
Component: XP Toolkit/Widgets: XUL → XUL
QA Contact: laurel → xptoolkit.widgets
You need to log in before you can comment on or make changes to this bug.