jsobject jswindow = NULL; GetWindowMessage msg(pluginInstance, &jswindow); sendMessage(env, &msg); pluginInstance->Release(); if (jswindow != NULL) return Wrap_JSObject(env, jswindow);
jsobject jswindow = NULL; GetWindowMessage msg(pluginInstance, &jswindow); sendMessage(env, &msg);  if (jswindow != NULL) return Wrap_JSObject(env, jswindow);
Java_netscape_javascript_JSObject_getWindow(JNIEnv* env,                                            jclass js_object_class,                                            jobject java_applet_obj){	MRJPluginInstance* pluginInstance = theJVMPlugin->getPluginInstance(java_applet_obj);	if (pluginInstance != NULL) {#ifdef MRJPLUGIN_4X		// keep an extra reference to the plugin instance, until it is finalized.		jobject jwindow = Wrap_JSObject(env, jsobject(pluginInstance));		return jwindow;#else		class GetWindowMessage : public JavaMessage {			nsIPluginInstance* mPluginInstance;			jsobject* mWindowResult;		public:			GetWindowMessage(nsIPluginInstance* pluginInstance, jsobject* windowResult)				:	mPluginInstance(pluginInstance), mWindowResult(windowResult)			{			}			virtual void execute(JNIEnv* env)			{				nsresult status = theLiveConnectManager->GetWindow(env,mPluginInstance, NULL, 0, NULL, mWindowResult);			}		};		jsobject jswindow = NULL;		GetWindowMessage msg(pluginInstance, &jswindow);		sendMessage(env, &msg);		pluginInstance->Release();		if (jswindow != NULL)			return Wrap_JSObject(env, jswindow);#endif	}	return NULL;}