]> git.sesse.net Git - vlc/blob - modules/gui/qt4/components/vistaassoc.h
1438c10e6e37f66427e7b25322d07f5a5cfd94bb
[vlc] / modules / gui / qt4 / components / vistaassoc.h
1 /*****************************************************************************
2  * vistaext.h : "Vista file associations support"
3  ****************************************************************************
4  * Copyright (C) 2006-2008 the VideoLAN team
5  * $Id$
6  *
7  * Authors: Geoffroy Couprie <geal@videolan.org>
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
22  *****************************************************************************/
23
24 #ifndef VISTAASSOC_H
25 #define VISTAASSOC_H
26
27 const GUID clsid_IApplication2 = { 0x1968106d,0xf3b5,0x44cf,{0x89,0x0e,0x11,0x6f,0xcb,0x9e,0xce,0xf1}};
28 const GUID IID_IApplicationAssociationRegistrationUI = {0x1f76a169,0xf994,0x40ac, {0x8f,0xc8,0x09,0x59,0xe8,0x87,0x47,0x10}};
29
30 #undef IUnknown
31 typedef struct _IUnknown IUnknown;
32 typedef struct _IApplicationAssociationRegistrationUI IApplicationAssociationRegistrationUI;
33
34 typedef struct IUnknown_vt
35 {
36     long (STDCALL *QueryInterface)(IUnknown *This, const GUID *riid,
37                                    void **ppvObject);
38     long (STDCALL *AddRef)(IUnknown *This);
39     long (STDCALL *Release)(IUnknown *This);
40
41 } IUnknown_vt;
42 struct _IUnknown { IUnknown_vt* vt; };
43 typedef IUnknown *LPUNKNOWN;
44
45 typedef struct IApplicationAssociationRegistrationUI_vt
46 {
47     /* IUnknown methods */
48     long (STDCALL *QueryInterface)(IUnknown *This, const GUID *riid,
49                                    void **ppvObject);
50     long (STDCALL *AddRef)(IUnknown *This);
51     long (STDCALL *Release)(IUnknown *This);
52     long (STDCALL *LaunchAdvancedAssociationUI)(IApplicationAssociationRegistrationUI *This, LPCWSTR app);
53 } IApplicationAssociationRegistrationUI_vt;
54 struct _IApplicationAssociationRegistrationUI { IApplicationAssociationRegistrationUI_vt* vt; };
55 typedef IApplicationAssociationRegistrationUI *LPAPPASSOCREGUI, *PAPPASSOCREGUI;
56
57 #define CLSCTX_INPROC_SERVER 1
58 typedef GUID IID;
59 #define REFIID const IID* const
60
61 extern "C" {
62     HRESULT WINAPI CoCreateInstance(const GUID *,LPUNKNOWN,DWORD,REFIID,PVOID*);         
63     HRESULT WINAPI CoInitialize(PVOID);
64     void WINAPI CoUninitialize(void);
65 };
66
67 #endif //VISTAASSOC_H