You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-04-13 14:42:51 -07:00
Rebase against 98b991fdcf3f2cdbdae7d61203367ce9728a5e6d.
This commit is contained in:
@@ -1,95 +1,18 @@
|
||||
From 366724a8595982b9d1159509188899afb227ecf5 Mon Sep 17 00:00:00 2001
|
||||
From cb74e4d8de36f0dfe8ab47f9a2a5394127142104 Mon Sep 17 00:00:00 2001
|
||||
From: Jactry Zeng <wine@jactry.com>
|
||||
Date: Fri, 8 Aug 2014 21:32:57 +0800
|
||||
Subject: riched20: Implement IText{Selection, Range}::Set{Start, End}.
|
||||
|
||||
---
|
||||
dlls/riched20/richole.c | 46 ++++++++++++--
|
||||
dlls/riched20/tests/richole.c | 135 ++++++++++++++++++++++++++++++++++++++++++
|
||||
2 files changed, 177 insertions(+), 4 deletions(-)
|
||||
1 file changed, 135 insertions(+)
|
||||
|
||||
diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c
|
||||
index 3a4eb3b..f93f086 100644
|
||||
--- a/dlls/riched20/richole.c
|
||||
+++ b/dlls/riched20/richole.c
|
||||
@@ -3270,14 +3270,33 @@ static HRESULT WINAPI ITextSelection_fnGetStart(ITextSelection *me, LONG *pcpFir
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
+static HRESULT range_SetStart(ME_TextEditor *editor, LONG cpFirst, LONG *start, LONG *end)
|
||||
+{
|
||||
+ int len = ME_GetTextLength(editor);
|
||||
+
|
||||
+ TRACE("%d\n", cpFirst);
|
||||
+ if (cpFirst == *start)
|
||||
+ return S_FALSE;
|
||||
+ cpFirst = min(cpFirst, len);
|
||||
+ cpFirst = max(cpFirst, 0);
|
||||
+ *end = max(*end, cpFirst);
|
||||
+ *start = cpFirst;
|
||||
+ return S_OK;
|
||||
+}
|
||||
+
|
||||
static HRESULT WINAPI ITextSelection_fnSetStart(ITextSelection *me, LONG cpFirst)
|
||||
{
|
||||
ITextSelectionImpl *This = impl_from_ITextSelection(me);
|
||||
+ int start, end;
|
||||
+ HRESULT hres;
|
||||
if (!This->reOle)
|
||||
return CO_E_RELEASED;
|
||||
|
||||
- FIXME("not implemented\n");
|
||||
- return E_NOTIMPL;
|
||||
+ ME_GetSelectionOfs(This->reOle->editor, &start, &end);
|
||||
+ hres = range_SetStart(This->reOle->editor, cpFirst, &start, &end);
|
||||
+ if (!hres)
|
||||
+ ME_SetSelection(This->reOle->editor, start, end);
|
||||
+ return hres;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ITextSelection_fnGetEnd(ITextSelection *me, LONG *pcpLim)
|
||||
@@ -3294,14 +3313,33 @@ static HRESULT WINAPI ITextSelection_fnGetEnd(ITextSelection *me, LONG *pcpLim)
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
+static HRESULT range_SetEnd(ME_TextEditor *editor, LONG cpLim, LONG *start, LONG *end)
|
||||
+{
|
||||
+ int len = ME_GetTextLength(editor) + 1;
|
||||
+
|
||||
+ TRACE("%d\n", cpLim);
|
||||
+ if (cpLim == *end)
|
||||
+ return S_FALSE;
|
||||
+ cpLim = min(cpLim, len);
|
||||
+ cpLim = max(cpLim, 0);
|
||||
+ *start = min(*start, cpLim);
|
||||
+ *end = cpLim;
|
||||
+ return S_OK;
|
||||
+}
|
||||
+
|
||||
static HRESULT WINAPI ITextSelection_fnSetEnd(ITextSelection *me, LONG cpLim)
|
||||
{
|
||||
ITextSelectionImpl *This = impl_from_ITextSelection(me);
|
||||
+ int start, end;
|
||||
+ HRESULT hres;
|
||||
if (!This->reOle)
|
||||
return CO_E_RELEASED;
|
||||
|
||||
- FIXME("not implemented\n");
|
||||
- return E_NOTIMPL;
|
||||
+ ME_GetSelectionOfs(This->reOle->editor, &start, &end);
|
||||
+ hres = range_SetEnd(This->reOle->editor, cpLim, &start, &end);
|
||||
+ if (!hres)
|
||||
+ ME_SetSelection(This->reOle->editor, start, end);
|
||||
+ return hres;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ITextSelection_fnGetFont(ITextSelection *me, ITextFont **font)
|
||||
diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c
|
||||
index 5472ce1..e654653 100644
|
||||
index 18ee8e0..dbd8dd2 100644
|
||||
--- a/dlls/riched20/tests/richole.c
|
||||
+++ b/dlls/riched20/tests/richole.c
|
||||
@@ -1570,6 +1570,137 @@ static void test_ITextFont(void)
|
||||
ITextFont_Release(font);
|
||||
@@ -2034,6 +2034,137 @@ todo_wine
|
||||
release_interfaces(&hwnd, &reOle, &doc, NULL);
|
||||
}
|
||||
|
||||
+static void test_ITextRange_SetStart(void)
|
||||
@@ -226,8 +149,8 @@ index 5472ce1..e654653 100644
|
||||
START_TEST(richole)
|
||||
{
|
||||
/* Must explicitly LoadLibrary(). The test has no references to functions in
|
||||
@@ -1582,12 +1713,16 @@ START_TEST(richole)
|
||||
test_ITextSelection_GetText();
|
||||
@@ -2046,12 +2177,16 @@ START_TEST(richole)
|
||||
test_GetText();
|
||||
test_ITextSelection_GetChar();
|
||||
test_ITextSelection_GetStart_GetEnd();
|
||||
+ test_ITextSelection_SetStart();
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -1,19 +1,19 @@
|
||||
From 4fb5a547a488fe7e1e1acfc090ae0e919f7f0e65 Mon Sep 17 00:00:00 2001
|
||||
From 39049f221562446f83685c72e72aaf002a6dbf70 Mon Sep 17 00:00:00 2001
|
||||
From: Jactry Zeng <wine@jactry.com>
|
||||
Date: Sun, 10 Aug 2014 22:17:57 +0800
|
||||
Subject: riched20: Stub for ITextPara interface and implement
|
||||
ITextRange::GetPara.
|
||||
|
||||
---
|
||||
dlls/riched20/richole.c | 222 ++++++++++++++++++++++++++++++++++++++++++
|
||||
dlls/riched20/tests/richole.c | 47 +++++++++
|
||||
2 files changed, 269 insertions(+)
|
||||
dlls/riched20/richole.c | 202 ++++++++++++++++++++++++++++++++++++++++++
|
||||
dlls/riched20/tests/richole.c | 47 ++++++++++
|
||||
2 files changed, 249 insertions(+)
|
||||
|
||||
diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c
|
||||
index 71fb311..f664616 100644
|
||||
index de70bc3..9605404 100644
|
||||
--- a/dlls/riched20/richole.c
|
||||
+++ b/dlls/riched20/richole.c
|
||||
@@ -2515,9 +2515,24 @@ static ULONG WINAPI TextPara_Release(ITextPara *iface)
|
||||
@@ -2668,6 +2668,16 @@ static ULONG WINAPI TextPara_Release(ITextPara *iface)
|
||||
return ref;
|
||||
}
|
||||
|
||||
@@ -29,54 +29,8 @@ index 71fb311..f664616 100644
|
||||
+
|
||||
static HRESULT WINAPI TextPara_GetTypeInfoCount(ITextPara *iface, UINT *pctinfo)
|
||||
{
|
||||
+ ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("stub\n");
|
||||
+
|
||||
+ if (!para_get_reole(This))
|
||||
+ return CO_E_RELEASED;
|
||||
+
|
||||
*pctinfo = 0;
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
@@ -2525,14 +2540,24 @@ static HRESULT WINAPI TextPara_GetTypeInfoCount(ITextPara *iface, UINT *pctinfo)
|
||||
static HRESULT WINAPI TextPara_GetTypeInfo(ITextPara *iface, UINT iTInfo, LCID lcid,
|
||||
ITypeInfo **ppTInfo)
|
||||
{
|
||||
+ ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("stub\n");
|
||||
+
|
||||
+ if (!para_get_reole(This))
|
||||
+ return CO_E_RELEASED;
|
||||
+
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI TextPara_GetIDsOfNames(ITextPara *iface, REFIID riid,
|
||||
LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
+ ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("stub\n");
|
||||
+
|
||||
+ if (!para_get_reole(This))
|
||||
+ return CO_E_RELEASED;
|
||||
+
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2547,7 +2572,12 @@ static HRESULT WINAPI TextPara_Invoke(
|
||||
EXCEPINFO *pExcepInfo,
|
||||
UINT *puArgErr)
|
||||
{
|
||||
+ ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("stub\n");
|
||||
+
|
||||
+ if (!para_get_reole(This))
|
||||
+ return CO_E_RELEASED;
|
||||
+
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2555,6 +2585,10 @@ static HRESULT WINAPI TextPara_GetDuplicate(ITextPara *iface, ITextPara **ret)
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
@@ -2734,6 +2744,10 @@ static HRESULT WINAPI TextPara_GetDuplicate(ITextPara *iface, ITextPara **ret)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, ret);
|
||||
@@ -87,7 +41,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2562,6 +2596,10 @@ static HRESULT WINAPI TextPara_SetDuplicate(ITextPara *iface, ITextPara *para)
|
||||
@@ -2741,6 +2755,10 @@ static HRESULT WINAPI TextPara_SetDuplicate(ITextPara *iface, ITextPara *para)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, para);
|
||||
@@ -98,7 +52,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2569,6 +2607,10 @@ static HRESULT WINAPI TextPara_CanChange(ITextPara *iface, LONG *ret)
|
||||
@@ -2748,6 +2766,10 @@ static HRESULT WINAPI TextPara_CanChange(ITextPara *iface, LONG *ret)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, ret);
|
||||
@@ -109,7 +63,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2576,6 +2618,10 @@ static HRESULT WINAPI TextPara_IsEqual(ITextPara *iface, ITextPara *para, LONG *
|
||||
@@ -2755,6 +2777,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);
|
||||
@@ -120,7 +74,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2583,6 +2629,10 @@ static HRESULT WINAPI TextPara_Reset(ITextPara *iface, LONG value)
|
||||
@@ -2762,6 +2788,10 @@ static HRESULT WINAPI TextPara_Reset(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -131,7 +85,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2590,6 +2640,10 @@ static HRESULT WINAPI TextPara_GetStyle(ITextPara *iface, LONG *value)
|
||||
@@ -2769,6 +2799,10 @@ static HRESULT WINAPI TextPara_GetStyle(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -142,7 +96,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2597,6 +2651,10 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value)
|
||||
@@ -2776,6 +2810,10 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -153,7 +107,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2604,6 +2662,10 @@ static HRESULT WINAPI TextPara_GetAlignment(ITextPara *iface, LONG *value)
|
||||
@@ -2783,6 +2821,10 @@ static HRESULT WINAPI TextPara_GetAlignment(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -164,7 +118,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2611,6 +2673,10 @@ static HRESULT WINAPI TextPara_SetAlignment(ITextPara *iface, LONG value)
|
||||
@@ -2790,6 +2832,10 @@ static HRESULT WINAPI TextPara_SetAlignment(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -175,7 +129,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2618,6 +2684,10 @@ static HRESULT WINAPI TextPara_GetHyphenation(ITextPara *iface, LONG *value)
|
||||
@@ -2797,6 +2843,10 @@ static HRESULT WINAPI TextPara_GetHyphenation(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -186,7 +140,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2625,6 +2695,10 @@ static HRESULT WINAPI TextPara_SetHyphenation(ITextPara *iface, LONG value)
|
||||
@@ -2804,6 +2854,10 @@ static HRESULT WINAPI TextPara_SetHyphenation(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -197,7 +151,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2632,6 +2706,10 @@ static HRESULT WINAPI TextPara_GetFirstLineIndent(ITextPara *iface, FLOAT *value
|
||||
@@ -2811,6 +2865,10 @@ static HRESULT WINAPI TextPara_GetFirstLineIndent(ITextPara *iface, FLOAT *value
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -208,7 +162,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2639,6 +2717,10 @@ static HRESULT WINAPI TextPara_GetKeepTogether(ITextPara *iface, LONG *value)
|
||||
@@ -2818,6 +2876,10 @@ static HRESULT WINAPI TextPara_GetKeepTogether(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -219,7 +173,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2646,6 +2728,10 @@ static HRESULT WINAPI TextPara_SetKeepTogether(ITextPara *iface, LONG value)
|
||||
@@ -2825,6 +2887,10 @@ static HRESULT WINAPI TextPara_SetKeepTogether(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -230,7 +184,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2653,6 +2739,10 @@ static HRESULT WINAPI TextPara_GetKeepWithNext(ITextPara *iface, LONG *value)
|
||||
@@ -2832,6 +2898,10 @@ static HRESULT WINAPI TextPara_GetKeepWithNext(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -241,7 +195,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2660,6 +2750,10 @@ static HRESULT WINAPI TextPara_SetKeepWithNext(ITextPara *iface, LONG value)
|
||||
@@ -2839,6 +2909,10 @@ static HRESULT WINAPI TextPara_SetKeepWithNext(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -252,7 +206,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2667,6 +2761,10 @@ static HRESULT WINAPI TextPara_GetLeftIndent(ITextPara *iface, FLOAT *value)
|
||||
@@ -2846,6 +2920,10 @@ static HRESULT WINAPI TextPara_GetLeftIndent(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -263,7 +217,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2674,6 +2772,10 @@ static HRESULT WINAPI TextPara_GetLineSpacing(ITextPara *iface, FLOAT *value)
|
||||
@@ -2853,6 +2931,10 @@ static HRESULT WINAPI TextPara_GetLineSpacing(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -274,7 +228,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2681,6 +2783,10 @@ static HRESULT WINAPI TextPara_GetLineSpacingRule(ITextPara *iface, LONG *value)
|
||||
@@ -2860,6 +2942,10 @@ static HRESULT WINAPI TextPara_GetLineSpacingRule(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -285,7 +239,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2688,6 +2794,10 @@ static HRESULT WINAPI TextPara_GetListAlignment(ITextPara *iface, LONG *value)
|
||||
@@ -2867,6 +2953,10 @@ static HRESULT WINAPI TextPara_GetListAlignment(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -296,7 +250,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2695,6 +2805,10 @@ static HRESULT WINAPI TextPara_SetListAlignment(ITextPara *iface, LONG value)
|
||||
@@ -2874,6 +2964,10 @@ static HRESULT WINAPI TextPara_SetListAlignment(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -307,7 +261,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2702,6 +2816,10 @@ static HRESULT WINAPI TextPara_GetListLevelIndex(ITextPara *iface, LONG *value)
|
||||
@@ -2881,6 +2975,10 @@ static HRESULT WINAPI TextPara_GetListLevelIndex(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -318,7 +272,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2709,6 +2827,10 @@ static HRESULT WINAPI TextPara_SetListLevelIndex(ITextPara *iface, LONG value)
|
||||
@@ -2888,6 +2986,10 @@ static HRESULT WINAPI TextPara_SetListLevelIndex(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -329,7 +283,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2716,6 +2838,10 @@ static HRESULT WINAPI TextPara_GetListStart(ITextPara *iface, LONG *value)
|
||||
@@ -2895,6 +2997,10 @@ static HRESULT WINAPI TextPara_GetListStart(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -340,7 +294,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2723,6 +2849,10 @@ static HRESULT WINAPI TextPara_SetListStart(ITextPara *iface, LONG value)
|
||||
@@ -2902,6 +3008,10 @@ static HRESULT WINAPI TextPara_SetListStart(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -351,7 +305,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2730,6 +2860,10 @@ static HRESULT WINAPI TextPara_GetListTab(ITextPara *iface, FLOAT *value)
|
||||
@@ -2909,6 +3019,10 @@ static HRESULT WINAPI TextPara_GetListTab(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -362,7 +316,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2737,6 +2871,10 @@ static HRESULT WINAPI TextPara_SetListTab(ITextPara *iface, FLOAT value)
|
||||
@@ -2916,6 +3030,10 @@ static HRESULT WINAPI TextPara_SetListTab(ITextPara *iface, FLOAT value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%.2f)\n", This, value);
|
||||
@@ -373,7 +327,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2744,6 +2882,10 @@ static HRESULT WINAPI TextPara_GetListType(ITextPara *iface, LONG *value)
|
||||
@@ -2923,6 +3041,10 @@ static HRESULT WINAPI TextPara_GetListType(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -384,7 +338,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2751,6 +2893,10 @@ static HRESULT WINAPI TextPara_SetListType(ITextPara *iface, LONG value)
|
||||
@@ -2930,6 +3052,10 @@ static HRESULT WINAPI TextPara_SetListType(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -395,7 +349,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2758,6 +2904,10 @@ static HRESULT WINAPI TextPara_GetNoLineNumber(ITextPara *iface, LONG *value)
|
||||
@@ -2937,6 +3063,10 @@ static HRESULT WINAPI TextPara_GetNoLineNumber(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -406,7 +360,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2765,6 +2915,10 @@ static HRESULT WINAPI TextPara_SetNoLineNumber(ITextPara *iface, LONG value)
|
||||
@@ -2944,6 +3074,10 @@ static HRESULT WINAPI TextPara_SetNoLineNumber(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -417,7 +371,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2772,6 +2926,10 @@ static HRESULT WINAPI TextPara_GetPageBreakBefore(ITextPara *iface, LONG *value)
|
||||
@@ -2951,6 +3085,10 @@ static HRESULT WINAPI TextPara_GetPageBreakBefore(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -428,7 +382,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2779,6 +2937,10 @@ static HRESULT WINAPI TextPara_SetPageBreakBefore(ITextPara *iface, LONG value)
|
||||
@@ -2958,6 +3096,10 @@ static HRESULT WINAPI TextPara_SetPageBreakBefore(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -439,7 +393,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2786,6 +2948,10 @@ static HRESULT WINAPI TextPara_GetRightIndent(ITextPara *iface, FLOAT *value)
|
||||
@@ -2965,6 +3107,10 @@ static HRESULT WINAPI TextPara_GetRightIndent(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -450,7 +404,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2793,6 +2959,10 @@ static HRESULT WINAPI TextPara_SetRightIndent(ITextPara *iface, FLOAT value)
|
||||
@@ -2972,6 +3118,10 @@ static HRESULT WINAPI TextPara_SetRightIndent(ITextPara *iface, FLOAT value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%.2f)\n", This, value);
|
||||
@@ -461,7 +415,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2800,6 +2970,10 @@ static HRESULT WINAPI TextPara_SetIndents(ITextPara *iface, FLOAT StartIndent, F
|
||||
@@ -2979,6 +3129,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);
|
||||
@@ -472,7 +426,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2807,6 +2981,10 @@ static HRESULT WINAPI TextPara_SetLineSpacing(ITextPara *iface, LONG LineSpacing
|
||||
@@ -2986,6 +3140,10 @@ static HRESULT WINAPI TextPara_SetLineSpacing(ITextPara *iface, LONG LineSpacing
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d %.2f)\n", This, LineSpacingRule, LineSpacing);
|
||||
@@ -483,7 +437,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2814,6 +2992,10 @@ static HRESULT WINAPI TextPara_GetSpaceAfter(ITextPara *iface, FLOAT *value)
|
||||
@@ -2993,6 +3151,10 @@ static HRESULT WINAPI TextPara_GetSpaceAfter(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -494,7 +448,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2821,6 +3003,10 @@ static HRESULT WINAPI TextPara_SetSpaceAfter(ITextPara *iface, FLOAT value)
|
||||
@@ -3000,6 +3162,10 @@ static HRESULT WINAPI TextPara_SetSpaceAfter(ITextPara *iface, FLOAT value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%.2f)\n", This, value);
|
||||
@@ -505,7 +459,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2828,6 +3014,10 @@ static HRESULT WINAPI TextPara_GetSpaceBefore(ITextPara *iface, FLOAT *value)
|
||||
@@ -3007,6 +3173,10 @@ static HRESULT WINAPI TextPara_GetSpaceBefore(ITextPara *iface, FLOAT *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -516,7 +470,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2835,6 +3025,10 @@ static HRESULT WINAPI TextPara_SetSpaceBefore(ITextPara *iface, FLOAT value)
|
||||
@@ -3014,6 +3184,10 @@ static HRESULT WINAPI TextPara_SetSpaceBefore(ITextPara *iface, FLOAT value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%.2f)\n", This, value);
|
||||
@@ -527,7 +481,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2842,6 +3036,10 @@ static HRESULT WINAPI TextPara_GetWidowControl(ITextPara *iface, LONG *value)
|
||||
@@ -3021,6 +3195,10 @@ static HRESULT WINAPI TextPara_GetWidowControl(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -538,7 +492,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2849,6 +3047,10 @@ static HRESULT WINAPI TextPara_SetWidowControl(ITextPara *iface, LONG value)
|
||||
@@ -3028,6 +3206,10 @@ static HRESULT WINAPI TextPara_SetWidowControl(ITextPara *iface, LONG value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%d)\n", This, value);
|
||||
@@ -549,7 +503,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2856,6 +3058,10 @@ static HRESULT WINAPI TextPara_GetTabCount(ITextPara *iface, LONG *value)
|
||||
@@ -3035,6 +3217,10 @@ static HRESULT WINAPI TextPara_GetTabCount(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%p)\n", This, value);
|
||||
@@ -560,7 +514,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2863,6 +3069,10 @@ static HRESULT WINAPI TextPara_AddTab(ITextPara *iface, FLOAT tbPos, LONG tbAlig
|
||||
@@ -3042,6 +3228,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);
|
||||
@@ -571,7 +525,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2870,6 +3080,10 @@ static HRESULT WINAPI TextPara_ClearAllTabs(ITextPara *iface)
|
||||
@@ -3049,6 +3239,10 @@ static HRESULT WINAPI TextPara_ClearAllTabs(ITextPara *iface)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)\n", This);
|
||||
@@ -582,7 +536,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2877,6 +3091,10 @@ static HRESULT WINAPI TextPara_DeleteTab(ITextPara *iface, FLOAT pos)
|
||||
@@ -3056,6 +3250,10 @@ static HRESULT WINAPI TextPara_DeleteTab(ITextPara *iface, FLOAT pos)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
FIXME("(%p)->(%.2f)\n", This, pos);
|
||||
@@ -593,7 +547,7 @@ index 71fb311..f664616 100644
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
@@ -2884,6 +3102,10 @@ static HRESULT WINAPI TextPara_GetTab(ITextPara *iface, LONG iTab, FLOAT *ptbPos
|
||||
@@ -3063,6 +3261,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);
|
||||
@@ -605,10 +559,10 @@ index 71fb311..f664616 100644
|
||||
}
|
||||
|
||||
diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c
|
||||
index 40577b3..065c86c 100644
|
||||
index 8b72a1d..ab94b58 100644
|
||||
--- a/dlls/riched20/tests/richole.c
|
||||
+++ b/dlls/riched20/tests/richole.c
|
||||
@@ -1637,6 +1637,52 @@ static void test_ITextSelection_GetFont(void)
|
||||
@@ -2256,6 +2256,52 @@ static void test_ITextSelection_GetFont(void)
|
||||
ITextFont_Release(txtFont);
|
||||
}
|
||||
|
||||
@@ -661,7 +615,7 @@ index 40577b3..065c86c 100644
|
||||
START_TEST(richole)
|
||||
{
|
||||
/* Must explicitly LoadLibrary(). The test has no references to functions in
|
||||
@@ -1661,6 +1707,7 @@ START_TEST(richole)
|
||||
@@ -2280,6 +2326,7 @@ START_TEST(richole)
|
||||
test_ITextRange_SetStart();
|
||||
test_ITextRange_SetEnd();
|
||||
test_ITextRange_GetFont();
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 9e71184f8215f3693f9b1418225dfbc2c7b57d77 Mon Sep 17 00:00:00 2001
|
||||
From 2a85e756deac893ec3b83a03c1fb4e0b85be829f Mon Sep 17 00:00:00 2001
|
||||
From: Jactry Zeng <wine@jactry.com>
|
||||
Date: Wed, 13 Aug 2014 14:57:52 +0800
|
||||
Subject: riched20: Fix ME_RunOfsFromCharOfs() when nCharOfs > strlen().
|
||||
|
@@ -1,19 +1,19 @@
|
||||
From 94fce2253318d11cb2cdc7681d639c795b816b27 Mon Sep 17 00:00:00 2001
|
||||
From 842d74c575aa057b5c093bc8570568bb88e6216b Mon Sep 17 00:00:00 2001
|
||||
From: Jactry Zeng <wine@jactry.com>
|
||||
Date: Wed, 13 Aug 2014 15:40:11 +0800
|
||||
Subject: riched20: Implement ITextRange::GetText.
|
||||
|
||||
---
|
||||
dlls/riched20/richole.c | 50 +++++++++++++++++++++++++------------------
|
||||
dlls/riched20/tests/richole.c | 38 ++++++++++++++++++++++++++++++++
|
||||
2 files changed, 67 insertions(+), 21 deletions(-)
|
||||
dlls/riched20/richole.c | 52 +++++++++++++++++++++++++------------------
|
||||
dlls/riched20/tests/richole.c | 52 +++++++++++++++++++++++++++++++------------
|
||||
2 files changed, 68 insertions(+), 36 deletions(-)
|
||||
|
||||
diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c
|
||||
index ee9f75c..3813c4f 100644
|
||||
index 9605404..da375e0 100644
|
||||
--- a/dlls/riched20/richole.c
|
||||
+++ b/dlls/riched20/richole.c
|
||||
@@ -1045,14 +1045,40 @@ static HRESULT WINAPI ITextRange_fnInvoke(ITextRange *me, DISPID dispIdMember, R
|
||||
return E_NOTIMPL;
|
||||
@@ -1145,11 +1145,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)
|
||||
@@ -44,10 +44,17 @@ index ee9f75c..3813c4f 100644
|
||||
{
|
||||
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;
|
||||
@@ -1157,8 +1182,9 @@ static HRESULT WINAPI ITextRange_fnGetText(ITextRange *me, BSTR *pbstr)
|
||||
if (!pbstr)
|
||||
return E_INVALIDARG;
|
||||
|
||||
- FIXME("not implemented %p\n", This);
|
||||
- *pbstr = NULL;
|
||||
- return E_NOTIMPL;
|
||||
+ ME_CursorFromCharOfs(This->reOle->editor, This->start, &start);
|
||||
+ ME_CursorFromCharOfs(This->reOle->editor, This->end, &end);
|
||||
@@ -55,7 +62,7 @@ index ee9f75c..3813c4f 100644
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ITextRange_fnSetText(ITextRange *me, BSTR bstr)
|
||||
@@ -3589,8 +3615,6 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr)
|
||||
@@ -3762,8 +3788,6 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr)
|
||||
{
|
||||
ITextSelectionImpl *This = impl_from_ITextSelection(me);
|
||||
ME_Cursor *start = NULL, *end = NULL;
|
||||
@@ -64,7 +71,7 @@ index ee9f75c..3813c4f 100644
|
||||
|
||||
TRACE("(%p)->(%p)\n", This, pbstr);
|
||||
|
||||
@@ -3601,23 +3625,7 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr)
|
||||
@@ -3774,23 +3798,7 @@ static HRESULT WINAPI ITextSelection_fnGetText(ITextSelection *me, BSTR *pbstr)
|
||||
return E_INVALIDARG;
|
||||
|
||||
ME_GetSelection(This->reOle->editor, &start, &end);
|
||||
@@ -90,10 +97,87 @@ index ee9f75c..3813c4f 100644
|
||||
|
||||
static HRESULT WINAPI ITextSelection_fnSetText(ITextSelection *me, BSTR bstr)
|
||||
diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c
|
||||
index 44e6051..583b195 100644
|
||||
index ab94b58..aaeb0c9 100644
|
||||
--- a/dlls/riched20/tests/richole.c
|
||||
+++ b/dlls/riched20/tests/richole.c
|
||||
@@ -1838,6 +1838,43 @@ static void test_ITextRange_GetPara(void)
|
||||
@@ -527,27 +527,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)
|
||||
@@ -560,37 +555,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);
|
||||
@@ -598,10 +586,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);
|
||||
@@ -2302,6 +2288,43 @@ static void test_ITextRange_GetPara(void)
|
||||
ITextPara_Release(txtPara);
|
||||
}
|
||||
|
||||
@@ -137,7 +221,7 @@ index 44e6051..583b195 100644
|
||||
START_TEST(richole)
|
||||
{
|
||||
/* Must explicitly LoadLibrary(). The test has no references to functions in
|
||||
@@ -1863,6 +1900,7 @@ START_TEST(richole)
|
||||
@@ -2327,6 +2350,7 @@ START_TEST(richole)
|
||||
test_ITextRange_SetEnd();
|
||||
test_ITextRange_GetFont();
|
||||
test_ITextRange_GetPara();
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 69ba6ab1953ff29538b3db3dcf87d02175c355ed Mon Sep 17 00:00:00 2001
|
||||
From ec06a4056cf8d7559020027563ce34e0158cda8a Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Sat, 1 Nov 2014 22:51:34 +0100
|
||||
Subject: riched20: Silence repeated FIXMEs triggered by Adobe Reader.
|
||||
@@ -9,10 +9,10 @@ Adobe Reader calls these functions very often while scrolling through a document
|
||||
1 file changed, 14 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c
|
||||
index 5d017e9..b5c2b9b 100644
|
||||
index 438de75..e722ef7 100644
|
||||
--- a/dlls/riched20/richole.c
|
||||
+++ b/dlls/riched20/richole.c
|
||||
@@ -394,6 +394,14 @@ static HRESULT WINAPI IRichEditOleImpl_inner_fnQueryInterface(IUnknown *iface, R
|
||||
@@ -495,6 +495,14 @@ static HRESULT WINAPI IRichEditOleImpl_inner_fnQueryInterface(IUnknown *iface, R
|
||||
IUnknown_AddRef((IUnknown *)*ppvObj);
|
||||
return S_OK;
|
||||
}
|
||||
@@ -27,7 +27,7 @@ index 5d017e9..b5c2b9b 100644
|
||||
FIXME("%p: unhandled interface %s\n", This, debugstr_guid(riid));
|
||||
|
||||
return E_NOINTERFACE;
|
||||
@@ -2434,7 +2442,9 @@ static HRESULT WINAPI TextFont_SetUnderline(ITextFont *iface, LONG value)
|
||||
@@ -2587,7 +2595,9 @@ static HRESULT WINAPI TextFont_SetUnderline(ITextFont *iface, LONG value)
|
||||
static HRESULT WINAPI TextFont_GetWeight(ITextFont *iface, LONG *value)
|
||||
{
|
||||
ITextFontImpl *This = impl_from_ITextFont(iface);
|
||||
@@ -36,9 +36,9 @@ index 5d017e9..b5c2b9b 100644
|
||||
+
|
||||
+ if (!once++) FIXME("(%p)->(%p): stub\n", This, value);
|
||||
|
||||
if (!font_get_reole(This))
|
||||
if (This->range && !get_range_reole(This->range))
|
||||
return CO_E_RELEASED;
|
||||
@@ -2726,7 +2736,9 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value)
|
||||
@@ -2885,7 +2895,9 @@ static HRESULT WINAPI TextPara_SetStyle(ITextPara *iface, LONG value)
|
||||
static HRESULT WINAPI TextPara_GetAlignment(ITextPara *iface, LONG *value)
|
||||
{
|
||||
ITextParaImpl *This = impl_from_ITextPara(iface);
|
||||
|
Reference in New Issue
Block a user