[PATCH 3/3] uiribbon: Add stubs for IUIFramework

Fabian Maurer dark.shadow4 at web.de
Thu Jul 27 13:53:39 CDT 2017


Signed-off-by: Fabian Maurer <dark.shadow4 at web.de>
---
 dlls/uiribbon/uiribbon.c | 76 +++++++++++++++++++++++++++++++++++++++++++++++-
 include/uiribbon.idl     | 47 +++++++++++++++++++++++++++++-
 2 files changed, 121 insertions(+), 2 deletions(-)

diff --git a/dlls/uiribbon/uiribbon.c b/dlls/uiribbon/uiribbon.c
index be84b54a65..9a9f1e4bd6 100644
--- a/dlls/uiribbon/uiribbon.c
+++ b/dlls/uiribbon/uiribbon.c
@@ -95,9 +95,83 @@ static ULONG WINAPI UIRibbonFrameworkImpl_Release(IUIFramework* iface)
     return ref;
 }
 
+/*** IUIFramework methods ***/
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_Initialize(IUIFramework* iface, HWND frameWnd, IUIApplication *application)
+{
+    FIXME("(%p, %p): stub!\n", frameWnd, application);
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_Destroy(IUIFramework* iface)
+{
+    FIXME("(): stub!\n");
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_LoadUI(IUIFramework* iface, HINSTANCE instance, LPCWSTR resourceName)
+{
+    FIXME("(%p, %s): stub!\n", instance, debugstr_w(resourceName));
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_GetView(IUIFramework* iface, UINT32 viewId, REFIID riid, void **ppv)
+{
+    FIXME("(%u, %p, %p): stub!\n", viewId, riid, ppv);
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_GetUICommandProperty(IUIFramework* iface, UINT32 commandId, REFPROPERTYKEY key, PROPVARIANT *value)
+{
+    FIXME("(%u, %p, %p): stub!\n", commandId, key, value);
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_SetUICommandProperty(IUIFramework* iface, UINT32 commandId, REFPROPERTYKEY key, PROPVARIANT value)
+{
+    FIXME("(%u, %p): stub!\n", commandId, key);
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_InvalidateUICommand(IUIFramework* iface, UINT32 commandId, UI_INVALIDATIONS flags, const PROPERTYKEY *key)
+{
+    FIXME("(%u, %#x, %p): stub!\n", commandId, flags, key);
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_FlushPendingInvalidations(IUIFramework* iface)
+{
+    FIXME("(): stub!\n");
+
+    return E_NOTIMPL;
+}
+
+static HRESULT WINAPI UIRibbonFrameworkImpl_SetModes(IUIFramework* iface, INT32 iModes)
+{
+    FIXME("(%d): stub!\n", iModes);
+
+    return E_NOTIMPL;
+}
+
 static const IUIFrameworkVtbl IUIFramework_Vtbl =
 {
     UIRibbonFrameworkImpl_QueryInterface,
     UIRibbonFrameworkImpl_AddRef,
-    UIRibbonFrameworkImpl_Release
+    UIRibbonFrameworkImpl_Release,
+    UIRibbonFrameworkImpl_Initialize,
+    UIRibbonFrameworkImpl_Destroy,
+    UIRibbonFrameworkImpl_LoadUI,
+    UIRibbonFrameworkImpl_GetView,
+    UIRibbonFrameworkImpl_GetUICommandProperty,
+    UIRibbonFrameworkImpl_SetUICommandProperty,
+    UIRibbonFrameworkImpl_InvalidateUICommand,
+    UIRibbonFrameworkImpl_FlushPendingInvalidations,
+    UIRibbonFrameworkImpl_SetModes
 };
diff --git a/include/uiribbon.idl b/include/uiribbon.idl
index 1ac464cb79..7f0c4f55fa 100644
--- a/include/uiribbon.idl
+++ b/include/uiribbon.idl
@@ -19,6 +19,17 @@
  */
 
 import "unknwn.idl";
+import "propsys.idl";
+
+/* Temporary define for the stubs */
+typedef void* IUIApplication;
+
+typedef enum UI_INVALIDATIONS {
+    UI_INVALIDATIONS_STATE         = 0x00000001,
+    UI_INVALIDATIONS_VALUE         = 0x00000002,
+    UI_INVALIDATIONS_PROPERTY      = 0x00000004,
+    UI_INVALIDATIONS_ALLPROPERTIES = 0x00000008,
+} UI_INVALIDATIONS;
 
 [
     object,
@@ -28,7 +39,41 @@ import "unknwn.idl";
 ]
 interface IUIFramework : IUnknown
 {
-
+    HRESULT Initialize(
+        [in] HWND frameWnd,
+        [in] IUIApplication *application
+    );
+    HRESULT Destroy(
+	);
+    HRESULT LoadUI(
+        [in] HINSTANCE instance,
+        [in] LPCWSTR resourceName
+    );
+    HRESULT GetView(
+        [in] UINT32 viewId,
+        [in] REFIID riid,
+        [out] void **ppv
+    );
+    HRESULT GetUICommandProperty(
+        [in] UINT32 commandId,
+        [in] REFPROPERTYKEY key,
+        [out] PROPVARIANT *value
+    );
+    HRESULT SetUICommandProperty(
+        [in] UINT32 commandId,
+        [in] REFPROPERTYKEY key,
+        [in] PROPVARIANT value
+    );
+    HRESULT InvalidateUICommand(
+        [in] UINT32 commandId,
+        [in] UI_INVALIDATIONS flags,
+        [in] const PROPERTYKEY *key
+    );
+    HRESULT FlushPendingInvalidations(
+	);
+    HRESULT SetModes(
+        INT32 iModes
+    );
 }
 
 [
-- 
2.13.3




More information about the wine-patches mailing list