⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 shareaza.idl

📁 著名的下载软件核心Shareaza
💻 IDL
📖 第 1 页 / 共 2 页
字号:
//
// Shareaza.odl
//
// Copyright (c) Shareaza Development Team, 2002-2004.
// This file is part of SHAREAZA (www.shareaza.com)
//
// Shareaza is free software; you can redistribute it
// and/or modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2 of
// the License, or (at your option) any later version.
//
// Shareaza is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Shareaza; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
//

[ uuid(E3481FE3-E062-4E1C-A23A-62A6D13CBFB8), version(1.0) ]
library Shareaza
{
	importlib("stdole32.tlb");

	interface IApplication;
	
	//
	// Common Data Types
	//

	typedef enum
	{
		TSUNKNOWN, TSTRUE, TSFALSE
	} STRISTATE;

	//
	// XML Object Model
	//

	interface ISXMLNode;
	interface ISXMLElement;
	interface ISXMLElements;
	interface ISXMLAttribute;
	interface ISXMLAttributes;

	typedef enum
	{
		xmlNode, xmlElement, xmlAttribute
	} SXMLNodeType;

	[ uuid(A0F89545-DAD8-4441-9DF4-BCB106B12234), dual, oleautomation ]
	interface ISXMLNode : IDispatch
	{
		[id(1),propget] HRESULT Parent( [out,retval] ISXMLElement** ppParent );
		[id(2),propget] HRESULT Type( [out,retval] SXMLNodeType* pnType );
		[id(3),propget] HRESULT AsNode( [out,retval] ISXMLNode** ppNode );
		[id(4),propget] HRESULT AsElement( [out,retval] ISXMLNode** ppElement );
		[id(5),propget] HRESULT AsAttribute( [out,retval] ISXMLNode** ppAttribute );
		[id(6),propget] HRESULT Name( [out,retval] BSTR* psName );
		[id(6),propput] HRESULT Name( [in] BSTR sName );
		[id(0),propget] HRESULT Value( [out,retval] BSTR* psValue );
		[id(0),propput] HRESULT Value( [in] BSTR sValue );

		[id(10)] HRESULT Delete();
		[id(11)] HRESULT IsNamed( [in] BSTR sName, [out,retval] VARIANT_BOOL* pbResult );

	};
	
	[ uuid(5198A470-F9EE-49eb-948C-F8176610A8B2), dual, oleautomation ]
	interface ISXMLElement : ISXMLNode
	{
		[id(20),propget] HRESULT Elements( [out,retval] ISXMLElements** ppElements );
		[id(21),propget] HRESULT Attributes( [out,retval] ISXMLAttributes** ppAttributes );

		[id(30)] HRESULT Detach();
		[id(31)] HRESULT Clone( [out,retval] ISXMLElement** ppClone );
		[id(32)] HRESULT ToString( [out,retval] BSTR* psValue );
		[id(33)] HRESULT ToStringEx( [in] VARIANT_BOOL bHeader, [in] VARIANT_BOOL bNewlines, [out,retval] BSTR* psValue );
		[id(34)] HRESULT FromString( [in] BSTR sXML, [out,retval] ISXMLElement** ppElement );
		[id(35)] HRESULT GetWords( [out,retval] BSTR* psWords );
	};
	
	[ uuid(6D4598A7-26A1-4990-BA60-DE0E212AF93C), dual, oleautomation ]
	interface ISXMLAttribute : ISXMLNode
	{
		[id(30)] HRESULT Detach();
		[id(31)] HRESULT Clone( [out,retval] ISXMLAttribute** ppClone );
	};
	
	[ uuid(10BF271C-85A3-4ad4-8930-CC0E3CEEADA4), dual, oleautomation ]
	interface ISXMLElements : IDispatch
	{
		[id(-4),propget,restricted] HRESULT _NewEnum( [out,retval] IUnknown** ppEnum );
		[id(0),propget] HRESULT Item( [in] VARIANT vIndex, [out,retval] ISXMLElement** ppElement );
		[id(1),propget] HRESULT Count( [out,retval] LONG* pnCount );
		[id(2)] HRESULT Create( [in] BSTR strName, [out,retval] ISXMLElement** ppElement );
		[id(3)] HRESULT Attach( [in] ISXMLElement* pElement );
		[id(4)] HRESULT RemoveAll();
		[id(5),propget] HRESULT First( [out,retval] ISXMLElement** ppElement );
		[id(6),propget] HRESULT ByName( [in] BSTR sName, [out,retval] ISXMLElement** ppElement );
	};
	
	[ uuid(8E03E1BF-CCC0-4616-9C0D-8204A83BAEB4), dual, oleautomation ]
	interface ISXMLAttributes : IDispatch
	{
		[id(-4),propget,restricted] HRESULT _NewEnum( [out,retval] IUnknown** ppEnum );
		[id(0),propget] HRESULT Item( [in] VARIANT vIndex, [out,retval] ISXMLAttribute** ppAttribute );
		[id(1),propget] HRESULT Count( [out,retval] LONG* pnCount );
		[id(2)] HRESULT Add( [in] BSTR strName, [in] BSTR strValue );
		[id(3)] HRESULT Create( [in] BSTR strName, [out,retval] ISXMLAttribute** ppAttribute );
		[id(4)] HRESULT Attach( [in] ISXMLAttribute* pAttribute );
		[id(5)] HRESULT RemoveAll();
		[id(6),propget] HRESULT ByName( [in] BSTR sName, [out,retval] ISXMLAttribute** ppAttribute );
		[id(7),propget] HRESULT Get( [in] BSTR sName, [out,retval] BSTR* psValue );
	};
	
	//
	// General Plugin Support
	//
	
	[ uuid(D1B5D3A4-B890-470a-A3FF-9700F3C2A063) ]
	interface IGeneralPlugin : IUnknown
	{
		HRESULT SetApplication( [in] IApplication* pApplication );
		HRESULT QueryCapabilities( [out] DWORD* pnCaps );
		HRESULT Configure();
		HRESULT OnSkinChanged();
	};
	
	//
	// Command Plugin
	//
	
	[ uuid(CB25DAED-D745-45db-994E-32639D2888A9) ]
	interface ICommandPlugin : IUnknown
	{
		HRESULT RegisterCommands();
		HRESULT InsertCommands();
		HRESULT OnUpdate( [in] UINT nCommandID, [in,out] STristate* pbVisible, [in,out] STristate* pbEnabled, [in,out] STristate* pbChecked );
		HRESULT OnCommand( [in] UINT nCommandID );
	};

	//
	// Execute Plugin
	//
	
	[ uuid(8E878640-37B5-44a3-A37C-FC3BF1CCF6B6) ]
	interface IExecutePlugin : IUnknown
	{
		HRESULT OnExecute( [in] BSTR sFilePath );
		HRESULT OnEnqueue( [in] BSTR sFilePath );
	};

	//
	// Window Plugin
	//

	interface ISToolbar;

	[ uuid(ADDB77AE-3483-4a15-B391-AE31563BD7E3) ]
	interface IPluginWindow : IUnknown
	{
		HRESULT ListenForSingleMessage( [in] UINT nMessage );
		HRESULT ListenForMultipleMessages( [in] SAFEARRAY* pMessages );
		HRESULT Create1( [in] BSTR bsCaption, [in] HICON hIcon, [in] VARIANT_BOOL bPanel, [in] VARIANT_BOOL bTabbed );
		HRESULT Create2( [in] UINT nCommandID, [in] VARIANT_BOOL bPanel, [in] VARIANT_BOOL bTabbed );
		HRESULT GetHwnd( [out] HWND* phWnd );
		HRESULT HandleMessage( [out] LRESULT* plResult );
		HRESULT LoadState( [in] VARIANT_BOOL bMaximise );
		HRESULT SaveState();
		HRESULT ThrowMenu( [in] BSTR sName, [in] LONG nDefaultID, [in] POINT* pPoint );
		HRESULT AddToolbar( [in] BSTR sName, [in] LONG nPosition, [out] HWND* phWnd, [out,retval] ISToolbar** ppToolbar );
		HRESULT AdjustWindowRect( [in,out] RECT* pRect, [in] VARIANT_BOOL bClientToWindow );
	};
	
	[ uuid(C6631461-2654-4572-BB3C-54F52F0FF1B9) ]
	interface IPluginWindowOwner : IUnknown
	{
		HRESULT OnTranslate( [in] MSG* pMessage );
		HRESULT OnMessage( [in] UINT nMessage, [in] WPARAM wParam, [in] LPARAM lParam, [out] LRESULT* plResult );
		HRESULT OnUpdate( [in] UINT nCommandID, [in,out] STristate* pbVisible, [in,out] STristate* pbEnabled, [in,out] STristate* pbChecked );
		HRESULT OnCommand( [in] UINT nCommandID );
	};

	//
	// LibraryBuilder Plugin
	//

	[ uuid(32496CEA-3B51-4f2f-9CE7-73D6AC942C34) ]
	interface ILibraryBuilderPlugin : IUnknown
	{
		HRESULT Process( [in] HANDLE hFile, [in] BSTR sFile, [in] ISXMLElement* pXML );
	};
	
	//
	// ImageService Plugin
	//

	typedef struct
	{
		int cbSize;
		int nFlags;
		int nWidth;
		int nHeight;
		int nComponents;
		int nQuality;
	} IMAGESERVICEDATA;
	
	typedef enum
	{
		IMAGESERVICE_SCANONLY		= 0x01,
		IMAGESERVICE_PARTIAL_IN		= 0x02,
		IMAGESERVICE_PARTIAL_OUT	= 0x04
	} IMAGESERVICEFLAGS;
	
	[ uuid(AD49786E-09C1-4069-B48A-15AD42D6CED1) ]
	interface IImageServicePlugin : IUnknown
	{
		HRESULT LoadFromFile( [in] HANDLE hFile, [in] DWORD nLength, [in,out] IMAGESERVICEDATA* pParams, [out] SAFEARRAY** ppImage );
		HRESULT LoadFromMemory( [in] SAFEARRAY* pMemory, [in,out] IMAGESERVICEDATA* pParams, [out] SAFEARRAY** ppImage );
		HRESULT SaveToFile( [in] HANDLE hFile, [in,out] IMAGESERVICEDATA* pParams, [in] SAFEARRAY* pImage);
		HRESULT SaveToMemory( [out] SAFEARRAY** ppMemory, [in,out] IMAGESERVICEDATA* pParams, [in] SAFEARRAY* pImage);
	};
	
	//
	// DownloadPreview Plugin
	//

	[ uuid(52A97CBD-2B99-45e8-B6F9-41E9CD583960) ]
	interface IDownloadPreviewSite : IUnknown
	{
		HRESULT GetSuggestedFilename( [out,retval] BSTR* psFile );
		HRESULT GetAvailableRanges( [out,retval] SAFEARRAY **pArray );
		HRESULT SetProgressRange( [in] DWORD nRange );
		HRESULT SetProgressPosition( [in] DWORD nPosition );
		HRESULT SetProgressMessage( [in] BSTR sMessage );
		HRESULT QueueDeleteFile( [in] BSTR sTempFile );
		HRESULT ExecuteFile( [in] BSTR sFile );
	};

	[ uuid(1182FCD9-9F14-4e4a-BD05-432422B5BFAF) ]
	interface IDownloadPreviewPlugin : IUnknown
	{
		HRESULT SetSite( [in] IDownloadPreviewSite* pSite );
		HRESULT Preview( [in] HANDLE hFile, [in] BSTR sFile );
		HRESULT Cancel();
	};

	//
	// MediaPlayer Plugin
	//

	interface IAudioVisPlugin;
	
	typedef enum
	{
		smsNull, smsOpen, smsPaused, smsPlaying
	} MediaState;

	typedef enum
	{
		smaDefault = 0,
		smzDistort = -1, smzFill = 0, smzOne = 1, smzDouble = 2,
	} MediaZoom;

	[ uuid(59978299-C8AC-4818-83F4-C382BB611D5C), pointer_default(unique) ]
	interface IMediaPlayer : IUnknown
	{
		HRESULT Create( [in] HWND hWnd );
		HRESULT Destroy();
		HRESULT Reposition( [in] RECT* prcWnd );
		HRESULT SetLogoBitmap( [in] HBITMAP hLogo );
		
		HRESULT GetVolume( [out] DOUBLE* pnVolume );
		HRESULT SetVolume( [in] DOUBLE nVolume );
		HRESULT GetZoom( [out] MediaZoom* pnZoom );
		HRESULT SetZoom( [in] MediaZoom nZoom );
		HRESULT GetAspect( [out] DOUBLE* pnAspect );
		HRESULT SetAspect( [in] DOUBLE nAspect );
		
		HRESULT Open( [in] BSTR sFilename );
		HRESULT Close();
		
		HRESULT Play();
		HRESULT Pause();

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -