winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
January 2011
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
879 discussions
Start a n
N
ew thread
Hwang YunSong : wineboot: Update Korean resource.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 183b89b689f499fa2fbb1321261e43a41571f1e1 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=183b89b689f499fa2fbb13212…
Author: Hwang YunSong <hys545(a)dreamwiz.com> Date: Wed Jan 5 10:31:53 2011 +0900 wineboot: Update Korean resource. --- programs/wineboot/wineboot_Ko.rc | 16 +++++++++------- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/programs/wineboot/wineboot_Ko.rc b/programs/wineboot/wineboot_Ko.rc index b792fbe..f153ccd 100644 --- a/programs/wineboot/wineboot_Ko.rc +++ b/programs/wineboot/wineboot_Ko.rc @@ -2,7 +2,7 @@ * WineBoot Korean resources * * Copyright (C) 2007 Robert Shearman for CodeWeavers - * Copyright (C) 2007 YunSong Hwang(hys545(a)dreamwiz.com, Ȳ����) + * Copyright (C) 2007,2011 YunSong Hwang * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -22,19 +22,21 @@ #include "resource.h" +#pragma code_page(65001) + LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_ENDTASK DIALOG 0, 0, 186, 71 STYLE DS_MODALFRAME | DS_NOIDLEMSG | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "���α� �����" +CAPTION "프로그램 대기중" FONT 9, "MS Shell Dlg" BEGIN - DEFPUSHBUTTON "���",IDCANCEL,129,49,50,15 - PUSHBUTTON "���μ��� ������",IDOK,51,49,71,15 - LTEXT "�� ���μ����� �α� ������ ���Ḧ �õ�������, �� ���α��� �ƹ��� ������ �����ϴ�.", + DEFPUSHBUTTON "취소",IDCANCEL,129,49,50,15 + PUSHBUTTON "프로세스 끝내기",IDOK,51,49,71,15 + LTEXT "이 프로세스에 로그 오프나 종료를 시도했으나, 이 프로그램은 아무런 반응이 없습니다.", IDC_STATIC,7,5,172,26 - LTEXT "���� ����� �� ���μ����� �����ٸ� ���� ���� ���� ��� ������ �Ҿ���� ���Դϴ�.", + LTEXT "만약 당신이 이 프로세스를 끝낸다면 저장 하지 않은 모든 데이터를 잃어버릴 것입니다.", IDC_STATIC,7,28,172,21 END @@ -44,6 +46,6 @@ CAPTION "Wine" FONT 8, "MS Shell Dlg" BEGIN ICON "", IDC_WAITICON, 3, 3, 10, 10 - LTEXT "Wine ���� %s �� ������Ʈ�Ǵ� ���Դϴ�, ��ø� ��ٷ��ֽñ� �ٶ��ϴ�...", + LTEXT "Wine 설정 %s 이 업데이트되는 중입니다, 잠시만 기다려주시기 바랍니다...", IDC_WAITTEXT, 40, 5, 150, 40, SS_NOPREFIX END
1
0
0
0
Austin English : winex11.drv: Use consistent formatting in a TRACE().
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 8ec262ef0def3e0f224a7e9217e157e4fe0ef8bc URL:
http://source.winehq.org/git/wine.git/?a=commit;h=8ec262ef0def3e0f224a7e921…
Author: Austin English <austinenglish(a)gmail.com> Date: Wed Jan 5 02:42:49 2011 +0000 winex11.drv: Use consistent formatting in a TRACE(). --- dlls/winex11.drv/keyboard.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c index d6054d6..313ff3a 100644 --- a/dlls/winex11.drv/keyboard.c +++ b/dlls/winex11.drv/keyboard.c @@ -1297,7 +1297,7 @@ static inline void KEYBOARD_UpdateOneState ( WORD vkey, WORD scan, int state, DW if (!state) flags |= KEYEVENTF_KEYUP; - TRACE("Adjusting state for vkey %#.2X. State before %#.2x\n", + TRACE("Adjusting state for vkey %#.2x. State before %#.2x\n", vkey, key_state_table[vkey & 0xff]); /* Fake key being pressed inside wine */
1
0
0
0
Huw Davies : ole32: Store the ole advise sinks in a STATDATA array.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 62cd56ce811e753b7b8c49ec996367b0a373a6c0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=62cd56ce811e753b7b8c49ec9…
Author: Huw Davies <huw(a)codeweavers.com> Date: Wed Jan 5 11:20:11 2011 +0000 ole32: Store the ole advise sinks in a STATDATA array. --- dlls/ole32/oleobj.c | 131 ++++++++++++++------------------------------------- 1 files changed, 36 insertions(+), 95 deletions(-) diff --git a/dlls/ole32/oleobj.c b/dlls/ole32/oleobj.c index 2495f9a..6a84681 100644 --- a/dlls/ole32/oleobj.c +++ b/dlls/ole32/oleobj.c @@ -243,8 +243,8 @@ typedef struct LONG ref; - DWORD maxSinks; - IAdviseSink** arrayOfSinks; + DWORD max_cons; + STATDATA *connections; } OleAdviseHolderImpl; static inline OleAdviseHolderImpl *impl_from_IOleAdviseHolder(IOleAdviseHolder *iface) @@ -255,28 +255,19 @@ static inline OleAdviseHolderImpl *impl_from_IOleAdviseHolder(IOleAdviseHolder * /************************************************************************** * OleAdviseHolderImpl_Destructor */ -static void OleAdviseHolderImpl_Destructor(OleAdviseHolderImpl* ptrToDestroy) +static void OleAdviseHolderImpl_Destructor(OleAdviseHolderImpl *This) { - DWORD index; - TRACE("%p\n", ptrToDestroy); + DWORD index; + TRACE("%p\n", This); - for (index = 0; index < ptrToDestroy->maxSinks; index++) - { - if (ptrToDestroy->arrayOfSinks[index]!=0) + for (index = 0; index < This->max_cons; index++) { - IAdviseSink_Release(ptrToDestroy->arrayOfSinks[index]); - ptrToDestroy->arrayOfSinks[index] = NULL; + if (This->connections[index].pAdvSink != NULL) + release_statdata(This->connections + index); } - } - HeapFree(GetProcessHeap(), - 0, - ptrToDestroy->arrayOfSinks); - - - HeapFree(GetProcessHeap(), - 0, - ptrToDestroy); + HeapFree(GetProcessHeap(), 0, This->connections); + HeapFree(GetProcessHeap(), 0, This); } /************************************************************************** @@ -344,6 +335,8 @@ static HRESULT WINAPI OleAdviseHolderImpl_Advise(IOleAdviseHolder *iface, { DWORD index; OleAdviseHolderImpl *This = impl_from_IOleAdviseHolder(iface); + STATDATA new_conn; + static const FORMATETC empty_fmtetc = {0, NULL, 0, -1, 0}; TRACE("(%p)->(%p, %p)\n", This, pAdvise, pdwConnection); @@ -352,38 +345,27 @@ static HRESULT WINAPI OleAdviseHolderImpl_Advise(IOleAdviseHolder *iface, *pdwConnection = 0; - for (index = 0; index < This->maxSinks; index++) + for (index = 0; index < This->max_cons; index++) { - if (This->arrayOfSinks[index]==NULL) + if (This->connections[index].pAdvSink == NULL) break; } - if (index == This->maxSinks) + if (index == This->max_cons) { - DWORD i; - - This->maxSinks+=INITIAL_SINKS; - - This->arrayOfSinks = HeapReAlloc(GetProcessHeap(), - 0, - This->arrayOfSinks, - This->maxSinks*sizeof(IAdviseSink*)); - - for (i=index;i < This->maxSinks; i++) - This->arrayOfSinks[i]=0; + This->max_cons += INITIAL_SINKS; + This->connections = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, This->connections, + This->max_cons * sizeof(*This->connections)); } - This->arrayOfSinks[index] = pAdvise; + new_conn.pAdvSink = pAdvise; + new_conn.advf = 0; + new_conn.formatetc = empty_fmtetc; + new_conn.dwConnection = index + 1; /* 0 is not a valid cookie, so increment the index */ - if (This->arrayOfSinks[index]!=NULL) - IAdviseSink_AddRef(This->arrayOfSinks[index]); + copy_statdata(This->connections + index, &new_conn); - /* - * Return the index as the cookie. - * Since 0 is not a valid cookie, we will increment by - * 1 the index in the table. - */ - *pdwConnection = index+1; + *pdwConnection = new_conn.dwConnection; return S_OK; } @@ -395,30 +377,17 @@ static HRESULT WINAPI OleAdviseHolderImpl_Unadvise(IOleAdviseHolder *iface, DWORD dwConnection) { OleAdviseHolderImpl *This = impl_from_IOleAdviseHolder(iface); + DWORD index; TRACE("(%p)->(%u)\n", This, dwConnection); - /* - * So we don't return 0 as a cookie, the index was - * incremented by 1 in OleAdviseHolderImpl_Advise - * we have to compensate. - */ - dwConnection--; - - /* - * Check for invalid cookies. - */ - if (dwConnection >= This->maxSinks) - return OLE_E_NOCONNECTION; + /* The connection number is 1 more than the index, see OleAdviseHolder_Advise */ + index = dwConnection - 1; - if (This->arrayOfSinks[dwConnection] == NULL) - return OLE_E_NOCONNECTION; + if (index >= This->max_cons || This->connections[index].pAdvSink == NULL) + return OLE_E_NOCONNECTION; - /* - * Release the sink and mark the spot in the list as free. - */ - IAdviseSink_Release(This->arrayOfSinks[dwConnection]); - This->arrayOfSinks[dwConnection] = NULL; + release_statdata(This->connections + index); return S_OK; } @@ -426,40 +395,17 @@ static HRESULT WINAPI OleAdviseHolderImpl_Unadvise(IOleAdviseHolder *iface, /****************************************************************************** * OleAdviseHolderImpl_EnumAdvise */ -static HRESULT WINAPI OleAdviseHolderImpl_EnumAdvise(IOleAdviseHolder *iface, IEnumSTATDATA **ppenumAdvise) +static HRESULT WINAPI OleAdviseHolderImpl_EnumAdvise(IOleAdviseHolder *iface, IEnumSTATDATA **enum_advise) { OleAdviseHolderImpl *This = impl_from_IOleAdviseHolder(iface); IUnknown *unk; - DWORD i, count; - STATDATA *data; - static const FORMATETC empty_fmtetc = {0, NULL, 0, -1, 0}; HRESULT hr; - TRACE("(%p)->(%p)\n", This, ppenumAdvise); - - *ppenumAdvise = NULL; - - /* Build an array of STATDATA structures */ - data = HeapAlloc(GetProcessHeap(), 0, This->maxSinks * sizeof(*data)); - if(!data) return E_OUTOFMEMORY; - - for(i = 0, count = 0; i < This->maxSinks; i++) - { - if(This->arrayOfSinks[i]) - { - data[count].formatetc = empty_fmtetc; - data[count].advf = 0; - data[count].pAdvSink = This->arrayOfSinks[i]; /* The constructor will take a ref. */ - data[count].dwConnection = i; - count++; - } - } + TRACE("(%p)->(%p)\n", This, enum_advise); IOleAdviseHolder_QueryInterface(iface, &IID_IUnknown, (void**)&unk); - hr = EnumSTATDATA_Construct(unk, 0, count, data, ppenumAdvise); + hr = EnumSTATDATA_Construct(unk, 0, This->max_cons, This->connections, enum_advise); IUnknown_Release(unk); - HeapFree(GetProcessHeap(), 0, data); - return hr; } @@ -564,19 +510,14 @@ static const IOleAdviseHolderVtbl oahvt = static IOleAdviseHolder *OleAdviseHolderImpl_Constructor(void) { OleAdviseHolderImpl* lpoah; - DWORD index; lpoah = HeapAlloc(GetProcessHeap(), 0, sizeof(OleAdviseHolderImpl)); lpoah->IOleAdviseHolder_iface.lpVtbl = &oahvt; lpoah->ref = 1; - lpoah->maxSinks = INITIAL_SINKS; - lpoah->arrayOfSinks = HeapAlloc(GetProcessHeap(), - 0, - lpoah->maxSinks * sizeof(IAdviseSink*)); - - for (index = 0; index < lpoah->maxSinks; index++) - lpoah->arrayOfSinks[index]=0; + lpoah->max_cons = INITIAL_SINKS; + lpoah->connections = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + lpoah->max_cons * sizeof(*lpoah->connections)); TRACE("returning %p\n", &lpoah->IOleAdviseHolder_iface); return &lpoah->IOleAdviseHolder_iface;
1
0
0
0
Huw Davies : ole32: Reimplement SendOnDataChange using the connection enumerator.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 6ac2cb3ddcb3021cc737a6c9b4dd16128d187038 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6ac2cb3ddcb3021cc737a6c9b…
Author: Huw Davies <huw(a)codeweavers.com> Date: Wed Jan 5 10:13:38 2011 +0000 ole32: Reimplement SendOnDataChange using the connection enumerator. --- dlls/ole32/oleobj.c | 62 +++++++++++++++++++++++++++----------------------- 1 files changed, 33 insertions(+), 29 deletions(-) diff --git a/dlls/ole32/oleobj.c b/dlls/ole32/oleobj.c index df2898d..2495f9a 100644 --- a/dlls/ole32/oleobj.c +++ b/dlls/ole32/oleobj.c @@ -24,6 +24,8 @@ #include <string.h> #define COBJMACROS +#define NONAMELESSUNION +#define NONAMELESSSTRUCT #include "windef.h" #include "winbase.h" @@ -804,41 +806,43 @@ static HRESULT WINAPI DataAdviseHolder_EnumAdvise(IDataAdviseHolder *iface, * DataAdviseHolder_SendOnDataChange */ static HRESULT WINAPI DataAdviseHolder_SendOnDataChange(IDataAdviseHolder *iface, - IDataObject *pDataObject, + IDataObject *data_obj, DWORD dwReserved, DWORD advf) { - DataAdviseHolder *This = impl_from_IDataAdviseHolder(iface); - DWORD index; - STGMEDIUM stg; - HRESULT res; + IEnumSTATDATA *pEnum; + HRESULT hr; - TRACE("(%p)->(%p,%08x,%08x)\n", This, pDataObject, dwReserved, advf); + TRACE("(%p)->(%p, %08x, %08x)\n", iface, data_obj, dwReserved, advf); - for(index = 0; index < This->maxCons; index++) - { - if(This->connections[index].pAdvSink != NULL) + hr = IDataAdviseHolder_EnumAdvise(iface, &pEnum); + if (SUCCEEDED(hr)) { - memset(&stg, 0, sizeof(stg)); - if(!(This->connections[index].advf & ADVF_NODATA)) - { - TRACE("Calling IDataObject_GetData\n"); - res = IDataObject_GetData(pDataObject, - &(This->connections[index].formatetc), - &stg); - TRACE("returns %08x\n", res); - } - TRACE("Calling IAdviseSink_OnDataChange\n"); - IAdviseSink_OnDataChange(This->connections[index].pAdvSink, - &(This->connections[index].formatetc), - &stg); - TRACE("Done IAdviseSink_OnDataChange\n"); - if(This->connections[index].advf & ADVF_ONLYONCE) { - TRACE("Removing connection\n"); - DataAdviseHolder_Unadvise(iface, This->connections[index].dwConnection); - } + STATDATA statdata; + while (IEnumSTATDATA_Next(pEnum, 1, &statdata, NULL) == S_OK) + { + STGMEDIUM stg; + stg.tymed = TYMED_NULL; + stg.u.pstg = NULL; + stg.pUnkForRelease = NULL; + + if(!(statdata.advf & ADVF_NODATA)) + { + hr = IDataObject_GetData(data_obj, &statdata.formatetc, &stg); + } + + IAdviseSink_OnDataChange(statdata.pAdvSink, &statdata.formatetc, &stg); + + if(statdata.advf & ADVF_ONLYONCE) + { + IDataAdviseHolder_Unadvise(iface, statdata.dwConnection); + } + + release_statdata(&statdata); + } + IEnumSTATDATA_Release(pEnum); } - } - return S_OK; + + return S_OK; } /**************************************************************************
1
0
0
0
Huw Davies : wrc: Initialise variable.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: d5c66bc23d8bd9c4750fa5f20ed442dc05e8408c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d5c66bc23d8bd9c4750fa5f20…
Author: Huw Davies <huw(a)codeweavers.com> Date: Wed Jan 5 14:55:02 2011 +0000 wrc: Initialise variable. --- tools/wrc/po.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/tools/wrc/po.c b/tools/wrc/po.c index 2b7ed6d..6cfb5b4 100644 --- a/tools/wrc/po.c +++ b/tools/wrc/po.c @@ -469,7 +469,7 @@ static char *get_po_file_name( const language_t *lang ) static unsigned int flush_po_files( const char *output_name ) { struct po_file_lang *po_file, *next; - unsigned int count; + unsigned int count = 0; LIST_FOR_EACH_ENTRY_SAFE( po_file, next, &po_file_langs, struct po_file_lang, entry ) {
1
0
0
0
Michael Stefaniuc : windowscodecs: Use an iface instead of a vtbl pointer in BmpFrameEncode.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 5cce70ddeb7d089ccfb124cc9e609af3af151fd5 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5cce70ddeb7d089ccfb124cc9…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 5 00:46:15 2011 +0100 windowscodecs: Use an iface instead of a vtbl pointer in BmpFrameEncode. --- dlls/windowscodecs/bmpencode.c | 33 +++++++++++++++++++-------------- 1 files changed, 19 insertions(+), 14 deletions(-) diff --git a/dlls/windowscodecs/bmpencode.c b/dlls/windowscodecs/bmpencode.c index 4b3b9ea..410c646 100644 --- a/dlls/windowscodecs/bmpencode.c +++ b/dlls/windowscodecs/bmpencode.c @@ -58,7 +58,7 @@ static const struct bmp_pixelformat formats[] = { }; typedef struct BmpFrameEncode { - const IWICBitmapFrameEncodeVtbl *lpVtbl; + IWICBitmapFrameEncode IWICBitmapFrameEncode_iface; LONG ref; IStream *stream; BOOL initialized; @@ -71,10 +71,15 @@ typedef struct BmpFrameEncode { BOOL committed; } BmpFrameEncode; +static inline BmpFrameEncode *impl_from_IWICBitmapFrameEncode(IWICBitmapFrameEncode *iface) +{ + return CONTAINING_RECORD(iface, BmpFrameEncode, IWICBitmapFrameEncode_iface); +} + static HRESULT WINAPI BmpFrameEncode_QueryInterface(IWICBitmapFrameEncode *iface, REFIID iid, void **ppv) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); if (!ppv) return E_INVALIDARG; @@ -96,7 +101,7 @@ static HRESULT WINAPI BmpFrameEncode_QueryInterface(IWICBitmapFrameEncode *iface static ULONG WINAPI BmpFrameEncode_AddRef(IWICBitmapFrameEncode *iface) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); ULONG ref = InterlockedIncrement(&This->ref); TRACE("(%p) refcount=%u\n", iface, ref); @@ -106,7 +111,7 @@ static ULONG WINAPI BmpFrameEncode_AddRef(IWICBitmapFrameEncode *iface) static ULONG WINAPI BmpFrameEncode_Release(IWICBitmapFrameEncode *iface) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p) refcount=%u\n", iface, ref); @@ -124,7 +129,7 @@ static ULONG WINAPI BmpFrameEncode_Release(IWICBitmapFrameEncode *iface) static HRESULT WINAPI BmpFrameEncode_Initialize(IWICBitmapFrameEncode *iface, IPropertyBag2 *pIEncoderOptions) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); TRACE("(%p,%p)\n", iface, pIEncoderOptions); if (This->initialized) return WINCODEC_ERR_WRONGSTATE; @@ -137,7 +142,7 @@ static HRESULT WINAPI BmpFrameEncode_Initialize(IWICBitmapFrameEncode *iface, static HRESULT WINAPI BmpFrameEncode_SetSize(IWICBitmapFrameEncode *iface, UINT uiWidth, UINT uiHeight) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); TRACE("(%p,%u,%u)\n", iface, uiWidth, uiHeight); if (!This->initialized || This->bits) return WINCODEC_ERR_WRONGSTATE; @@ -151,7 +156,7 @@ static HRESULT WINAPI BmpFrameEncode_SetSize(IWICBitmapFrameEncode *iface, static HRESULT WINAPI BmpFrameEncode_SetResolution(IWICBitmapFrameEncode *iface, double dpiX, double dpiY) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); TRACE("(%p,%0.2f,%0.2f)\n", iface, dpiX, dpiY); if (!This->initialized || This->bits) return WINCODEC_ERR_WRONGSTATE; @@ -165,7 +170,7 @@ static HRESULT WINAPI BmpFrameEncode_SetResolution(IWICBitmapFrameEncode *iface, static HRESULT WINAPI BmpFrameEncode_SetPixelFormat(IWICBitmapFrameEncode *iface, WICPixelFormatGUID *pPixelFormat) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); int i; TRACE("(%p,%s)\n", iface, debugstr_guid(pPixelFormat)); @@ -224,7 +229,7 @@ static HRESULT BmpFrameEncode_AllocateBits(BmpFrameEncode *This) static HRESULT WINAPI BmpFrameEncode_WritePixels(IWICBitmapFrameEncode *iface, UINT lineCount, UINT cbStride, UINT cbBufferSize, BYTE *pbPixels) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); HRESULT hr; WICRect rc; TRACE("(%p,%u,%u,%u,%p)\n", iface, lineCount, cbStride, cbBufferSize, pbPixels); @@ -253,7 +258,7 @@ static HRESULT WINAPI BmpFrameEncode_WritePixels(IWICBitmapFrameEncode *iface, static HRESULT WINAPI BmpFrameEncode_WriteSource(IWICBitmapFrameEncode *iface, IWICBitmapSource *pIBitmapSource, WICRect *prc) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); HRESULT hr; WICRect rc; WICPixelFormatGUID guid; @@ -316,7 +321,7 @@ static HRESULT WINAPI BmpFrameEncode_WriteSource(IWICBitmapFrameEncode *iface, static HRESULT WINAPI BmpFrameEncode_Commit(IWICBitmapFrameEncode *iface) { - BmpFrameEncode *This = (BmpFrameEncode*)iface; + BmpFrameEncode *This = impl_from_IWICBitmapFrameEncode(iface); BITMAPFILEHEADER bfh; BITMAPV5HEADER bih; UINT info_size; @@ -456,7 +461,7 @@ static ULONG WINAPI BmpEncoder_Release(IWICBitmapEncoder *iface) if (ref == 0) { if (This->stream) IStream_Release(This->stream); - if (This->frame) IWICBitmapFrameEncode_Release((IWICBitmapFrameEncode*)This->frame); + if (This->frame) IWICBitmapFrameEncode_Release(&This->frame->IWICBitmapFrameEncode_iface); HeapFree(GetProcessHeap(), 0, This); } @@ -538,7 +543,7 @@ static HRESULT WINAPI BmpEncoder_CreateNewFrame(IWICBitmapEncoder *iface, *ppIEncoderOptions = NULL; return E_OUTOFMEMORY; } - encode->lpVtbl = &BmpFrameEncode_Vtbl; + encode->IWICBitmapFrameEncode_iface.lpVtbl = &BmpFrameEncode_Vtbl; encode->ref = 2; IStream_AddRef(This->stream); encode->stream = This->stream; @@ -552,7 +557,7 @@ static HRESULT WINAPI BmpEncoder_CreateNewFrame(IWICBitmapEncoder *iface, encode->lineswritten = 0; encode->committed = FALSE; - *ppIFrameEncode = (IWICBitmapFrameEncode*)encode; + *ppIFrameEncode = &encode->IWICBitmapFrameEncode_iface; This->frame = encode; return S_OK;
1
0
0
0
Michael Stefaniuc : mshtml: Use ifaces instead of vtbl pointers in ProtocolFactory.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 0eff947c091de89621dd7d48ae1c6adb18853b71 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=0eff947c091de89621dd7d48a…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 5 00:43:29 2011 +0100 mshtml: Use ifaces instead of vtbl pointers in ProtocolFactory. --- dlls/mshtml/protocol.c | 52 ++++++++++++++++++++++++------------------------ 1 files changed, 26 insertions(+), 26 deletions(-) diff --git a/dlls/mshtml/protocol.c b/dlls/mshtml/protocol.c index 1485881..b3aee2b 100644 --- a/dlls/mshtml/protocol.c +++ b/dlls/mshtml/protocol.c @@ -39,31 +39,32 @@ WINE_DEFAULT_DEBUG_CHANNEL(mshtml); * common ProtocolFactory implementation */ -#define CLASSFACTORY(x) (&(x)->lpClassFactoryVtbl) #define PROTOCOL(x) ((IInternetProtocol*) &(x)->lpInternetProtocolVtbl) -#define PROTOCOLINFO(x) ((IInternetProtocolInfo*) &(x)->lpInternetProtocolInfoVtbl) typedef struct { - const IInternetProtocolInfoVtbl *lpInternetProtocolInfoVtbl; - const IClassFactoryVtbl *lpClassFactoryVtbl; + IInternetProtocolInfo IInternetProtocolInfo_iface; + IClassFactory IClassFactory_iface; } ProtocolFactory; -#define PROTOCOLINFO_THIS(iface) DEFINE_THIS(ProtocolFactory, InternetProtocolInfo, iface) +static inline ProtocolFactory *impl_from_IInternetProtocolInfo(IInternetProtocolInfo *iface) +{ + return CONTAINING_RECORD(iface, ProtocolFactory, IInternetProtocolInfo_iface); +} static HRESULT WINAPI InternetProtocolInfo_QueryInterface(IInternetProtocolInfo *iface, REFIID riid, void **ppv) { - ProtocolFactory *This = PROTOCOLINFO_THIS(iface); + ProtocolFactory *This = impl_from_IInternetProtocolInfo(iface); *ppv = NULL; if(IsEqualGUID(&IID_IUnknown, riid)) { TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); - *ppv = PROTOCOLINFO(This); + *ppv = &This->IInternetProtocolInfo_iface; }else if(IsEqualGUID(&IID_IInternetProtocolInfo, riid)) { TRACE("(%p)->(IID_IInternetProtocolInfo %p)\n", This, ppv); - *ppv = PROTOCOLINFO(This); + *ppv = &This->IInternetProtocolInfo_iface; }else if(IsEqualGUID(&IID_IClassFactory, riid)) { TRACE("(%p)->(IID_IClassFactory %p)\n", This, ppv); - *ppv = CLASSFACTORY(This); + *ppv = &This->IClassFactory_iface; } if(!*ppv) { @@ -105,26 +106,27 @@ static HRESULT WINAPI InternetProtocolInfo_CompareUrl(IInternetProtocolInfo *ifa return E_NOTIMPL; } -#undef PROTOCOLINFO_THIS - -#define CLASSFACTORY_THIS(iface) DEFINE_THIS(ProtocolFactory, ClassFactory, iface) +static inline ProtocolFactory *impl_from_IClassFactory(IClassFactory *iface) +{ + return CONTAINING_RECORD(iface, ProtocolFactory, IClassFactory_iface); +} static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFIID riid, void **ppv) { - ProtocolFactory *This = CLASSFACTORY_THIS(iface); - return IInternetProtocolInfo_QueryInterface(PROTOCOLINFO(This), riid, ppv); + ProtocolFactory *This = impl_from_IClassFactory(iface); + return IInternetProtocolInfo_QueryInterface(&This->IInternetProtocolInfo_iface, riid, ppv); } static ULONG WINAPI ClassFactory_AddRef(IClassFactory *iface) { - ProtocolFactory *This = CLASSFACTORY_THIS(iface); - return IInternetProtocolInfo_AddRef(PROTOCOLINFO(This)); + ProtocolFactory *This = impl_from_IClassFactory(iface); + return IInternetProtocolInfo_AddRef(&This->IInternetProtocolInfo_iface); } static ULONG WINAPI ClassFactory_Release(IClassFactory *iface) { - ProtocolFactory *This = CLASSFACTORY_THIS(iface); - return IInternetProtocolInfo_Release(PROTOCOLINFO(This)); + ProtocolFactory *This = impl_from_IClassFactory(iface); + return IInternetProtocolInfo_Release(&This->IInternetProtocolInfo_iface); } static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL dolock) @@ -133,8 +135,6 @@ static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL dolock) return S_OK; } -#undef CLASSFACTORY_THIS - /******************************************************************** * AboutProtocol implementation */ @@ -497,8 +497,8 @@ static const IClassFactoryVtbl AboutProtocolFactoryVtbl = { }; static ProtocolFactory AboutProtocolFactory = { - &AboutProtocolInfoVtbl, - &AboutProtocolFactoryVtbl + { &AboutProtocolInfoVtbl }, + { &AboutProtocolFactoryVtbl } }; /******************************************************************** @@ -934,8 +934,8 @@ static const IClassFactoryVtbl ResProtocolFactoryVtbl = { }; static ProtocolFactory ResProtocolFactory = { - &ResProtocolInfoVtbl, - &ResProtocolFactoryVtbl + { &ResProtocolInfoVtbl }, + { &ResProtocolFactoryVtbl } }; /******************************************************************** @@ -1017,8 +1017,8 @@ static const IClassFactoryVtbl JSProtocolFactoryVtbl = { }; static ProtocolFactory JSProtocolFactory = { - &JSProtocolInfoVtbl, - &JSProtocolFactoryVtbl + { &JSProtocolInfoVtbl }, + { &JSProtocolFactoryVtbl } }; HRESULT ProtocolFactory_Create(REFCLSID rclsid, REFIID riid, void **ppv)
1
0
0
0
Michael Stefaniuc : mshtml: COM cleanup for the nsIInputStream iface.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 1ae51aa74a1efde0dbc902064d83bc9863ab8e70 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1ae51aa74a1efde0dbc902064…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 5 00:41:05 2011 +0100 mshtml: COM cleanup for the nsIInputStream iface. --- dlls/mshtml/navigate.c | 41 ++++++++++++++++++++--------------------- 1 files changed, 20 insertions(+), 21 deletions(-) diff --git a/dlls/mshtml/navigate.c b/dlls/mshtml/navigate.c index 175b85b..f1731fb 100644 --- a/dlls/mshtml/navigate.c +++ b/dlls/mshtml/navigate.c @@ -45,7 +45,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mshtml); #define UTF16_STR "utf-16" typedef struct { - const nsIInputStreamVtbl *lpInputStreamVtbl; + nsIInputStream nsIInputStream_iface; LONG ref; @@ -53,8 +53,6 @@ typedef struct { DWORD buf_size; } nsProtocolStream; -#define NSINSTREAM(x) ((nsIInputStream*) &(x)->lpInputStreamVtbl) - typedef struct { void (*destroy)(BSCallback*); HRESULT (*init_bindinfo)(BSCallback*); @@ -91,25 +89,28 @@ struct BSCallback { struct list entry; }; -#define NSINSTREAM_THIS(iface) DEFINE_THIS(nsProtocolStream, InputStream, iface) +static inline nsProtocolStream *impl_from_nsIInputStream(nsIInputStream *iface) +{ + return CONTAINING_RECORD(iface, nsProtocolStream, nsIInputStream_iface); +} static nsresult NSAPI nsInputStream_QueryInterface(nsIInputStream *iface, nsIIDRef riid, void **result) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); *result = NULL; if(IsEqualGUID(&IID_nsISupports, riid)) { TRACE("(%p)->(IID_nsISupports %p)\n", This, result); - *result = NSINSTREAM(This); + *result = &This->nsIInputStream_iface; }else if(IsEqualGUID(&IID_nsIInputStream, riid)) { TRACE("(%p)->(IID_nsIInputStream %p)\n", This, result); - *result = NSINSTREAM(This); + *result = &This->nsIInputStream_iface; } if(*result) { - nsIInputStream_AddRef(NSINSTREAM(This)); + nsIInputStream_AddRef(&This->nsIInputStream_iface); return NS_OK; } @@ -119,7 +120,7 @@ static nsresult NSAPI nsInputStream_QueryInterface(nsIInputStream *iface, nsIIDR static nsrefcnt NSAPI nsInputStream_AddRef(nsIInputStream *iface) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); LONG ref = InterlockedIncrement(&This->ref); TRACE("(%p) ref=%d\n", This, ref); @@ -130,7 +131,7 @@ static nsrefcnt NSAPI nsInputStream_AddRef(nsIInputStream *iface) static nsrefcnt NSAPI nsInputStream_Release(nsIInputStream *iface) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); LONG ref = InterlockedDecrement(&This->ref); TRACE("(%p) ref=%d\n", This, ref); @@ -143,14 +144,14 @@ static nsrefcnt NSAPI nsInputStream_Release(nsIInputStream *iface) static nsresult NSAPI nsInputStream_Close(nsIInputStream *iface) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); FIXME("(%p)\n", This); return NS_ERROR_NOT_IMPLEMENTED; } static nsresult NSAPI nsInputStream_Available(nsIInputStream *iface, PRUint32 *_retval) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); FIXME("(%p)->(%p)\n", This, _retval); return NS_ERROR_NOT_IMPLEMENTED; } @@ -158,7 +159,7 @@ static nsresult NSAPI nsInputStream_Available(nsIInputStream *iface, PRUint32 *_ static nsresult NSAPI nsInputStream_Read(nsIInputStream *iface, char *aBuf, PRUint32 aCount, PRUint32 *_retval) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); DWORD read = aCount; TRACE("(%p)->(%p %d %p)\n", This, aBuf, aCount, _retval); @@ -181,7 +182,7 @@ static nsresult NSAPI nsInputStream_ReadSegments(nsIInputStream *iface, nsresult (WINAPI *aWriter)(nsIInputStream*,void*,const char*,PRUint32,PRUint32,PRUint32*), void *aClousure, PRUint32 aCount, PRUint32 *_retval) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); PRUint32 written = 0; nsresult nsres; @@ -193,7 +194,7 @@ static nsresult NSAPI nsInputStream_ReadSegments(nsIInputStream *iface, if(aCount > This->buf_size) aCount = This->buf_size; - nsres = aWriter(NSINSTREAM(This), aClousure, This->buf, 0, aCount, &written); + nsres = aWriter(&This->nsIInputStream_iface, aClousure, This->buf, 0, aCount, &written); if(NS_FAILED(nsres)) TRACE("aWritter failed: %08x\n", nsres); else if(written != This->buf_size) @@ -207,13 +208,11 @@ static nsresult NSAPI nsInputStream_ReadSegments(nsIInputStream *iface, static nsresult NSAPI nsInputStream_IsNonBlocking(nsIInputStream *iface, PRBool *_retval) { - nsProtocolStream *This = NSINSTREAM_THIS(iface); + nsProtocolStream *This = impl_from_nsIInputStream(iface); FIXME("(%p)->(%p)\n", This, _retval); return NS_ERROR_NOT_IMPLEMENTED; } -#undef NSINSTREAM_THIS - static const nsIInputStreamVtbl nsInputStreamVtbl = { nsInputStream_QueryInterface, nsInputStream_AddRef, @@ -229,7 +228,7 @@ static nsProtocolStream *create_nsprotocol_stream(void) { nsProtocolStream *ret = heap_alloc(sizeof(nsProtocolStream)); - ret->lpInputStreamVtbl = &nsInputStreamVtbl; + ret->nsIInputStream_iface.lpVtbl = &nsInputStreamVtbl; ret->ref = 1; ret->buf_size = 0; @@ -1016,7 +1015,7 @@ static HRESULT read_stream_data(nsChannelBSC *This, IStream *stream) nsres = nsIStreamListener_OnDataAvailable(This->nslistener, (nsIRequest*)&This->nschannel->nsIHttpChannel_iface, This->nscontext, - NSINSTREAM(This->nsstream), This->bsc.readed-This->nsstream->buf_size, + &This->nsstream->nsIInputStream_iface, This->bsc.readed-This->nsstream->buf_size, This->nsstream->buf_size); if(NS_FAILED(nsres)) ERR("OnDataAvailable failed: %08x\n", nsres); @@ -1043,7 +1042,7 @@ static void nsChannelBSC_destroy(BSCallback *bsc) if(This->nscontext) nsISupports_Release(This->nscontext); if(This->nsstream) - nsIInputStream_Release(NSINSTREAM(This->nsstream)); + nsIInputStream_Release(&This->nsstream->nsIInputStream_iface); heap_free(This); }
1
0
0
0
Michael Stefaniuc : mshtml: COM cleanup for the nsIURL iface.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 1d7e50079a60664f1c75eec9a0b3d200cfe5204d URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1d7e50079a60664f1c75eec9a…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 5 00:39:25 2011 +0100 mshtml: COM cleanup for the nsIURL iface. --- dlls/mshtml/nsio.c | 138 +++++++++++++++++++++++++-------------------------- 1 files changed, 68 insertions(+), 70 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=1d7e50079a60664f1c75e…
1
0
0
0
Michael Stefaniuc : atl: Use ifaces instead of vtbl pointers in IOCS.
by Alexandre Julliard
05 Jan '11
05 Jan '11
Module: wine Branch: master Commit: 1e19fd6c49da7fc405a68e093b176fa05a46075f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1e19fd6c49da7fc405a68e093…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 5 00:37:45 2011 +0100 atl: Use ifaces instead of vtbl pointers in IOCS. --- dlls/atl/atl_ax.c | 215 +++++++++++++++++++++++++++++++--------------------- 1 files changed, 128 insertions(+), 87 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=1e19fd6c49da7fc405a68…
1
0
0
0
← Newer
1
...
71
72
73
74
75
76
77
...
88
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
Results per page:
10
25
50
100
200