1 /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* ***** BEGIN LICENSE BLOCK *****
3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 * http://www.mozilla.org/MPL/
10 * Software distributed under the License is distributed on an "AS IS" basis,
11 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 * for the specific language governing rights and limitations under the
15 * The Original Code is mozilla.org code.
17 * The Initial Developer of the Original Code is
18 * Netscape Communications Corporation.
19 * Portions created by the Initial Developer are Copyright (C) 1998
20 * the Initial Developer. All Rights Reserved.
24 * Alternatively, the contents of this file may be used under the terms of
25 * either the GNU General Public License Version 2 or later (the "GPL"), or
26 * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 * in which case the provisions of the GPL or the LGPL are applicable instead
28 * of those above. If you wish to allow use of your version of this file only
29 * under the terms of either the GPL or the LGPL, and not to allow others to
30 * use your version of this file under the terms of the MPL, indicate your
31 * decision by deleting the provisions above and replace them with the notice
32 * and other provisions required by the GPL or the LGPL. If you do not delete
33 * the provisions above, a recipient may use your version of this file under
34 * the terms of any one of the MPL, the GPL or the LGPL.
36 * ***** END LICENSE BLOCK ***** */
47 #if defined(__OS2__) || defined(OS2)
53 #if defined(_WIN32) && !defined(__SYMBIAN32__)
54 #if defined _MSC_VER && _MSC_VER >= 1200
56 #pragma warning(disable:4201)
59 #if defined _MSC_VER && _MSC_VER >= 1200
67 #if defined(__SYMBIAN32__)
74 #if defined(__APPLE_CC__) && !defined(XP_UNIX)
80 #if defined(XP_MACOSX) && defined(__LP64__)
81 #define NP_NO_QUICKDRAW
85 #if defined(XP_MACOSX)
86 #include <ApplicationServices/ApplicationServices.h>
87 #include <OpenGL/OpenGL.h>
89 #include <Carbon/Carbon.h>
97 #include <X11/Xutil.h>
101 #if defined(XP_SYMBIAN)
106 /*----------------------------------------------------------------------*/
107 /* Plugin Version Constants */
108 /*----------------------------------------------------------------------*/
110 #define NP_VERSION_MAJOR 0
111 #define NP_VERSION_MINOR 27
114 /* The OS/2 version of Netscape uses RC_DATA to define the
115 mime types, file extensions, etc that are required.
116 Use a vertical bar to separate types, end types with \0.
117 FileVersion and ProductVersion are 32bit ints, all other
118 entries are strings that MUST be terminated with a \0.
122 RCDATA NP_INFO_ProductVersion { 1,0,0,1,}
124 RCDATA NP_INFO_MIMEType { "video/x-video|",
126 RCDATA NP_INFO_FileExtents { "avi|",
128 RCDATA NP_INFO_FileOpenName{ "MMOS2 video player(*.avi)|",
129 "MMOS2 Flc/Fli player(*.flc)\0" }
131 RCDATA NP_INFO_FileVersion { 1,0,0,1 }
132 RCDATA NP_INFO_CompanyName { "Netscape Communications\0" }
133 RCDATA NP_INFO_FileDescription { "NPAVI32 Extension DLL\0"
134 RCDATA NP_INFO_InternalName { "NPAVI32\0" )
135 RCDATA NP_INFO_LegalCopyright { "Copyright Netscape Communications \251 1996\0"
136 RCDATA NP_INFO_OriginalFilename { "NVAPI32.DLL" }
137 RCDATA NP_INFO_ProductName { "NPAVI32 Dynamic Link Library\0" }
139 /* RC_DATA types for version info - required */
140 #define NP_INFO_ProductVersion 1
141 #define NP_INFO_MIMEType 2
142 #define NP_INFO_FileOpenName 3
143 #define NP_INFO_FileExtents 4
144 /* RC_DATA types for version info - used if found */
145 #define NP_INFO_FileDescription 5
146 #define NP_INFO_ProductName 6
147 /* RC_DATA types for version info - optional */
148 #define NP_INFO_CompanyName 7
149 #define NP_INFO_FileVersion 8
150 #define NP_INFO_InternalName 9
151 #define NP_INFO_LegalCopyright 10
152 #define NP_INFO_OriginalFilename 11
156 /*----------------------------------------------------------------------*/
157 /* Definition of Basic Types */
158 /*----------------------------------------------------------------------*/
160 typedef unsigned char NPBool
;
161 typedef int16_t NPError
;
162 typedef int16_t NPReason
;
163 typedef char* NPMIMEType
;
165 /*----------------------------------------------------------------------*/
166 /* Structures and definitions */
167 /*----------------------------------------------------------------------*/
169 #if !defined(__LP64__)
170 #if defined(XP_MACOSX)
171 #pragma options align=mac68k
173 #endif /* __LP64__ */
176 * NPP is a plug-in's opaque instance handle
180 void* pdata
; /* plug-in private data */
181 void* ndata
; /* netscape private data */
186 typedef struct _NPStream
188 void* pdata
; /* plug-in private data */
189 void* ndata
; /* netscape private data */
192 uint32_t lastmodified
;
194 const char* headers
; /* Response headers from host.
195 * Exists only for >= NPVERS_HAS_RESPONSE_HEADERS.
196 * Used for HTTP only; NULL for non-HTTP.
197 * Available from NPP_NewStream onwards.
198 * Plugin should copy this data before storing it.
199 * Includes HTTP status line and all headers,
200 * preferably verbatim as received from server,
201 * headers formatted as in HTTP ("Header: Value"),
202 * and newlines (\n, NOT \r\n) separating lines.
203 * Terminated by \n\0 (NOT \n\n\0). */
206 typedef struct _NPByteRange
208 int32_t offset
; /* negative offset means from the end */
210 struct _NPByteRange
* next
;
213 typedef struct _NPSavedData
219 typedef struct _NPRect
227 typedef struct _NPSize
238 /* Return values for NPP_HandleEvent */
239 #define kNPEventNotHandled 0
240 #define kNPEventHandled 1
241 /* Exact meaning must be spec'd in event model. */
242 #define kNPEventStartIME 2
246 * Unix specific structures and definitions
250 * Callback Structures.
252 * These are used to pass additional platform specific information.
262 } NPAnyCallbackStruct
;
273 } NPSetWindowCallbackStruct
;
279 } NPPrintCallbackStruct
;
283 #if defined(XP_MACOSX)
285 #ifndef NP_NO_QUICKDRAW
286 NPDrawingModelQuickDraw
= 0,
288 NPDrawingModelCoreGraphics
= 1,
289 NPDrawingModelOpenGL
= 2,
290 NPDrawingModelCoreAnimation
= 3,
291 NPDrawingModelInvalidatingCoreAnimation
= 4
296 NPEventModelCarbon
= 0,
298 NPEventModelCocoa
= 1
303 * The following masks are applied on certain platforms to NPNV and
304 * NPPV selectors that pass around pointers to COM interfaces. Newer
305 * compilers on some platforms may generate vtables that are not
306 * compatible with older compilers. To prevent older plugins from
307 * not understanding a new browser's ABI, these masks change the
308 * values of those selectors on those platforms. To remain backwards
309 * compatible with different versions of the browser, plugins can
310 * use these masks to dynamically determine and use the correct C++
311 * ABI that the browser is expecting. This does not apply to Windows
312 * as Microsoft's COM ABI will likely not change.
315 #define NP_ABI_GCC3_MASK 0x10000000
317 * gcc 3.x generated vtables on UNIX and OSX are incompatible with
318 * previous compilers.
320 #if defined(XP_UNIX) && defined(__GNUC__)
321 #define _NP_ABI_MIXIN_FOR_GCC3 NP_ABI_GCC3_MASK
323 #define _NP_ABI_MIXIN_FOR_GCC3 0
326 #if defined(XP_MACOSX)
327 #define NP_ABI_MACHO_MASK 0x01000000
328 #define _NP_ABI_MIXIN_FOR_MACHO NP_ABI_MACHO_MASK
330 #define _NP_ABI_MIXIN_FOR_MACHO 0
333 #define NP_ABI_MASK (_NP_ABI_MIXIN_FOR_GCC3 | _NP_ABI_MIXIN_FOR_MACHO)
336 * List of variable names for which NPP_GetValue shall be implemented
339 NPPVpluginNameString
= 1,
340 NPPVpluginDescriptionString
,
341 NPPVpluginWindowBool
,
342 NPPVpluginTransparentBool
,
344 NPPVpluginWindowSize
,
345 NPPVpluginTimerInterval
,
346 NPPVpluginScriptableInstance
= (10 | NP_ABI_MASK
),
347 NPPVpluginScriptableIID
= 11,
348 NPPVjavascriptPushCallerBool
= 12,
349 NPPVpluginKeepLibraryInMemory
= 13,
350 NPPVpluginNeedsXEmbed
= 14,
352 /* Get the NPObject for scripting the plugin. Introduced in NPAPI minor version 14.
354 NPPVpluginScriptableNPObject
= 15,
356 /* Get the plugin value (as \0-terminated UTF-8 string data) for
357 * form submission if the plugin is part of a form. Use
358 * NPN_MemAlloc() to allocate memory for the string data. Introduced
359 * in NPAPI minor version 15.
363 NPPVpluginUrlRequestsDisplayedBool
= 17,
365 /* Checks if the plugin is interested in receiving the http body of
366 * all http requests (including failed ones, http status != 200).
368 NPPVpluginWantsAllNetworkStreams
= 18,
370 /* Browsers can retrieve a native ATK accessibility plug ID via this variable. */
371 NPPVpluginNativeAccessibleAtkPlugId
= 19,
373 /* Checks to see if the plug-in would like the browser to load the "src" attribute. */
374 NPPVpluginCancelSrcStream
= 20,
376 NPPVSupportsAdvancedKeyHandling
= 21
378 #if defined(XP_MACOSX)
379 /* Used for negotiating drawing models */
380 , NPPVpluginDrawingModel
= 1000
381 /* Used for negotiating event models */
382 , NPPVpluginEventModel
= 1001
383 /* In the NPDrawingModelCoreAnimation drawing model, the browser asks the plug-in for a Core Animation layer. */
384 , NPPVpluginCoreAnimationLayer
= 1003
387 #if defined(MOZ_PLATFORM_MAEMO) && ((MOZ_PLATFORM_MAEMO == 5) || (MOZ_PLATFORM_MAEMO == 6))
388 , NPPVpluginWindowlessLocalBool
= 2002
393 * List of variable names for which NPN_GetValue should be implemented.
399 NPNVjavascriptEnabledBool
,
403 NPNVserviceManager
= (10 | NP_ABI_MASK
),
404 NPNVDOMElement
= (11 | NP_ABI_MASK
),
405 NPNVDOMWindow
= (12 | NP_ABI_MASK
),
406 NPNVToolkit
= (13 | NP_ABI_MASK
),
407 NPNVSupportsXEmbedBool
= 14,
409 /* Get the NPObject wrapper for the browser window. */
410 NPNVWindowNPObject
= 15,
412 /* Get the NPObject wrapper for the plugins DOM element. */
413 NPNVPluginElementNPObject
= 16,
415 NPNVSupportsWindowless
= 17,
417 NPNVprivateModeBool
= 18,
419 NPNVsupportsAdvancedKeyHandling
= 21
421 #if defined(XP_MACOSX)
422 /* Used for negotiating drawing models */
423 , NPNVpluginDrawingModel
= 1000
424 #ifndef NP_NO_QUICKDRAW
425 , NPNVsupportsQuickDrawBool
= 2000
427 , NPNVsupportsCoreGraphicsBool
= 2001
428 , NPNVsupportsOpenGLBool
= 2002
429 , NPNVsupportsCoreAnimationBool
= 2003
430 , NPNVsupportsInvalidatingCoreAnimationBool
= 2004
432 , NPNVsupportsCarbonBool
= 3000 /* TRUE if the browser supports the Carbon event model */
434 , NPNVsupportsCocoaBool
= 3001 /* TRUE if the browser supports the Cocoa event model */
435 , NPNVsupportsUpdatedCocoaTextInputBool
= 3002 /* TRUE if the browser supports the updated
436 Cocoa text input specification. */
438 #if defined(MOZ_PLATFORM_MAEMO) && ((MOZ_PLATFORM_MAEMO == 5) || (MOZ_PLATFORM_MAEMO == 6))
439 , NPNVSupportsWindowlessLocal
= 2002
449 * The type of Toolkit the widgets use
457 * The type of a NPWindow - it specifies the type of the data structure
458 * returned in the window field.
461 NPWindowTypeWindow
= 1,
465 typedef struct _NPWindow
467 void* window
; /* Platform specific window handle */
468 /* OS/2: x - Position of bottom left corner */
469 /* OS/2: y - relative to visible netscape window */
470 int32_t x
; /* Position of top left corner relative */
471 int32_t y
; /* to a netscape page. */
472 uint32_t width
; /* Maximum window size */
474 NPRect clipRect
; /* Clipping rectangle in port coordinates */
475 #if (defined(XP_UNIX) || defined(XP_SYMBIAN)) && !defined(XP_MACOSX)
476 void * ws_info
; /* Platform-dependent additional data */
478 NPWindowType type
; /* Is this a window or a drawable? */
481 typedef struct _NPImageExpose
483 char* data
; /* image pointer */
484 int32_t stride
; /* Stride of data image pointer */
485 int32_t depth
; /* Depth of image pointer */
486 int32_t x
; /* Expose x */
487 int32_t y
; /* Expose y */
488 uint32_t width
; /* Expose width */
489 uint32_t height
; /* Expose height */
490 NPSize dataSize
; /* Data buffer size */
491 float translateX
; /* translate X matrix value */
492 float translateY
; /* translate Y matrix value */
493 float scaleX
; /* scale X matrix value */
494 float scaleY
; /* scale Y matrix value */
497 typedef struct _NPFullPrint
499 NPBool pluginPrinted
;/* Set TRUE if plugin handled fullscreen printing */
500 NPBool printOne
; /* TRUE if plugin should print one copy to default
502 void* platformPrint
; /* Platform-specific printing info */
505 typedef struct _NPEmbedPrint
508 void* platformPrint
; /* Platform-specific printing info */
511 typedef struct _NPPrint
513 uint16_t mode
; /* NP_FULL or NP_EMBED */
516 NPFullPrint fullPrint
; /* if mode is NP_FULL */
517 NPEmbedPrint embedPrint
; /* if mode is NP_EMBED */
521 #if defined(XP_MACOSX)
523 typedef EventRecord NPEvent
;
525 #elif defined(XP_SYMBIAN)
526 typedef QEvent NPEvent
;
527 #elif defined(XP_WIN)
528 typedef struct _NPEvent
534 #elif defined(XP_OS2)
535 typedef struct _NPEvent
541 #elif defined(XP_UNIX) && defined(MOZ_X11)
542 typedef XEvent NPEvent
;
544 typedef void* NPEvent
;
547 #if defined(XP_MACOSX)
548 typedef void* NPRegion
;
549 #ifndef NP_NO_QUICKDRAW
550 typedef RgnHandle NPQDRegion
;
552 typedef CGPathRef NPCGRegion
;
553 #elif defined(XP_WIN)
554 typedef HRGN NPRegion
;
555 #elif defined(XP_UNIX) && defined(MOZ_X11)
556 typedef Region NPRegion
;
557 #elif defined(XP_SYMBIAN)
558 typedef QRegion
* NPRegion
;
560 typedef void *NPRegion
;
563 typedef struct _NPNSString NPNSString
;
564 typedef struct _NPNSWindow NPNSWindow
;
565 typedef struct _NPNSMenu NPNSMenu
;
567 #if defined(XP_MACOSX)
568 typedef NPNSMenu NPMenu
;
570 typedef void *NPMenu
;
574 NPCoordinateSpacePlugin
= 1,
575 NPCoordinateSpaceWindow
,
576 NPCoordinateSpaceFlippedWindow
,
577 NPCoordinateSpaceScreen
,
578 NPCoordinateSpaceFlippedScreen
581 #if defined(XP_MACOSX)
583 #ifndef NP_NO_QUICKDRAW
584 typedef struct NP_Port
587 int32_t portx
; /* position inside the topmost window */
590 #endif /* NP_NO_QUICKDRAW */
593 * NP_CGContext is the type of the NPWindow's 'window' when the plugin specifies NPDrawingModelCoreGraphics
594 * as its drawing model.
597 typedef struct NP_CGContext
599 CGContextRef context
;
600 void *window
; /* A WindowRef under the Carbon event model. */
604 * NP_GLContext is the type of the NPWindow's 'window' when the plugin specifies NPDrawingModelOpenGL as its
608 typedef struct NP_GLContext
610 CGLContextObj context
;
614 void *window
; /* Can be either an NSWindow or a WindowRef depending on the event model */
619 NPCocoaEventDrawRect
= 1,
620 NPCocoaEventMouseDown
,
622 NPCocoaEventMouseMoved
,
623 NPCocoaEventMouseEntered
,
624 NPCocoaEventMouseExited
,
625 NPCocoaEventMouseDragged
,
628 NPCocoaEventFlagsChanged
,
629 NPCocoaEventFocusChanged
,
630 NPCocoaEventWindowFocusChanged
,
631 NPCocoaEventScrollWheel
,
632 NPCocoaEventTextInput
635 typedef struct _NPCocoaEvent
{
636 NPCocoaEventType type
;
640 uint32_t modifierFlags
;
643 int32_t buttonNumber
;
650 uint32_t modifierFlags
;
651 NPNSString
*characters
;
652 NPNSString
*charactersIgnoringModifiers
;
657 CGContextRef context
;
673 /* Non-standard event types that can be passed to HandleEvent */
675 NPEventType_GetFocusEvent
= (osEvt
+ 16),
676 NPEventType_LoseFocusEvent
,
677 NPEventType_AdjustCursorEvent
,
678 NPEventType_MenuCommandEvent
,
679 NPEventType_ClippingChangedEvent
,
680 NPEventType_ScrollingBeginsEvent
= 1000,
681 NPEventType_ScrollingEndsEvent
683 #endif /* NP_NO_CARBON */
685 #endif /* XP_MACOSX */
688 * Values for mode passed to NPP_New:
694 * Values for stream type passed to NPP_NewStream:
699 #define NP_ASFILEONLY 4
701 #define NP_MAXREADY (((unsigned)(~0)<<1)>>1)
704 * Flags for NPP_ClearSiteData.
706 #define NP_CLEAR_ALL 0
707 #define NP_CLEAR_CACHE (1 << 0)
709 #if !defined(__LP64__)
710 #if defined(XP_MACOSX)
711 #pragma options align=reset
713 #endif /* __LP64__ */
715 /*----------------------------------------------------------------------*/
716 /* Error and Reason Code definitions */
717 /*----------------------------------------------------------------------*/
720 * Values of type NPError:
723 #define NPERR_NO_ERROR (NPERR_BASE + 0)
724 #define NPERR_GENERIC_ERROR (NPERR_BASE + 1)
725 #define NPERR_INVALID_INSTANCE_ERROR (NPERR_BASE + 2)
726 #define NPERR_INVALID_FUNCTABLE_ERROR (NPERR_BASE + 3)
727 #define NPERR_MODULE_LOAD_FAILED_ERROR (NPERR_BASE + 4)
728 #define NPERR_OUT_OF_MEMORY_ERROR (NPERR_BASE + 5)
729 #define NPERR_INVALID_PLUGIN_ERROR (NPERR_BASE + 6)
730 #define NPERR_INVALID_PLUGIN_DIR_ERROR (NPERR_BASE + 7)
731 #define NPERR_INCOMPATIBLE_VERSION_ERROR (NPERR_BASE + 8)
732 #define NPERR_INVALID_PARAM (NPERR_BASE + 9)
733 #define NPERR_INVALID_URL (NPERR_BASE + 10)
734 #define NPERR_FILE_NOT_FOUND (NPERR_BASE + 11)
735 #define NPERR_NO_DATA (NPERR_BASE + 12)
736 #define NPERR_STREAM_NOT_SEEKABLE (NPERR_BASE + 13)
737 #define NPERR_TIME_RANGE_NOT_SUPPORTED (NPERR_BASE + 14)
738 #define NPERR_MALFORMED_SITE (NPERR_BASE + 15)
741 * Values of type NPReason:
744 #define NPRES_DONE (NPRES_BASE + 0)
745 #define NPRES_NETWORK_ERR (NPRES_BASE + 1)
746 #define NPRES_USER_BREAK (NPRES_BASE + 2)
749 * Version feature information
751 #define NPVERS_HAS_STREAMOUTPUT 8
752 #define NPVERS_HAS_NOTIFICATION 9
753 #define NPVERS_HAS_LIVECONNECT 9
754 #define NPVERS_68K_HAS_LIVECONNECT 11
755 #define NPVERS_HAS_WINDOWLESS 11
756 #define NPVERS_HAS_XPCONNECT_SCRIPTING 13
757 #define NPVERS_HAS_NPRUNTIME_SCRIPTING 14
758 #define NPVERS_HAS_FORM_VALUES 15
759 #define NPVERS_HAS_POPUPS_ENABLED_STATE 16
760 #define NPVERS_HAS_RESPONSE_HEADERS 17
761 #define NPVERS_HAS_NPOBJECT_ENUM 18
762 #define NPVERS_HAS_PLUGIN_THREAD_ASYNC_CALL 19
763 #define NPVERS_HAS_ALL_NETWORK_STREAMS 20
764 #define NPVERS_HAS_URL_AND_AUTH_INFO 21
765 #define NPVERS_HAS_PRIVATE_MODE 22
766 #define NPVERS_MACOSX_HAS_COCOA_EVENTS 23
767 #define NPVERS_HAS_ADVANCED_KEY_HANDLING 25
768 #define NPVERS_HAS_URL_REDIRECT_HANDLING 26
769 #define NPVERS_HAS_CLEAR_SITE_DATA 27
771 /*----------------------------------------------------------------------*/
772 /* Function Prototypes */
773 /*----------------------------------------------------------------------*/
776 #define NP_LOADDS _System
785 /* NPP_* functions are provided by the plugin and called by the navigator. */
787 const char* NPP_GetMIMEDescription(void);
788 NPError NP_LOADDS
NPP_New(NPMIMEType pluginType
, NPP instance
,
789 uint16_t mode
, int16_t argc
, char* argn
[],
790 char* argv
[], NPSavedData
* saved
);
791 NPError NP_LOADDS
NPP_Destroy(NPP instance
, NPSavedData
** save
);
792 NPError NP_LOADDS
NPP_SetWindow(NPP instance
, NPWindow
* window
);
793 NPError NP_LOADDS
NPP_NewStream(NPP instance
, NPMIMEType type
,
794 NPStream
* stream
, NPBool seekable
,
796 NPError NP_LOADDS
NPP_DestroyStream(NPP instance
, NPStream
* stream
,
798 int32_t NP_LOADDS
NPP_WriteReady(NPP instance
, NPStream
* stream
);
799 int32_t NP_LOADDS
NPP_Write(NPP instance
, NPStream
* stream
, int32_t offset
,
800 int32_t len
, void* buffer
);
801 void NP_LOADDS
NPP_StreamAsFile(NPP instance
, NPStream
* stream
,
803 void NP_LOADDS
NPP_Print(NPP instance
, NPPrint
* platformPrint
);
804 int16_t NP_LOADDS
NPP_HandleEvent(NPP instance
, void* event
);
805 void NP_LOADDS
NPP_URLNotify(NPP instance
, const char* url
,
806 NPReason reason
, void* notifyData
);
807 NPError NP_LOADDS
NPP_GetValue(NPP instance
, NPPVariable variable
, void *value
);
808 NPError NP_LOADDS
NPP_SetValue(NPP instance
, NPNVariable variable
, void *value
);
809 NPBool NP_LOADDS
NPP_GotFocus(NPP instance
, NPFocusDirection direction
);
810 void NP_LOADDS
NPP_LostFocus(NPP instance
);
811 void NP_LOADDS
NPP_URLRedirectNotify(NPP instance
, const char* url
, int32_t status
, void* notifyData
);
812 NPError NP_LOADDS
NPP_ClearSiteData(const char* site
, uint64_t flags
, uint64_t maxAge
);
813 char** NP_LOADDS
NPP_GetSitesWithData(void);
815 /* NPN_* functions are provided by the navigator and called by the plugin. */
816 void NP_LOADDS
NPN_Version(int* plugin_major
, int* plugin_minor
,
817 int* netscape_major
, int* netscape_minor
);
818 NPError NP_LOADDS
NPN_GetURLNotify(NPP instance
, const char* url
,
819 const char* target
, void* notifyData
);
820 NPError NP_LOADDS
NPN_GetURL(NPP instance
, const char* url
,
822 NPError NP_LOADDS
NPN_PostURLNotify(NPP instance
, const char* url
,
823 const char* target
, uint32_t len
,
824 const char* buf
, NPBool file
,
826 NPError NP_LOADDS
NPN_PostURL(NPP instance
, const char* url
,
827 const char* target
, uint32_t len
,
828 const char* buf
, NPBool file
);
829 NPError NP_LOADDS
NPN_RequestRead(NPStream
* stream
, NPByteRange
* rangeList
);
830 NPError NP_LOADDS
NPN_NewStream(NPP instance
, NPMIMEType type
,
831 const char* target
, NPStream
** stream
);
832 int32_t NP_LOADDS
NPN_Write(NPP instance
, NPStream
* stream
, int32_t len
,
834 NPError NP_LOADDS
NPN_DestroyStream(NPP instance
, NPStream
* stream
,
836 void NP_LOADDS
NPN_Status(NPP instance
, const char* message
);
837 const char* NP_LOADDS
NPN_UserAgent(NPP instance
);
838 void* NP_LOADDS
NPN_MemAlloc(uint32_t size
);
839 void NP_LOADDS
NPN_MemFree(void* ptr
);
840 uint32_t NP_LOADDS
NPN_MemFlush(uint32_t size
);
841 void NP_LOADDS
NPN_ReloadPlugins(NPBool reloadPages
);
842 NPError NP_LOADDS
NPN_GetValue(NPP instance
, NPNVariable variable
,
844 NPError NP_LOADDS
NPN_SetValue(NPP instance
, NPPVariable variable
,
846 void NP_LOADDS
NPN_InvalidateRect(NPP instance
, NPRect
*invalidRect
);
847 void NP_LOADDS
NPN_InvalidateRegion(NPP instance
,
848 NPRegion invalidRegion
);
849 void NP_LOADDS
NPN_ForceRedraw(NPP instance
);
850 void NP_LOADDS
NPN_PushPopupsEnabledState(NPP instance
, NPBool enabled
);
851 void NP_LOADDS
NPN_PopPopupsEnabledState(NPP instance
);
852 void NP_LOADDS
NPN_PluginThreadAsyncCall(NPP instance
,
853 void (*func
) (void *),
855 NPError NP_LOADDS
NPN_GetValueForURL(NPP instance
, NPNURLVariable variable
,
856 const char *url
, char **value
,
858 NPError NP_LOADDS
NPN_SetValueForURL(NPP instance
, NPNURLVariable variable
,
859 const char *url
, const char *value
,
861 NPError NP_LOADDS
NPN_GetAuthenticationInfo(NPP instance
,
862 const char *protocol
,
863 const char *host
, int32_t port
,
866 char **username
, uint32_t *ulen
,
869 uint32_t NP_LOADDS
NPN_ScheduleTimer(NPP instance
, uint32_t interval
, NPBool repeat
, void (*timerFunc
)(NPP npp
, uint32_t timerID
));
870 void NP_LOADDS
NPN_UnscheduleTimer(NPP instance
, uint32_t timerID
);
871 NPError NP_LOADDS
NPN_PopUpContextMenu(NPP instance
, NPMenu
* menu
);
872 NPBool NP_LOADDS
NPN_ConvertPoint(NPP instance
, double sourceX
, double sourceY
, NPCoordinateSpace sourceSpace
, double *destX
, double *destY
, NPCoordinateSpace destSpace
);
873 NPBool NP_LOADDS
NPN_HandleEvent(NPP instance
, void *event
, NPBool handled
);
874 NPBool NP_LOADDS
NPN_UnfocusInstance(NPP instance
, NPFocusDirection direction
);
875 void NP_LOADDS
NPN_URLRedirectResponse(NPP instance
, void* notifyData
, NPBool allow
);
878 } /* end extern "C" */
881 #endif /* RC_INVOKED */
886 #endif /* npapi_h_ */