Mariusz Pluciński : gameux: IGameStatistics:: GetMaxValueLength implementation.

Alexandre Julliard julliard at winehq.org
Fri Sep 24 11:43:44 CDT 2010


Module: wine
Branch: master
Commit: 448ac80fd4e917daf2151e38165a4fe0288358b3
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=448ac80fd4e917daf2151e38165a4fe0288358b3

Author: Mariusz Pluciński <vshader at gmail.com>
Date:   Thu Sep 23 15:39:49 2010 +0200

gameux: IGameStatistics::GetMaxValueLength implementation.

---

 dlls/gameux/gamestatistics.c       |    9 +++++++--
 dlls/gameux/tests/gamestatistics.c |    4 ++--
 2 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/dlls/gameux/gamestatistics.c b/dlls/gameux/gamestatistics.c
index 905baf2..f0ee14c 100644
--- a/dlls/gameux/gamestatistics.c
+++ b/dlls/gameux/gamestatistics.c
@@ -33,6 +33,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(gameux);
 
 #define MAX_CATEGORY_LENGTH 60
 #define MAX_NAME_LENGTH 30
+#define MAX_VALUE_LENGTH 30
 /*******************************************************************************
  * IGameStatistics implementation
  */
@@ -134,8 +135,12 @@ static HRESULT WINAPI GameStatisticsImpl_GetMaxValueLength(
     IGameStatistics *iface,
     UINT *cch)
 {
-    FIXME("stub\n");
-    return E_NOTIMPL;
+    TRACE("(%p, %p)\n", iface, cch);
+    if(!cch)
+        return E_INVALIDARG;
+
+    *cch = MAX_VALUE_LENGTH;
+    return S_OK;
 }
 
 static HRESULT WINAPI GameStatisticsImpl_GetMaxCategories(
diff --git a/dlls/gameux/tests/gamestatistics.c b/dlls/gameux/tests/gamestatistics.c
index 3904bea..d494d22 100644
--- a/dlls/gameux/tests/gamestatistics.c
+++ b/dlls/gameux/tests/gamestatistics.c
@@ -252,8 +252,8 @@ static void test_gamestatisticsmgr( void )
         ok(uMaxNameLength==30, "getting maximum name length returned invalid value: %d\n", uMaxNameLength);
 
         hr = IGameStatistics_GetMaxValueLength(gs, &uMaxValueLength);
-        todo_wine ok(hr==S_OK, "getting maximum value length failed\n");
-        todo_wine ok(uMaxValueLength==30, "getting maximum value length returned invalid value: %d\n", uMaxValueLength);
+        ok(hr==S_OK, "getting maximum value length failed\n");
+        ok(uMaxValueLength==30, "getting maximum value length returned invalid value: %d\n", uMaxValueLength);
 
         hr = IGameStatistics_GetMaxCategories(gs, &wMaxCategories);
         todo_wine ok(hr==S_OK, "getting maximum number of categories failed\n");




More information about the wine-cvs mailing list