[RICHED20] Sync with Wine Staging 2.2. CORE-12823

440b921 riched20: Return proper interface pointers.
e63cea5 riched20: A spelling fix in a comment.
9f37f6a riched20: Check for NULL in fnTextSrv_TxSetText and add test.

svn path=/trunk/; revision=74108
This commit is contained in:
Amine Khaldi 2017-03-05 21:43:39 +00:00
parent e007edf028
commit a142fcc929
5 changed files with 8 additions and 9 deletions

View file

@ -64,7 +64,7 @@ static HRESULT WINAPI EnumFormatImpl_QueryInterface(IEnumFORMATETC *iface, REFII
if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IEnumFORMATETC)) {
IEnumFORMATETC_AddRef(iface);
*ppvObj = This;
*ppvObj = &This->IEnumFORMATETC_iface;
return S_OK;
}
*ppvObj = NULL;
@ -181,7 +181,7 @@ static HRESULT WINAPI DataObjectImpl_QueryInterface(IDataObject *iface, REFIID r
if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IDataObject)) {
IDataObject_AddRef(iface);
*ppvObj = This;
*ppvObj = &This->IDataObject_iface;
return S_OK;
}
*ppvObj = NULL;

View file

@ -183,7 +183,7 @@ ME_Style *ME_ApplyStyle(ME_TextEditor *editor, ME_Style *sSrc, CHARFORMAT2W *mod
}
COPY_STYLE_ITEM(CFM_UNDERLINETYPE, bUnderlineType);
/* If the CFM_UNDERLINE effect is not specified set it appropiately */
/* If the CFM_UNDERLINE effect is not specified, set it appropriately */
if ((mod->dwMask & CFM_UNDERLINETYPE) && !(mod->dwMask & CFM_UNDERLINE))
{
fmt.dwMask |= CFM_UNDERLINE;

View file

@ -65,7 +65,7 @@ static HRESULT WINAPI ITextHostImpl_QueryInterface(ITextHost *iface, REFIID riid
ITextHostImpl *This = impl_from_ITextHost(iface);
if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_ITextHost)) {
*ppvObject = This;
*ppvObject = &This->ITextHost_iface;
ITextHost_AddRef((ITextHost *)*ppvObject);
return S_OK;
}

View file

@ -274,10 +274,9 @@ DECLSPEC_HIDDEN HRESULT WINAPI fnTextSrv_TxSetText(ITextServices *iface, LPCWSTR
ME_Cursor cursor;
ME_SetCursorToStart(This->editor, &cursor);
ME_InternalDeleteText(This->editor, &cursor,
ME_GetTextLength(This->editor), FALSE);
ME_InsertTextFromCursor(This->editor, 0, pszText, -1,
This->editor->pBuffer->pDefaultStyle);
ME_InternalDeleteText(This->editor, &cursor, ME_GetTextLength(This->editor), FALSE);
if(pszText)
ME_InsertTextFromCursor(This->editor, 0, pszText, -1, This->editor->pBuffer->pDefaultStyle);
ME_SetSelection(This->editor, 0, 0);
This->editor->nModifyStep = 0;
OleFlushClipboard();

View file

@ -158,7 +158,7 @@ reactos/dll/win32/qmgrprxy # Synced to WineStaging-1.9.11
reactos/dll/win32/query # Synced to WineStaging-1.9.11
reactos/dll/win32/rasapi32 # Synced to WineStaging-1.9.11
reactos/dll/win32/resutils # Synced to WineStaging-1.9.11
reactos/dll/win32/riched20 # Synced to WineStaging-1.9.23
reactos/dll/win32/riched20 # Synced to WineStaging-2.2
reactos/dll/win32/riched32 # Synced to WineStaging-1.9.11
reactos/dll/win32/rpcrt4 # Synced to WineStaging-2.2
reactos/dll/win32/rsabase # Synced to WineStaging-1.9.11