Mariusz Pluciński : gameux: IGameStatistics:: GetMaxStatsPerCategory implementation.
Alexandre Julliard
julliard at winehq.org
Fri Sep 24 11:43:45 CDT 2010
Module: wine
Branch: master
Commit: 7cbcbf45770de0d7263a31e4c419e71f5fd35328
URL: http://source.winehq.org/git/wine.git/?a=commit;h=7cbcbf45770de0d7263a31e4c419e71f5fd35328
Author: Mariusz Pluciński <vshader at gmail.com>
Date: Thu Sep 23 15:40:04 2010 +0200
gameux: IGameStatistics::GetMaxStatsPerCategory implementation.
---
dlls/gameux/gamestatistics.c | 12 ++++++++++--
dlls/gameux/tests/gamestatistics.c | 4 ++--
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/dlls/gameux/gamestatistics.c b/dlls/gameux/gamestatistics.c
index c318eef..44cc04e 100644
--- a/dlls/gameux/gamestatistics.c
+++ b/dlls/gameux/gamestatistics.c
@@ -31,10 +31,14 @@
WINE_DEFAULT_DEBUG_CHANNEL(gameux);
+/*
+ * constant definitions
+ */
#define MAX_CATEGORY_LENGTH 60
#define MAX_NAME_LENGTH 30
#define MAX_VALUE_LENGTH 30
#define MAX_CATEGORIES 10
+#define MAX_STATS_PER_CATEGORY 10
/*******************************************************************************
* IGameStatistics implementation
*/
@@ -160,8 +164,12 @@ static HRESULT WINAPI GameStatisticsImpl_GetMaxStatsPerCategory(
IGameStatistics *iface,
WORD *pMax)
{
- FIXME("stub\n");
- return E_NOTIMPL;
+ TRACE("(%p, %p)\n", iface, pMax);
+ if(!pMax)
+ return E_INVALIDARG;
+
+ *pMax = MAX_STATS_PER_CATEGORY;
+ return S_OK;
}
static HRESULT WINAPI GameStatisticsImpl_SetCategoryTitle(
diff --git a/dlls/gameux/tests/gamestatistics.c b/dlls/gameux/tests/gamestatistics.c
index e485f9f..30e1fcd 100644
--- a/dlls/gameux/tests/gamestatistics.c
+++ b/dlls/gameux/tests/gamestatistics.c
@@ -260,8 +260,8 @@ static void test_gamestatisticsmgr( void )
ok(wMaxCategories==10, "getting maximum number of categories returned invalid value: %d\n", wMaxCategories);
hr = IGameStatistics_GetMaxStatsPerCategory(gs, &wMaxStatsPerCategory);
- todo_wine ok(hr==S_OK, "getting maximum number of statistics per category failed\n");
- todo_wine ok(wMaxStatsPerCategory==10, "getting maximum number of statistics per category returned invalid value: %d\n", wMaxStatsPerCategory);
+ ok(hr==S_OK, "getting maximum number of statistics per category failed\n");
+ ok(wMaxStatsPerCategory==10, "getting maximum number of statistics per category returned invalid value: %d\n", wMaxStatsPerCategory);
/* create name of statistics file */
hr = _buildStatisticsFilePath(&guidApplicationId, &lpStatisticsFile);
More information about the wine-cvs
mailing list