Closed Bug 117766 Opened 23 years ago Closed 11 years ago

With a non-NULL target argument, NPN_GetURLNotify and NPN_PostURLNotify do not cause NPP_Notify to be called

Categories

(Core Graveyard :: Plug-ins, defect, P2)

defect

Tracking

(Not tracked)

RESOLVED WONTFIX
mozilla1.5alpha

People

(Reporter: serhunt, Assigned: peterl-bugs)

References

Details

(Keywords: topembed+, Whiteboard: [PL:BRANCH])

Attachments

(1 file, 1 obsolete file)

If you look at ns4xPlugin.cpp _geturlnotify method (as of today it is here: 
http://lxr.mozilla.org/seamonkey/source/modules/plugin/base/src/ns4xPlugin.cpp#7
00 ), you will notice that we create a stream only for null-targets:

  if(target == nsnull)
    ((ns4xPluginInstance*)inst)->NewNotifyStream(&listener, notifyData);

This is probably not correct. The Tester plugin shows a difference between 
Mozilla and NS4.x where the notification comes regardless of the target used.
Keywords: 4xp
nominating nsbeta1, mozilla.10
Keywords: mozilla1.0, nsbeta1
Marking nsbeta1- per ADT.
Keywords: nsbeta1nsbeta1-
fixed in bug 127259?
nope, it does not.
I think this may be a bit more difficult to fix.

Currently, non-null targeted requests get funnled through nsILinkHandler:
http://lxr.mozilla.org/mozilla/source/layout/html/base/src/nsObjectFrame.cpp#2252

The problem is that this opens the stream asynchronsly in the webshell and
plugin code has know way of knowing when to call URLNotify.

One possibility is to use the newly added |OnLinkClickSync| on nsILinkHandler
which works synchronsly PLUS returns a nsIRequest and nsIDocShell. An
nsIWebProgressListener can then be attached to the docshell and a notification
fired when loading is done.



Blocks: 55959
setting to 1.1
Priority: -- → P3
Target Milestone: --- → mozilla1.1alpha
Priority: P3 → P1
Hardware: PC → All
Summary: NPN_GetURLNotify and NPN_PostURLNotify do not notify for non-null targets → With a non-NULL target argument, NPN_GetURLNotify and NPN_PostURLNotify do not cause NPP_Notify to be called
Whiteboard: [PL2:P1]
Target Milestone: mozilla1.1alpha → mozilla1.2beta
*** Bug 56311 has been marked as a duplicate of this bug. ***
taking this bug
Assignee: av → serge
Attached patch patch v1 (obsolete) — Splinter Review
this patch seams to work, I need to find out the right header file for
declaration of struct _NPN_NotifyRequire
actually it seams to me it would be much easy to put that struct into local *.h
file after landing the patch for bug 136927
Keywords: topembed+
Attached patch patch v1.2Splinter Review
set flag to avoid conflict when plugin issues  several GetURLNotify with the
same url & target (not final yet)
Attachment #103109 - Attachment is obsolete: true
moving to 1.4beta, plug-in branch work
Whiteboard: [PL2:P1] → [PL:BRANCH]
Target Milestone: mozilla1.2beta → mozilla1.4beta
-->peterl
Assignee: serge → peterl
Priority: P1 → P3
per topembed+ triage: P2
Priority: P3 → P2
QA Contact: shrir → ashishbhatt
Target Milestone: mozilla1.4beta → mozilla1.5alpha
Keywords: mozilla1.0
QA Contact: ashshbhatt → plugins
At this point, we do not intend to fix this behavior.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → WONTFIX
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: