Closed Bug 955215 Opened 10 years ago Closed 10 years ago

Typing notification never goes away for tabs in a detached window

Categories

(Instantbird Graveyard :: Conversation, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: bugzilla, Assigned: florian)

Details

(Whiteboard: [1.3-wanted?])

Attachments

(1 file)

*** Original post on bio 1783 by spiffytech AT gmail.com at 2012-11-08 23:18:00 UTC ***

1) Start a conversation. I know it at least happens when someone else initiates the conversation, and I noticed it for Facebook chats.

2) Detach the conversation into a new window

3) Let the conversant type and send their message

4) See the "typing" notification and green highlight on the conversation tab never go away. 

5) Drag the conversation tab back to its original window

6) After the conversant sends a new message, the typing notification goes away
*** Original post on bio 1783 at 2012-11-08 23:35:08 UTC ***

Is there any error in the Error Console that could be related?
*** Original post on bio 1783 by spiffytech AT gmail.com at 2012-11-08 23:39:14 UTC ***

Here are the last few error console entries, which occurred at about the time I detached a window and received a message:

---
Timestamp: 11/8/12 6:37:36 PM
Warning: Use of Mutation Events is deprecated. Use MutationObserver instead.
Source File: chrome://instantbird/content/instantbird.xul
Line: 0
---

---
Timestamp: 11/8/12 6:37:42 PM
Error: [Exception... "'ReferenceError: Interruptions is not defined' when calling method: [nsIObserver::observe]"  nsresult: "0x8057001c (NS_ERROR_XPC_JS_THREW_JS_OBJECT)"  location: "JS frame :: resource:///modules/jsProtoHelper.jsm :: <TOP_LEVEL> :: line 411"  data: no]
Source File: resource:///modules/jsProtoHelper.jsm
Line: 411
---

---
Timestamp: 11/8/12 6:37:42 PM
Error: [Exception... "'ReferenceError: Interruptions is not defined' when calling method: [nsIObserver::observe]"  nsresult: "0x8057001c (NS_ERROR_XPC_JS_THREW_JS_OBJECT)"  location: "JS frame :: resource:///modules/jsProtoHelper.jsm :: <TOP_LEVEL> :: line 411"  data: no]
Source File: resource:///modules/xmpp-xml.jsm
Line: 399
---
*** Original post on bio 1783 by spiffytech AT gmail.com at 2012-11-08 23:41:52 UTC ***

Sorry, copy/paste fail due to new errors coming in. Let's try that again:

---
Timestamp: 11/8/12 6:37:42 PM
Error: [Exception... "'ReferenceError: Interruptions is not defined' when calling method: [nsIObserver::observe]"  nsresult: "0x8057001c (NS_ERROR_XPC_JS_THREW_JS_OBJECT)"  location: "JS frame :: resource:///modules/jsProtoHelper.jsm :: <TOP_LEVEL> :: line 411"  data: no]
Source File: resource:///modules/xmpp-xml.jsm
Line: 399
---

---
Timestamp: 11/8/12 6:37:42 PM
Error: [Exception... "'ReferenceError: Interruptions is not defined' when calling method: [nsIObserver::observe]"  nsresult: "0x8057001c (NS_ERROR_XPC_JS_THREW_JS_OBJECT)"  location: "JS frame :: resource:///modules/jsProtoHelper.jsm :: <TOP_LEVEL> :: line 411"  data: no]
Source File: resource:///modules/jsProtoHelper.jsm
Line: 411
---

---
Timestamp: 11/8/12 6:37:36 PM
Warning: Use of Mutation Events is deprecated. Use MutationObserver instead.
Source File: chrome://instantbird/content/instantbird.xul
Line: 0
---
*** Original post on bio 1783 at 2012-11-08 23:59:45 UTC ***

Thanks. 'ReferenceError: Interruptions is not defined' is an interesting error, and we should fix it.

It's because we import that module at http://lxr.instantbird.org/instantbird/source/instantbird/content/conversation.xml#163 in _showFirstMessages which is probably never called for an imported conversation.

The fix is either to move the import of Interruptions in the constructor of the conversation binding, or to duplicate it to the finishImport method which is called when displaying a conversation that's been detached.

However, I don't see how that can affect typing notifications, so there may be something else that's broken.

I kinda wonder if this._readCount should be initialized in _showFirstMessage, but it's not related to typing notifications either. :-S
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Other → All
Hardware: x86 → All
Whiteboard: [1.3-wanted?]
Attached patch PatchSplinter Review
*** Original post on bio 1783 as attmnt 2078 at 2012-11-09 23:54:00 UTC ***

I can reproduce the bug, and after fixing that JS error by moving the import call in a code path used by both new and detached windows I can no longer reproduce, so I didn't bother looking for the exact cause of the problem with typing notifications.
Attachment #8353838 - Flags: review?(benediktp)
Assignee: nobody → florian
Comment on attachment 8353838 [details] [diff] [review]
Patch

*** Original change on bio 1783 attmnt 2078 at 2012-11-10 00:18:59 UTC ***

Looks good, thanks!
Attachment #8353838 - Flags: review?(benediktp) → review+
*** Original post on bio 1783 at 2012-11-10 00:21:47 UTC ***

http://hg.instantbird.org/instantbird/rev/8725800af23f
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.3
You need to log in before you can comment on or make changes to this bug.