From ce3f724ea26654849faa8f4b27ecb24eb0b5f582 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Mon, 1 Jun 2015 19:20:24 +0200 Subject: [PATCH] Rebase against 7c5f639cb86fba26a3b96d9dd0798fd3da2150a0. --- ...ly-check-return-values-in-IAMMultiMe.patch | 31 --- ...ly-check-for-an-empty-short-filename.patch | 26 --- ...-AEV_SetMasterVolumeLevel-and-AEV_Ge.patch | 28 +-- ...ve-AEV_SetMute-and-AEV_GetMute-stubs.patch | 26 +-- patches/patchinstall.sh | 8 +- ...nt-IText-Selection-Range-Set-Start-E.patch | 15 +- ...r-ITextFont-interface-and-implement-.patch | 28 +-- ...r-ITextPara-interface-and-implement-.patch | 116 +++++------ ...iched20-Implement-ITextRange-GetText.patch | 184 +----------------- ...ched20-Implement-ITextRange-SetRange.patch | 22 +-- ...iched20-Implement-ITextRange-IsEqual.patch | 12 +- ...-Implement-ITextRange-GetStoryLength.patch | 28 +-- 12 files changed, 151 insertions(+), 373 deletions(-) delete mode 100644 patches/Coverity/0002-amstream-Correctly-check-return-values-in-IAMMultiMe.patch delete mode 100644 patches/Coverity/0003-kernel32-Correctly-check-for-an-empty-short-filename.patch diff --git a/patches/Coverity/0002-amstream-Correctly-check-return-values-in-IAMMultiMe.patch b/patches/Coverity/0002-amstream-Correctly-check-return-values-in-IAMMultiMe.patch deleted file mode 100644 index 44791e38..00000000 --- a/patches/Coverity/0002-amstream-Correctly-check-return-values-in-IAMMultiMe.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 173d42087f21dae75c8fb7299f5444c3d57a35c7 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Michael=20M=C3=BCller?= -Date: Sat, 30 May 2015 15:30:36 +0200 -Subject: amstream: Correctly check return values in - IAMMultiMediaStreamImpl_Initialize (Coverity). - ---- - dlls/amstream/amstream.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/dlls/amstream/amstream.c b/dlls/amstream/amstream.c -index 800e48d..fcef7ec 100644 ---- a/dlls/amstream/amstream.c -+++ b/dlls/amstream/amstream.c -@@ -256,11 +256,11 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_Initialize(IAMMultiMediaStream* if - This->StreamType = StreamType; - hr = IGraphBuilder_QueryInterface(This->pFilterGraph, &IID_IMediaSeeking, (void**)&This->media_seeking); - if (SUCCEEDED(hr)) -- IGraphBuilder_QueryInterface(This->pFilterGraph, &IID_IMediaControl, (void**)&This->media_control); -+ hr = IGraphBuilder_QueryInterface(This->pFilterGraph, &IID_IMediaControl, (void**)&This->media_control); - if (SUCCEEDED(hr)) - hr = CoCreateInstance(&CLSID_MediaStreamFilter, NULL, CLSCTX_INPROC_SERVER, &IID_IBaseFilter, (LPVOID*)&This->media_stream_filter); - if (SUCCEEDED(hr)) -- IGraphBuilder_AddFilter(This->pFilterGraph, This->media_stream_filter, filternameW); -+ hr = IGraphBuilder_AddFilter(This->pFilterGraph, This->media_stream_filter, filternameW); - if (SUCCEEDED(hr)) - { - IMediaEventEx* media_event = NULL; --- -2.4.2 - diff --git a/patches/Coverity/0003-kernel32-Correctly-check-for-an-empty-short-filename.patch b/patches/Coverity/0003-kernel32-Correctly-check-for-an-empty-short-filename.patch deleted file mode 100644 index 0a59b1f2..00000000 --- a/patches/Coverity/0003-kernel32-Correctly-check-for-an-empty-short-filename.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 6addc4f5304995f32525dce5422bc6544d7b313d Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Michael=20M=C3=BCller?= -Date: Sat, 30 May 2015 15:36:43 +0200 -Subject: kernel32: Correctly check for an empty short filename in - GetShortPathNameW (Coverity). - ---- - dlls/kernel32/path.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/dlls/kernel32/path.c b/dlls/kernel32/path.c -index f74b952..09b8b7f 100644 ---- a/dlls/kernel32/path.c -+++ b/dlls/kernel32/path.c -@@ -528,7 +528,7 @@ DWORD WINAPI GetShortPathNameW( LPCWSTR longpath, LPWSTR shortpath, DWORD shortl - - /* In rare cases (like "a.abcd") short path may be longer than original path. - * Make sure we have enough space in temp buffer. */ -- if (wfd.cAlternateFileName && tmplen < strlenW(wfd.cAlternateFileName)) -+ if (wfd.cAlternateFileName[0] && tmplen < strlenW(wfd.cAlternateFileName)) - { - WCHAR *new_buf; - buf_len += strlenW(wfd.cAlternateFileName) - tmplen; --- -2.4.2 - diff --git a/patches/mmdevapi-AEV_Stubs/0002-mmdevapi-Improve-AEV_SetMasterVolumeLevel-and-AEV_Ge.patch b/patches/mmdevapi-AEV_Stubs/0002-mmdevapi-Improve-AEV_SetMasterVolumeLevel-and-AEV_Ge.patch index f20cd008..b5fdcaf2 100644 --- a/patches/mmdevapi-AEV_Stubs/0002-mmdevapi-Improve-AEV_SetMasterVolumeLevel-and-AEV_Ge.patch +++ b/patches/mmdevapi-AEV_Stubs/0002-mmdevapi-Improve-AEV_SetMasterVolumeLevel-and-AEV_Ge.patch @@ -1,4 +1,4 @@ -From 6e92d3988f6678c45e8752000170f07d186d9c9e Mon Sep 17 00:00:00 2001 +From 542ba5fc717facafe9de075cec17fa115472bc1b Mon Sep 17 00:00:00 2001 From: Christian Costa Date: Sun, 8 Feb 2015 11:38:17 +0100 Subject: mmdevapi: Improve AEV_SetMasterVolumeLevel and @@ -9,10 +9,10 @@ Subject: mmdevapi: Improve AEV_SetMasterVolumeLevel and 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/dlls/mmdevapi/audiovolume.c b/dlls/mmdevapi/audiovolume.c -index 4cc3226..4765935 100644 +index e6f94a1..4f915ed 100644 --- a/dlls/mmdevapi/audiovolume.c +++ b/dlls/mmdevapi/audiovolume.c -@@ -47,6 +47,7 @@ static const IAudioEndpointVolumeExVtbl AEVImpl_Vtbl; +@@ -43,6 +43,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mmdevapi); typedef struct AEVImpl { IAudioEndpointVolumeEx IAudioEndpointVolumeEx_iface; LONG ref; @@ -20,15 +20,7 @@ index 4cc3226..4765935 100644 } AEVImpl; static inline AEVImpl *impl_from_IAudioEndpointVolumeEx(IAudioEndpointVolumeEx *iface) -@@ -63,6 +64,7 @@ HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolume **ppv) - return E_OUTOFMEMORY; - This->IAudioEndpointVolumeEx_iface.lpVtbl = &AEVImpl_Vtbl; - This->ref = 1; -+ This->level = 1.0f; - return S_OK; - } - -@@ -136,9 +138,13 @@ static HRESULT WINAPI AEV_GetChannelCount(IAudioEndpointVolumeEx *iface, UINT *c +@@ -120,9 +121,13 @@ static HRESULT WINAPI AEV_GetChannelCount(IAudioEndpointVolumeEx *iface, UINT *c static HRESULT WINAPI AEV_SetMasterVolumeLevel(IAudioEndpointVolumeEx *iface, float leveldb, const GUID *ctx) { @@ -45,7 +37,7 @@ index 4cc3226..4765935 100644 } static HRESULT WINAPI AEV_SetMasterVolumeLevelScalar(IAudioEndpointVolumeEx *iface, float level, const GUID *ctx) -@@ -150,11 +156,16 @@ static HRESULT WINAPI AEV_SetMasterVolumeLevelScalar(IAudioEndpointVolumeEx *ifa +@@ -134,11 +139,16 @@ static HRESULT WINAPI AEV_SetMasterVolumeLevelScalar(IAudioEndpointVolumeEx *ifa static HRESULT WINAPI AEV_GetMasterVolumeLevel(IAudioEndpointVolumeEx *iface, float *leveldb) { @@ -65,6 +57,14 @@ index 4cc3226..4765935 100644 } static HRESULT WINAPI AEV_GetMasterVolumeLevelScalar(IAudioEndpointVolumeEx *iface, float *level) +@@ -288,6 +298,7 @@ HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolume **ppv) + return E_OUTOFMEMORY; + This->IAudioEndpointVolumeEx_iface.lpVtbl = &AEVImpl_Vtbl; + This->ref = 1; ++ This->level = 1.0f; + + *ppv = (IAudioEndpointVolume*)&This->IAudioEndpointVolumeEx_iface; + return S_OK; -- -2.3.0 +2.4.2 diff --git a/patches/mmdevapi-AEV_Stubs/0003-mmdevapi-Improve-AEV_SetMute-and-AEV_GetMute-stubs.patch b/patches/mmdevapi-AEV_Stubs/0003-mmdevapi-Improve-AEV_SetMute-and-AEV_GetMute-stubs.patch index 1823024d..687190cf 100644 --- a/patches/mmdevapi-AEV_Stubs/0003-mmdevapi-Improve-AEV_SetMute-and-AEV_GetMute-stubs.patch +++ b/patches/mmdevapi-AEV_Stubs/0003-mmdevapi-Improve-AEV_SetMute-and-AEV_GetMute-stubs.patch @@ -1,4 +1,4 @@ -From ccdb37883bd0ceeaad872dcd90e0b17d6dc7fd85 Mon Sep 17 00:00:00 2001 +From 320a7201538fd7a1774b6a67713a2fa446791238 Mon Sep 17 00:00:00 2001 From: Christian Costa Date: Tue, 10 Feb 2015 20:12:12 +0100 Subject: mmdevapi: Improve AEV_SetMute and AEV_GetMute stubs. @@ -8,10 +8,10 @@ Subject: mmdevapi: Improve AEV_SetMute and AEV_GetMute stubs. 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/dlls/mmdevapi/audiovolume.c b/dlls/mmdevapi/audiovolume.c -index 4765935..c7d7ebe 100644 +index 4f915ed..f8655db 100644 --- a/dlls/mmdevapi/audiovolume.c +++ b/dlls/mmdevapi/audiovolume.c -@@ -48,6 +48,7 @@ typedef struct AEVImpl { +@@ -44,6 +44,7 @@ typedef struct AEVImpl { IAudioEndpointVolumeEx IAudioEndpointVolumeEx_iface; LONG ref; float level; @@ -19,15 +19,7 @@ index 4765935..c7d7ebe 100644 } AEVImpl; static inline AEVImpl *impl_from_IAudioEndpointVolumeEx(IAudioEndpointVolumeEx *iface) -@@ -65,6 +66,7 @@ HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolume **ppv) - This->IAudioEndpointVolumeEx_iface.lpVtbl = &AEVImpl_Vtbl; - This->ref = 1; - This->level = 1.0f; -+ This->mute = FALSE; - return S_OK; - } - -@@ -211,18 +213,27 @@ static HRESULT WINAPI AEV_GetChannelVolumeLevelScalar(IAudioEndpointVolumeEx *if +@@ -194,18 +195,27 @@ static HRESULT WINAPI AEV_GetChannelVolumeLevelScalar(IAudioEndpointVolumeEx *if static HRESULT WINAPI AEV_SetMute(IAudioEndpointVolumeEx *iface, BOOL mute, const GUID *ctx) { @@ -61,6 +53,14 @@ index 4765935..c7d7ebe 100644 } static HRESULT WINAPI AEV_GetVolumeStepInfo(IAudioEndpointVolumeEx *iface, UINT *stepsize, UINT *stepcount) +@@ -299,6 +309,7 @@ HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolume **ppv) + This->IAudioEndpointVolumeEx_iface.lpVtbl = &AEVImpl_Vtbl; + This->ref = 1; + This->level = 1.0f; ++ This->mute = FALSE; + + *ppv = (IAudioEndpointVolume*)&This->IAudioEndpointVolumeEx_iface; + return S_OK; -- -2.3.0 +2.4.2 diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index ff249f42..c55418a4 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -55,7 +55,7 @@ version() echo "Copyright (C) 2014-2015 the Wine Staging project authors." echo "" echo "Patchset to be applied on upstream Wine:" - echo " commit 7efe31d9294275f2505361c19afa4e8e50be2c8d" + echo " commit 7c5f639cb86fba26a3b96d9dd0798fd3da2150a0" echo "" } @@ -1927,16 +1927,12 @@ fi # Patchset Coverity # | # | Modified files: -# | * dlls/amstream/amstream.c, dlls/kernel32/path.c, dlls/ws2_32/socket.c +# | * dlls/ws2_32/socket.c # | if test "$enable_Coverity" -eq 1; then patch_apply Coverity/0001-ws2_32-Fix-uninitialized-memory-access-in-do_poll-Co.patch - patch_apply Coverity/0002-amstream-Correctly-check-return-values-in-IAMMultiMe.patch - patch_apply Coverity/0003-kernel32-Correctly-check-for-an-empty-short-filename.patch ( echo '+ { "Sebastian Lackner", "ws2_32: Fix uninitialized memory access in do_poll (Coverity).", 1 },'; - echo '+ { "Michael Müller", "amstream: Correctly check return values in IAMMultiMediaStreamImpl_Initialize (Coverity).", 1 },'; - echo '+ { "Michael Müller", "kernel32: Correctly check for an empty short filename in GetShortPathNameW (Coverity).", 1 },'; ) >> "$patchlist" fi diff --git a/patches/riched20-IText_Interface/0001-riched20-Implement-IText-Selection-Range-Set-Start-E.patch b/patches/riched20-IText_Interface/0001-riched20-Implement-IText-Selection-Range-Set-Start-E.patch index 3e2f7f8c..3379b5f1 100644 --- a/patches/riched20-IText_Interface/0001-riched20-Implement-IText-Selection-Range-Set-Start-E.patch +++ b/patches/riched20-IText_Interface/0001-riched20-Implement-IText-Selection-Range-Set-Start-E.patch @@ -1,4 +1,4 @@ -From c7baa273ffbfe58fa195d5f61a9a5a03ed86dceb Mon Sep 17 00:00:00 2001 +From 41acfc2923995baef4ed18edf3803ba159464457 Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Fri, 8 Aug 2014 21:32:57 +0800 Subject: riched20: Implement IText{Selection, Range}::Set{Start, End}. @@ -8,10 +8,10 @@ Subject: riched20: Implement IText{Selection, Range}::Set{Start, End}. 1 file changed, 135 insertions(+) diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index 3e41ede..49d4652 100644 +index 318b386..957cbee 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -2806,6 +2806,137 @@ static void test_Select(void) +@@ -3072,6 +3072,137 @@ static void test_SetFont(void) ITextSelection_Release(selection); } @@ -149,7 +149,7 @@ index 3e41ede..49d4652 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -2818,12 +2949,16 @@ START_TEST(richole) +@@ -3084,11 +3215,15 @@ START_TEST(richole) test_GetText(); test_ITextSelection_GetChar(); test_ITextSelection_GetStart_GetEnd(); @@ -160,12 +160,11 @@ index 3e41ede..49d4652 100644 test_ITextRange_GetChar(); test_ITextRange_GetStart_GetEnd(); test_ITextRange_GetDuplicate(); - test_ITextRange_Collapse(); + test_ITextRange_SetStart(); + test_ITextRange_SetEnd(); - test_IOleClientSite_QueryInterface(); + test_ITextRange_Collapse(); + test_GetClientSite(); test_IOleWindow_GetWindow(); - test_IOleInPlaceSite_GetWindow(); -- -2.4.1 +2.4.2 diff --git a/patches/riched20-IText_Interface/0002-riched20-Stub-for-ITextFont-interface-and-implement-.patch b/patches/riched20-IText_Interface/0002-riched20-Stub-for-ITextFont-interface-and-implement-.patch index 6868a8e0..51a3d8bb 100644 --- a/patches/riched20-IText_Interface/0002-riched20-Stub-for-ITextFont-interface-and-implement-.patch +++ b/patches/riched20-IText_Interface/0002-riched20-Stub-for-ITextFont-interface-and-implement-.patch @@ -1,4 +1,4 @@ -From 6a9811fc03e0199c92abbd9e36a56000afdcc107 Mon Sep 17 00:00:00 2001 +From ae80466c3ae5494b123bbcc7f210b85691d94eb2 Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Mon, 11 Aug 2014 13:51:55 +0800 Subject: riched20: Stub for ITextFont interface and implement @@ -10,10 +10,10 @@ Subject: riched20: Stub for ITextFont interface and implement 2 files changed, 113 insertions(+) diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c -index 14c4c8e..b995608 100644 +index f3a4a01..9f31654 100644 --- a/dlls/riched20/richole.c +++ b/dlls/riched20/richole.c -@@ -2243,6 +2243,10 @@ static HRESULT WINAPI TextFont_SetDuplicate(ITextFont *iface, ITextFont *pFont) +@@ -2526,6 +2526,10 @@ static HRESULT WINAPI TextFont_SetDuplicate(ITextFont *iface, ITextFont *pFont) { ITextFontImpl *This = impl_from_ITextFont(iface); FIXME("(%p)->(%p): stub\n", This, pFont); @@ -24,7 +24,7 @@ index 14c4c8e..b995608 100644 return E_NOTIMPL; } -@@ -2250,6 +2254,10 @@ static HRESULT WINAPI TextFont_CanChange(ITextFont *iface, LONG *ret) +@@ -2533,6 +2537,10 @@ static HRESULT WINAPI TextFont_CanChange(ITextFont *iface, LONG *ret) { ITextFontImpl *This = impl_from_ITextFont(iface); FIXME("(%p)->(%p): stub\n", This, ret); @@ -35,7 +35,7 @@ index 14c4c8e..b995608 100644 return E_NOTIMPL; } -@@ -2257,6 +2265,10 @@ static HRESULT WINAPI TextFont_IsEqual(ITextFont *iface, ITextFont *font, LONG * +@@ -2540,6 +2548,10 @@ static HRESULT WINAPI TextFont_IsEqual(ITextFont *iface, ITextFont *font, LONG * { ITextFontImpl *This = impl_from_ITextFont(iface); FIXME("(%p)->(%p %p): stub\n", This, font, ret); @@ -46,7 +46,7 @@ index 14c4c8e..b995608 100644 return E_NOTIMPL; } -@@ -2424,6 +2436,10 @@ static HRESULT WINAPI TextFont_GetStyle(ITextFont *iface, LONG *value) +@@ -2713,6 +2725,10 @@ static HRESULT WINAPI TextFont_GetStyle(ITextFont *iface, LONG *value) { ITextFontImpl *This = impl_from_ITextFont(iface); FIXME("(%p)->(%p): stub\n", This, value); @@ -57,7 +57,7 @@ index 14c4c8e..b995608 100644 return E_NOTIMPL; } -@@ -2431,6 +2447,10 @@ static HRESULT WINAPI TextFont_SetStyle(ITextFont *iface, LONG value) +@@ -2720,6 +2736,10 @@ static HRESULT WINAPI TextFont_SetStyle(ITextFont *iface, LONG value) { ITextFontImpl *This = impl_from_ITextFont(iface); FIXME("(%p)->(%d): stub\n", This, value); @@ -69,10 +69,10 @@ index 14c4c8e..b995608 100644 } diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index 45ec28a..77e8ea9 100644 +index 957cbee..02576a8 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -2618,6 +2618,97 @@ static void test_ITextSelection_SetEnd(void) +@@ -3203,6 +3203,97 @@ static void test_ITextSelection_SetEnd(void) release_interfaces(&w, &reOle, &txtDoc, &txtSel); } @@ -170,7 +170,7 @@ index 45ec28a..77e8ea9 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -2633,6 +2724,7 @@ START_TEST(richole) +@@ -3218,6 +3309,7 @@ START_TEST(richole) test_ITextSelection_SetStart(); test_ITextSelection_SetEnd(); test_ITextSelection_Collapse(); @@ -178,14 +178,14 @@ index 45ec28a..77e8ea9 100644 test_ITextDocument_Range(); test_ITextRange_GetChar(); test_ITextRange_GetStart_GetEnd(); -@@ -2640,6 +2732,7 @@ START_TEST(richole) - test_ITextRange_Collapse(); +@@ -3225,6 +3317,7 @@ START_TEST(richole) test_ITextRange_SetStart(); test_ITextRange_SetEnd(); + test_ITextRange_Collapse(); + test_ITextRange_GetFont(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); -- -2.4.1 +2.4.2 diff --git a/patches/riched20-IText_Interface/0003-riched20-Stub-for-ITextPara-interface-and-implement-.patch b/patches/riched20-IText_Interface/0003-riched20-Stub-for-ITextPara-interface-and-implement-.patch index 24c6d04b..d3786010 100644 --- a/patches/riched20-IText_Interface/0003-riched20-Stub-for-ITextPara-interface-and-implement-.patch +++ b/patches/riched20-IText_Interface/0003-riched20-Stub-for-ITextPara-interface-and-implement-.patch @@ -1,4 +1,4 @@ -From 39049f221562446f83685c72e72aaf002a6dbf70 Mon Sep 17 00:00:00 2001 +From cdbc7f63c0cf485261d76ee0e908c041b3850a18 Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Sun, 10 Aug 2014 22:17:57 +0800 Subject: riched20: Stub for ITextPara interface and implement @@ -10,10 +10,10 @@ Subject: riched20: Stub for ITextPara interface and implement 2 files changed, 249 insertions(+) diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c -index de70bc3..9605404 100644 +index 9f31654..c9e4753 100644 --- a/dlls/riched20/richole.c +++ b/dlls/riched20/richole.c -@@ -2668,6 +2668,16 @@ static ULONG WINAPI TextPara_Release(ITextPara *iface) +@@ -3246,6 +3246,16 @@ static ULONG WINAPI TextPara_Release(ITextPara *iface) return ref; } @@ -22,7 +22,7 @@ index de70bc3..9605404 100644 + if (This->range) + { + ITextRangeImpl *rng = impl_from_ITextRange(This->range); -+ return rng->reOle; ++ return rng->child.reole; + } + return NULL; +} @@ -30,7 +30,7 @@ index de70bc3..9605404 100644 static HRESULT WINAPI TextPara_GetTypeInfoCount(ITextPara *iface, UINT *pctinfo) { ITextParaImpl *This = impl_from_ITextPara(iface); -@@ -2734,6 +2744,10 @@ static HRESULT WINAPI TextPara_GetDuplicate(ITextPara *iface, ITextPara **ret) +@@ -3312,6 +3322,10 @@ static HRESULT WINAPI TextPara_GetDuplicate(ITextPara *iface, ITextPara **ret) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, ret); @@ -41,7 +41,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2741,6 +2755,10 @@ static HRESULT WINAPI TextPara_SetDuplicate(ITextPara *iface, ITextPara *para) +@@ -3319,6 +3333,10 @@ static HRESULT WINAPI TextPara_SetDuplicate(ITextPara *iface, ITextPara *para) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, para); @@ -52,7 +52,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2748,6 +2766,10 @@ static HRESULT WINAPI TextPara_CanChange(ITextPara *iface, LONG *ret) +@@ -3326,6 +3344,10 @@ static HRESULT WINAPI TextPara_CanChange(ITextPara *iface, LONG *ret) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, ret); @@ -63,7 +63,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2755,6 +2777,10 @@ static HRESULT WINAPI TextPara_IsEqual(ITextPara *iface, ITextPara *para, LONG * +@@ -3333,6 +3355,10 @@ static HRESULT WINAPI TextPara_IsEqual(ITextPara *iface, ITextPara *para, LONG * { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p %p)\n", This, para, ret); @@ -74,7 +74,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2762,6 +2788,10 @@ static HRESULT WINAPI TextPara_Reset(ITextPara *iface, LONG value) +@@ -3340,6 +3366,10 @@ static HRESULT WINAPI TextPara_Reset(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -85,7 +85,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2769,6 +2799,10 @@ static HRESULT WINAPI TextPara_GetStyle(ITextPara *iface, LONG *value) +@@ -3347,6 +3377,10 @@ static HRESULT WINAPI TextPara_GetStyle(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -96,7 +96,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2776,6 +2810,10 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value) +@@ -3354,6 +3388,10 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -107,7 +107,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2783,6 +2821,10 @@ static HRESULT WINAPI TextPara_GetAlignment(ITextPara *iface, LONG *value) +@@ -3361,6 +3399,10 @@ static HRESULT WINAPI TextPara_GetAlignment(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -118,7 +118,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2790,6 +2832,10 @@ static HRESULT WINAPI TextPara_SetAlignment(ITextPara *iface, LONG value) +@@ -3368,6 +3410,10 @@ static HRESULT WINAPI TextPara_SetAlignment(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -129,7 +129,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2797,6 +2843,10 @@ static HRESULT WINAPI TextPara_GetHyphenation(ITextPara *iface, LONG *value) +@@ -3375,6 +3421,10 @@ static HRESULT WINAPI TextPara_GetHyphenation(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -140,7 +140,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2804,6 +2854,10 @@ static HRESULT WINAPI TextPara_SetHyphenation(ITextPara *iface, LONG value) +@@ -3382,6 +3432,10 @@ static HRESULT WINAPI TextPara_SetHyphenation(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -151,7 +151,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2811,6 +2865,10 @@ static HRESULT WINAPI TextPara_GetFirstLineIndent(ITextPara *iface, FLOAT *value +@@ -3389,6 +3443,10 @@ static HRESULT WINAPI TextPara_GetFirstLineIndent(ITextPara *iface, FLOAT *value { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -162,7 +162,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2818,6 +2876,10 @@ static HRESULT WINAPI TextPara_GetKeepTogether(ITextPara *iface, LONG *value) +@@ -3396,6 +3454,10 @@ static HRESULT WINAPI TextPara_GetKeepTogether(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -173,7 +173,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2825,6 +2887,10 @@ static HRESULT WINAPI TextPara_SetKeepTogether(ITextPara *iface, LONG value) +@@ -3403,6 +3465,10 @@ static HRESULT WINAPI TextPara_SetKeepTogether(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -184,7 +184,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2832,6 +2898,10 @@ static HRESULT WINAPI TextPara_GetKeepWithNext(ITextPara *iface, LONG *value) +@@ -3410,6 +3476,10 @@ static HRESULT WINAPI TextPara_GetKeepWithNext(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -195,7 +195,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2839,6 +2909,10 @@ static HRESULT WINAPI TextPara_SetKeepWithNext(ITextPara *iface, LONG value) +@@ -3417,6 +3487,10 @@ static HRESULT WINAPI TextPara_SetKeepWithNext(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -206,7 +206,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2846,6 +2920,10 @@ static HRESULT WINAPI TextPara_GetLeftIndent(ITextPara *iface, FLOAT *value) +@@ -3424,6 +3498,10 @@ static HRESULT WINAPI TextPara_GetLeftIndent(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -217,7 +217,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2853,6 +2931,10 @@ static HRESULT WINAPI TextPara_GetLineSpacing(ITextPara *iface, FLOAT *value) +@@ -3431,6 +3509,10 @@ static HRESULT WINAPI TextPara_GetLineSpacing(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -228,7 +228,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2860,6 +2942,10 @@ static HRESULT WINAPI TextPara_GetLineSpacingRule(ITextPara *iface, LONG *value) +@@ -3438,6 +3520,10 @@ static HRESULT WINAPI TextPara_GetLineSpacingRule(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -239,7 +239,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2867,6 +2953,10 @@ static HRESULT WINAPI TextPara_GetListAlignment(ITextPara *iface, LONG *value) +@@ -3445,6 +3531,10 @@ static HRESULT WINAPI TextPara_GetListAlignment(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -250,7 +250,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2874,6 +2964,10 @@ static HRESULT WINAPI TextPara_SetListAlignment(ITextPara *iface, LONG value) +@@ -3452,6 +3542,10 @@ static HRESULT WINAPI TextPara_SetListAlignment(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -261,7 +261,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2881,6 +2975,10 @@ static HRESULT WINAPI TextPara_GetListLevelIndex(ITextPara *iface, LONG *value) +@@ -3459,6 +3553,10 @@ static HRESULT WINAPI TextPara_GetListLevelIndex(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -272,7 +272,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2888,6 +2986,10 @@ static HRESULT WINAPI TextPara_SetListLevelIndex(ITextPara *iface, LONG value) +@@ -3466,6 +3564,10 @@ static HRESULT WINAPI TextPara_SetListLevelIndex(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -283,7 +283,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2895,6 +2997,10 @@ static HRESULT WINAPI TextPara_GetListStart(ITextPara *iface, LONG *value) +@@ -3473,6 +3575,10 @@ static HRESULT WINAPI TextPara_GetListStart(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -294,7 +294,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2902,6 +3008,10 @@ static HRESULT WINAPI TextPara_SetListStart(ITextPara *iface, LONG value) +@@ -3480,6 +3586,10 @@ static HRESULT WINAPI TextPara_SetListStart(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -305,7 +305,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2909,6 +3019,10 @@ static HRESULT WINAPI TextPara_GetListTab(ITextPara *iface, FLOAT *value) +@@ -3487,6 +3597,10 @@ static HRESULT WINAPI TextPara_GetListTab(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -316,7 +316,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2916,6 +3030,10 @@ static HRESULT WINAPI TextPara_SetListTab(ITextPara *iface, FLOAT value) +@@ -3494,6 +3608,10 @@ static HRESULT WINAPI TextPara_SetListTab(ITextPara *iface, FLOAT value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f)\n", This, value); @@ -327,7 +327,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2923,6 +3041,10 @@ static HRESULT WINAPI TextPara_GetListType(ITextPara *iface, LONG *value) +@@ -3501,6 +3619,10 @@ static HRESULT WINAPI TextPara_GetListType(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -338,7 +338,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2930,6 +3052,10 @@ static HRESULT WINAPI TextPara_SetListType(ITextPara *iface, LONG value) +@@ -3508,6 +3630,10 @@ static HRESULT WINAPI TextPara_SetListType(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -349,7 +349,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2937,6 +3063,10 @@ static HRESULT WINAPI TextPara_GetNoLineNumber(ITextPara *iface, LONG *value) +@@ -3515,6 +3641,10 @@ static HRESULT WINAPI TextPara_GetNoLineNumber(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -360,7 +360,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2944,6 +3074,10 @@ static HRESULT WINAPI TextPara_SetNoLineNumber(ITextPara *iface, LONG value) +@@ -3522,6 +3652,10 @@ static HRESULT WINAPI TextPara_SetNoLineNumber(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -371,7 +371,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2951,6 +3085,10 @@ static HRESULT WINAPI TextPara_GetPageBreakBefore(ITextPara *iface, LONG *value) +@@ -3529,6 +3663,10 @@ static HRESULT WINAPI TextPara_GetPageBreakBefore(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -382,7 +382,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2958,6 +3096,10 @@ static HRESULT WINAPI TextPara_SetPageBreakBefore(ITextPara *iface, LONG value) +@@ -3536,6 +3674,10 @@ static HRESULT WINAPI TextPara_SetPageBreakBefore(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -393,7 +393,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2965,6 +3107,10 @@ static HRESULT WINAPI TextPara_GetRightIndent(ITextPara *iface, FLOAT *value) +@@ -3543,6 +3685,10 @@ static HRESULT WINAPI TextPara_GetRightIndent(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -404,7 +404,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2972,6 +3118,10 @@ static HRESULT WINAPI TextPara_SetRightIndent(ITextPara *iface, FLOAT value) +@@ -3550,6 +3696,10 @@ static HRESULT WINAPI TextPara_SetRightIndent(ITextPara *iface, FLOAT value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f)\n", This, value); @@ -415,7 +415,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2979,6 +3129,10 @@ static HRESULT WINAPI TextPara_SetIndents(ITextPara *iface, FLOAT StartIndent, F +@@ -3557,6 +3707,10 @@ static HRESULT WINAPI TextPara_SetIndents(ITextPara *iface, FLOAT StartIndent, F { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f %.2f %.2f)\n", This, StartIndent, LeftIndent, RightIndent); @@ -426,7 +426,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2986,6 +3140,10 @@ static HRESULT WINAPI TextPara_SetLineSpacing(ITextPara *iface, LONG LineSpacing +@@ -3564,6 +3718,10 @@ static HRESULT WINAPI TextPara_SetLineSpacing(ITextPara *iface, LONG LineSpacing { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d %.2f)\n", This, LineSpacingRule, LineSpacing); @@ -437,7 +437,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -2993,6 +3151,10 @@ static HRESULT WINAPI TextPara_GetSpaceAfter(ITextPara *iface, FLOAT *value) +@@ -3571,6 +3729,10 @@ static HRESULT WINAPI TextPara_GetSpaceAfter(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -448,7 +448,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3000,6 +3162,10 @@ static HRESULT WINAPI TextPara_SetSpaceAfter(ITextPara *iface, FLOAT value) +@@ -3578,6 +3740,10 @@ static HRESULT WINAPI TextPara_SetSpaceAfter(ITextPara *iface, FLOAT value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f)\n", This, value); @@ -459,7 +459,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3007,6 +3173,10 @@ static HRESULT WINAPI TextPara_GetSpaceBefore(ITextPara *iface, FLOAT *value) +@@ -3585,6 +3751,10 @@ static HRESULT WINAPI TextPara_GetSpaceBefore(ITextPara *iface, FLOAT *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -470,7 +470,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3014,6 +3184,10 @@ static HRESULT WINAPI TextPara_SetSpaceBefore(ITextPara *iface, FLOAT value) +@@ -3592,6 +3762,10 @@ static HRESULT WINAPI TextPara_SetSpaceBefore(ITextPara *iface, FLOAT value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f)\n", This, value); @@ -481,7 +481,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3021,6 +3195,10 @@ static HRESULT WINAPI TextPara_GetWidowControl(ITextPara *iface, LONG *value) +@@ -3599,6 +3773,10 @@ static HRESULT WINAPI TextPara_GetWidowControl(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -492,7 +492,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3028,6 +3206,10 @@ static HRESULT WINAPI TextPara_SetWidowControl(ITextPara *iface, LONG value) +@@ -3606,6 +3784,10 @@ static HRESULT WINAPI TextPara_SetWidowControl(ITextPara *iface, LONG value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d)\n", This, value); @@ -503,7 +503,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3035,6 +3217,10 @@ static HRESULT WINAPI TextPara_GetTabCount(ITextPara *iface, LONG *value) +@@ -3613,6 +3795,10 @@ static HRESULT WINAPI TextPara_GetTabCount(ITextPara *iface, LONG *value) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%p)\n", This, value); @@ -514,7 +514,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3042,6 +3228,10 @@ static HRESULT WINAPI TextPara_AddTab(ITextPara *iface, FLOAT tbPos, LONG tbAlig +@@ -3620,6 +3806,10 @@ static HRESULT WINAPI TextPara_AddTab(ITextPara *iface, FLOAT tbPos, LONG tbAlig { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f %d %d)\n", This, tbPos, tbAlign, tbLeader); @@ -525,7 +525,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3049,6 +3239,10 @@ static HRESULT WINAPI TextPara_ClearAllTabs(ITextPara *iface) +@@ -3627,6 +3817,10 @@ static HRESULT WINAPI TextPara_ClearAllTabs(ITextPara *iface) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)\n", This); @@ -536,7 +536,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3056,6 +3250,10 @@ static HRESULT WINAPI TextPara_DeleteTab(ITextPara *iface, FLOAT pos) +@@ -3634,6 +3828,10 @@ static HRESULT WINAPI TextPara_DeleteTab(ITextPara *iface, FLOAT pos) { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%.2f)\n", This, pos); @@ -547,7 +547,7 @@ index de70bc3..9605404 100644 return E_NOTIMPL; } -@@ -3063,6 +3261,10 @@ static HRESULT WINAPI TextPara_GetTab(ITextPara *iface, LONG iTab, FLOAT *ptbPos +@@ -3641,6 +3839,10 @@ static HRESULT WINAPI TextPara_GetTab(ITextPara *iface, LONG iTab, FLOAT *ptbPos { ITextParaImpl *This = impl_from_ITextPara(iface); FIXME("(%p)->(%d %p %p %p)\n", This, iTab, ptbPos, ptbAlign, ptbLeader); @@ -559,10 +559,10 @@ index de70bc3..9605404 100644 } diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index 8b72a1d..ab94b58 100644 +index 02576a8..06410e7 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -2256,6 +2256,52 @@ static void test_ITextSelection_GetFont(void) +@@ -3294,6 +3294,52 @@ static void test_ITextSelection_GetFont(void) ITextFont_Release(txtFont); } @@ -615,14 +615,14 @@ index 8b72a1d..ab94b58 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -2280,6 +2326,7 @@ START_TEST(richole) - test_ITextRange_SetStart(); +@@ -3318,6 +3364,7 @@ START_TEST(richole) test_ITextRange_SetEnd(); + test_ITextRange_Collapse(); test_ITextRange_GetFont(); + test_ITextRange_GetPara(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); -- -2.4.0 +2.4.2 diff --git a/patches/riched20-IText_Interface/0005-riched20-Implement-ITextRange-GetText.patch b/patches/riched20-IText_Interface/0005-riched20-Implement-ITextRange-GetText.patch index 4d48325e..dfbcc11f 100644 --- a/patches/riched20-IText_Interface/0005-riched20-Implement-ITextRange-GetText.patch +++ b/patches/riched20-IText_Interface/0005-riched20-Implement-ITextRange-GetText.patch @@ -1,183 +1,17 @@ -From 74ef4d73346d9607112923c1e9598b3c4db19433 Mon Sep 17 00:00:00 2001 +From 65420d15d3691b910578f3e2dab6d6c2fc25bbfe Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Wed, 13 Aug 2014 15:40:11 +0800 Subject: riched20: Implement ITextRange::GetText. --- - dlls/riched20/richole.c | 52 +++++++++++++++++++++++++------------------ - dlls/riched20/tests/richole.c | 52 +++++++++++++++++++++++++++++++------------ - 2 files changed, 68 insertions(+), 36 deletions(-) + dlls/riched20/tests/richole.c | 38 ++++++++++++++++++++++++++++++++++++++ + 1 file changed, 38 insertions(+) -diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c -index 155ebca..d0834da 100644 ---- a/dlls/riched20/richole.c -+++ b/dlls/riched20/richole.c -@@ -1393,11 +1393,36 @@ static HRESULT WINAPI ITextRange_fnInvoke(ITextRange *me, DISPID dispIdMember, R - return hr; - } - -+static HRESULT range_GetText(ME_TextEditor *editor, ME_Cursor *start, ME_Cursor *end, BSTR *pbstr) -+{ -+ int nChars, endOfs; -+ BOOL bEOP; -+ -+ endOfs = ME_GetCursorOfs(end); -+ nChars = endOfs - ME_GetCursorOfs(start); -+ if (!nChars) -+ { -+ *pbstr = NULL; -+ return S_OK; -+ } -+ -+ *pbstr = SysAllocStringLen(NULL, nChars); -+ if (!*pbstr) -+ return E_OUTOFMEMORY; -+ -+ bEOP = (end->pRun->next->type == diTextEnd && endOfs > ME_GetTextLength(editor)); -+ ME_GetTextW(editor, *pbstr, nChars, start, nChars, FALSE, bEOP); -+ TRACE("%s\n", wine_dbgstr_w(*pbstr)); -+ -+ return S_OK; -+} -+ - static HRESULT WINAPI ITextRange_fnGetText(ITextRange *me, BSTR *pbstr) - { - ITextRangeImpl *This = impl_from_ITextRange(me); -+ ME_Cursor start, end; - -- FIXME("(%p)->(%p): stub\n", This, pbstr); -+ TRACE("(%p)->(%p)\n", This, pbstr); - - if (!This->reOle) - return CO_E_RELEASED; -@@ -1405,8 +1430,9 @@ static HRESULT WINAPI ITextRange_fnGetText(ITextRange *me, BSTR *pbstr) - if (!pbstr) - return E_INVALIDARG; - -- *pbstr = NULL; -- return E_NOTIMPL; -+ ME_CursorFromCharOfs(This->reOle->editor, This->start, &start); -+ ME_CursorFromCharOfs(This->reOle->editor, This->end, &end); -+ return range_GetText(This->reOle->editor, &start, &end, pbstr); - } - - static HRESULT WINAPI ITextRange_fnSetText(ITextRange *me, BSTR str) -@@ -4051,8 +4077,6 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr) - { - ITextSelectionImpl *This = impl_from_ITextSelection(me); - ME_Cursor *start = NULL, *end = NULL; -- int nChars, endOfs; -- BOOL bEOP; - - TRACE("(%p)->(%p)\n", This, pbstr); - -@@ -4063,23 +4087,7 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr) - return E_INVALIDARG; - - ME_GetSelection(This->reOle->editor, &start, &end); -- endOfs = ME_GetCursorOfs(end); -- nChars = endOfs - ME_GetCursorOfs(start); -- if (!nChars) -- { -- *pbstr = NULL; -- return S_OK; -- } -- -- *pbstr = SysAllocStringLen(NULL, nChars); -- if (!*pbstr) -- return E_OUTOFMEMORY; -- -- bEOP = (end->pRun->next->type == diTextEnd && endOfs > ME_GetTextLength(This->reOle->editor)); -- ME_GetTextW(This->reOle->editor, *pbstr, nChars, start, nChars, FALSE, bEOP); -- TRACE("%s\n", wine_dbgstr_w(*pbstr)); -- -- return S_OK; -+ return range_GetText(This->reOle->editor, start, end, pbstr); - } - - static HRESULT WINAPI ITextSelection_fnSetText(ITextSelection *me, BSTR str) diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index 0065196..d7642d4 100644 +index 06410e7..05c1f34 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -529,27 +529,22 @@ static void test_GetText(void) - hres = ITextDocument_Range(txtDoc, 0, 4, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW1), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - ITextRange_Release(range); - - hres = ITextDocument_Range(txtDoc, 4, 0, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW1), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - ITextRange_Release(range); - - hres = ITextDocument_Range(txtDoc, 1, 1, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!bstr, "got wrong text: %s\n", wine_dbgstr_w(bstr)); - if (!is64bit) -@@ -562,37 +557,30 @@ todo_wine - hres = ITextDocument_Range(txtDoc, 8, 12, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW3), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - ITextRange_Release(range); - - hres = ITextDocument_Range(txtDoc, 8, 13, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW2), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - ITextRange_Release(range); - - hres = ITextDocument_Range(txtDoc, 12, 13, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW5), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - ITextRange_Release(range); - - hres = ITextDocument_Range(txtDoc, 0, -1, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!bstr, "got wrong text: %s\n", wine_dbgstr_w(bstr)); - ITextRange_Release(range); -@@ -600,10 +588,8 @@ todo_wine - hres = ITextDocument_Range(txtDoc, -1, 9, &range); - ok(hres == S_OK, "got 0x%08x\n", hres); - hres = ITextRange_GetText(range, &bstr); --todo_wine { - ok(hres == S_OK, "got 0x%08x\n", hres); - ok(!lstrcmpW(bstr, bufW6), "got wrong text: %s\n", wine_dbgstr_w(bstr)); --} - SysFreeString(bstr); - - release_interfaces(&w, &reOle, &txtDoc, NULL); -@@ -2755,6 +2741,43 @@ static void test_ITextRange_GetPara(void) +@@ -3340,6 +3340,43 @@ static void test_ITextRange_GetPara(void) ITextPara_Release(txtPara); } @@ -221,14 +55,14 @@ index 0065196..d7642d4 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -2780,6 +2803,7 @@ START_TEST(richole) - test_ITextRange_SetEnd(); +@@ -3365,6 +3402,7 @@ START_TEST(richole) + test_ITextRange_Collapse(); test_ITextRange_GetFont(); test_ITextRange_GetPara(); + test_ITextRange_GetText(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); -- -2.4.1 +2.4.2 diff --git a/patches/riched20-IText_Interface/0006-riched20-Implement-ITextRange-SetRange.patch b/patches/riched20-IText_Interface/0006-riched20-Implement-ITextRange-SetRange.patch index 48bbf3b9..c2d60805 100644 --- a/patches/riched20-IText_Interface/0006-riched20-Implement-ITextRange-SetRange.patch +++ b/patches/riched20-IText_Interface/0006-riched20-Implement-ITextRange-SetRange.patch @@ -1,4 +1,4 @@ -From cbae34419bf155b9bebae7bf28a90722b81fde5a Mon Sep 17 00:00:00 2001 +From e97c89d122de411b7889944b20b4cefa20e1f848 Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Wed, 13 Aug 2014 17:17:14 +0800 Subject: riched20: Implement ITextRange::SetRange. @@ -9,10 +9,10 @@ Subject: riched20: Implement ITextRange::SetRange. 2 files changed, 60 insertions(+), 17 deletions(-) diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c -index 1d22a3d..5795dd3 100644 +index c9e4753..6762441 100644 --- a/dlls/riched20/richole.c +++ b/dlls/riched20/richole.c -@@ -1766,14 +1766,36 @@ static HRESULT WINAPI ITextRange_fnSetIndex(ITextRange *me, LONG Unit, LONG Inde +@@ -1974,14 +1974,36 @@ static HRESULT WINAPI ITextRange_fnSetIndex(ITextRange *me, LONG Unit, LONG Inde return E_NOTIMPL; } @@ -36,12 +36,12 @@ index 1d22a3d..5795dd3 100644 static HRESULT WINAPI ITextRange_fnSetRange(ITextRange *me, LONG cpActive, LONG cpOther) { ITextRangeImpl *This = impl_from_ITextRange(me); - if (!This->reOle) + if (!This->child.reole) return CO_E_RELEASED; - FIXME("not implemented %p\n", This); - return E_NOTIMPL; -+ cp2range(This->reOle->editor, &cpActive, &cpOther); ++ cp2range(This->child.reole->editor, &cpActive, &cpOther); + if (cpActive == This->start && cpOther == This->end) + return S_FALSE; + @@ -51,7 +51,7 @@ index 1d22a3d..5795dd3 100644 } static HRESULT textrange_inrange(LONG start, LONG end, ITextRange *range, LONG *ret) -@@ -3956,26 +3978,12 @@ ITextDocument_fnRange(ITextDocument* me, LONG cp1, LONG cp2, +@@ -4180,26 +4202,12 @@ ITextDocument_fnRange(ITextDocument* me, LONG cp1, LONG cp2, ITextRange** ppRange) { IRichEditOleImpl *This = impl_from_ITextDocument(me); @@ -80,10 +80,10 @@ index 1d22a3d..5795dd3 100644 } diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index d4cc049..529d2e0 100644 +index 05c1f34..4c8a2e5 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -3097,6 +3097,40 @@ static void test_ITextRange_GetText(void) +@@ -3377,6 +3377,40 @@ static void test_ITextRange_GetText(void) TEST_TXTRGE_GETTEXT(1, 1, NULL) } @@ -124,14 +124,14 @@ index d4cc049..529d2e0 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -3123,6 +3157,7 @@ START_TEST(richole) +@@ -3403,6 +3437,7 @@ START_TEST(richole) test_ITextRange_GetFont(); test_ITextRange_GetPara(); test_ITextRange_GetText(); + test_ITextRange_SetRange(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); -- -2.4.1 +2.4.2 diff --git a/patches/riched20-IText_Interface/0007-riched20-Implement-ITextRange-IsEqual.patch b/patches/riched20-IText_Interface/0007-riched20-Implement-ITextRange-IsEqual.patch index 7e81db36..7ad6ccef 100644 --- a/patches/riched20-IText_Interface/0007-riched20-Implement-ITextRange-IsEqual.patch +++ b/patches/riched20-IText_Interface/0007-riched20-Implement-ITextRange-IsEqual.patch @@ -1,4 +1,4 @@ -From c3c1be38502880aa25b1ec2f26765802ba87d3dc Mon Sep 17 00:00:00 2001 +From 068997a807063442045442273323dc5d2e62835c Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Fri, 15 Aug 2014 14:27:21 +0800 Subject: riched20: Implement ITextRange::IsEqual. @@ -8,10 +8,10 @@ Subject: riched20: Implement ITextRange::IsEqual. 1 file changed, 47 insertions(+) diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index 529d2e0..451d888 100644 +index 4c8a2e5..2618138 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -3131,6 +3131,52 @@ static void test_ITextRange_SetRange(void) +@@ -3411,6 +3411,52 @@ static void test_ITextRange_SetRange(void) release_interfaces(&w, &reOle, &txtDoc, NULL); } @@ -64,14 +64,14 @@ index 529d2e0..451d888 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -3158,6 +3204,7 @@ START_TEST(richole) +@@ -3438,6 +3484,7 @@ START_TEST(richole) test_ITextRange_GetPara(); test_ITextRange_GetText(); test_ITextRange_SetRange(); + test_ITextRange_IsEqual2(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); -- -2.4.1 +2.4.2 diff --git a/patches/riched20-IText_Interface/0008-riched20-Implement-ITextRange-GetStoryLength.patch b/patches/riched20-IText_Interface/0008-riched20-Implement-ITextRange-GetStoryLength.patch index 6cc7f0ef..444e0796 100644 --- a/patches/riched20-IText_Interface/0008-riched20-Implement-ITextRange-GetStoryLength.patch +++ b/patches/riched20-IText_Interface/0008-riched20-Implement-ITextRange-GetStoryLength.patch @@ -1,35 +1,41 @@ -From c8561b8c1e51a425fa58a7a1ed3ce178930448b2 Mon Sep 17 00:00:00 2001 +From c0a3f18523c07ebb9bb26a6902ce07c69f283ca6 Mon Sep 17 00:00:00 2001 From: Jactry Zeng Date: Mon, 18 Aug 2014 14:38:50 +0800 Subject: riched20: Implement ITextRange::GetStoryLength. --- - dlls/riched20/richole.c | 6 ++++-- + dlls/riched20/richole.c | 9 +++++++-- dlls/riched20/tests/richole.c | 32 ++++++++++++++++++++++++++++++++ - 2 files changed, 36 insertions(+), 2 deletions(-) + 2 files changed, 39 insertions(+), 2 deletions(-) diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c -index 33eeca8..26a6da6 100644 +index 6762441..1817c09 100644 --- a/dlls/riched20/richole.c +++ b/dlls/riched20/richole.c -@@ -1876,8 +1876,10 @@ static HRESULT WINAPI ITextRange_fnGetStoryLength(ITextRange *me, LONG *pcch) - if (!This->reOle) +@@ -1896,11 +1896,16 @@ static HRESULT WINAPI ITextRange_fnSetPara(ITextRange *me, ITextPara *pPara) + static HRESULT WINAPI ITextRange_fnGetStoryLength(ITextRange *me, LONG *pcch) + { + ITextRangeImpl *This = impl_from_ITextRange(me); ++ ++ TRACE("(%p)->(%p)\n", This, pcch); ++ + if (!This->child.reole) return CO_E_RELEASED; - FIXME("not implemented %p\n", This); - return E_NOTIMPL; + if (!pcch) + return E_INVALIDARG; -+ *pcch = ME_GetTextLength(This->reOle->editor) + 1; ++ *pcch = ME_GetTextLength(This->child.reole->editor) + 1; + return S_OK; } static HRESULT WINAPI ITextRange_fnGetStoryType(ITextRange *me, LONG *value) diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c -index e905321..72f324e 100644 +index 2618138..c9bdc28 100644 --- a/dlls/riched20/tests/richole.c +++ b/dlls/riched20/tests/richole.c -@@ -3448,6 +3448,37 @@ static void test_ITextRange_IsEqual2(void) +@@ -3457,6 +3457,37 @@ static void test_ITextRange_IsEqual2(void) release_interfaces(&w, &reOle, &txtDoc, NULL); } @@ -67,12 +73,12 @@ index e905321..72f324e 100644 START_TEST(richole) { /* Must explicitly LoadLibrary(). The test has no references to functions in -@@ -3476,6 +3507,7 @@ START_TEST(richole) +@@ -3485,6 +3516,7 @@ START_TEST(richole) test_ITextRange_GetText(); test_ITextRange_SetRange(); test_ITextRange_IsEqual2(); + test_ITextRange_GetStoryLength(); - test_IOleClientSite_QueryInterface(); + test_GetClientSite(); test_IOleWindow_GetWindow(); test_IOleInPlaceSite_GetWindow(); --