views:

25

answers:

2

I'm mantaining an ancient Firefox plugin. It uses GetWindowFromPort to get a WindowPtr object out of the NP_Port object which is the platform specific window data in the WidowPtr object. Now it always returns NULL.

NP_Port object is non-null as is the port field (CGraphPtr) of that object. However, without GetWindowFromPort, I no longer know how to get a WindowPtr from a CGraphPtr...

A: 

It appears it's bigger than that. QuickDraw (of which GetWindowFromPort is a function) us na longer supported in any 64b system...

Brian Postow
A: 

This is probably because Firefox is now creating a separate offscreen GWorld for plug-ins to draw to, which is not associated with a window. Considering that in the future plug-ins are going to move out-of-process, depending on it returning a meaningful value is not going to be a good idea. What are you using this value for?

Yuhong Bao