[PATCH v2 5/5] qedit: Implement IAMTimelineObj_GetTimelineNoRef and add tests.

Andrew Eikum aeikum at codeweavers.com
Wed Apr 27 08:51:07 CDT 2016


Signed-off-by: Andrew Eikum <aeikum at codeweavers.com>

On Tue, Apr 26, 2016 at 11:12:50PM -0600, Alex Henrie wrote:
> Cc: Andrew Eikum <aeikum at codeweavers.com>
> 
> Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
> ---
>  dlls/qedit/tests/timeline.c | 8 ++++++++
>  dlls/qedit/timeline.c       | 7 +++++--
>  2 files changed, 13 insertions(+), 2 deletions(-)
> 
> diff --git a/dlls/qedit/tests/timeline.c b/dlls/qedit/tests/timeline.c
> index ca00063..2d37010 100644
> --- a/dlls/qedit/tests/timeline.c
> +++ b/dlls/qedit/tests/timeline.c
> @@ -91,6 +91,14 @@ static void test_timeline(void)
>          else
>              ok(hr == E_INVALIDARG, "Expected E_INVALIDARG got %08x\n", hr);
>      }
> +
> +    hr = IAMTimelineObj_GetTimelineNoRef(obj, NULL);
> +    ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
> +
> +    timeline2 = (IAMTimeline *)0xdeadbeef;
> +    hr = IAMTimelineObj_GetTimelineNoRef(obj, &timeline2);
> +    ok(hr == E_NOINTERFACE, "Expected E_NOINTERFACE got %08x\n", hr);
> +    ok(!timeline2, "Expected NULL got %p\n", timeline2);
>  }
>  
>  START_TEST(timeline)
> diff --git a/dlls/qedit/timeline.c b/dlls/qedit/timeline.c
> index a2552d2..8c6ac5b 100644
> --- a/dlls/qedit/timeline.c
> +++ b/dlls/qedit/timeline.c
> @@ -737,9 +737,12 @@ static HRESULT WINAPI TimelineObj_RemoveAll(IAMTimelineObj *iface)
>  
>  static HRESULT WINAPI TimelineObj_GetTimelineNoRef(IAMTimelineObj *iface, IAMTimeline **timeline)
>  {
> +    /* MSDN says that this function is "not supported" */
>      TimelineObjImpl *This = impl_from_IAMTimelineObj(iface);
> -    FIXME("(%p)->(%p): not implemented!\n", This, timeline);
> -    return E_NOTIMPL;
> +    TRACE("(%p)->(%p)\n", This, timeline);
> +    if (!timeline) return E_POINTER;
> +    *timeline = NULL;
> +    return E_NOINTERFACE;
>  }
>  
>  static HRESULT WINAPI TimelineObj_GetGroupIBelongTo(IAMTimelineObj *iface, IAMTimelineGroup **group)
> -- 
> 2.8.0
> 



More information about the wine-patches mailing list