Commit 7cbcbf45 authored by Mariusz Pluciński's avatar Mariusz Pluciński Committed by Alexandre Julliard

gameux: IGameStatistics::GetMaxStatsPerCategory implementation.

parent 6dfb5f6a
...@@ -31,10 +31,14 @@ ...@@ -31,10 +31,14 @@
WINE_DEFAULT_DEBUG_CHANNEL(gameux); WINE_DEFAULT_DEBUG_CHANNEL(gameux);
/*
* constant definitions
*/
#define MAX_CATEGORY_LENGTH 60 #define MAX_CATEGORY_LENGTH 60
#define MAX_NAME_LENGTH 30 #define MAX_NAME_LENGTH 30
#define MAX_VALUE_LENGTH 30 #define MAX_VALUE_LENGTH 30
#define MAX_CATEGORIES 10 #define MAX_CATEGORIES 10
#define MAX_STATS_PER_CATEGORY 10
/******************************************************************************* /*******************************************************************************
* IGameStatistics implementation * IGameStatistics implementation
*/ */
...@@ -160,8 +164,12 @@ static HRESULT WINAPI GameStatisticsImpl_GetMaxStatsPerCategory( ...@@ -160,8 +164,12 @@ static HRESULT WINAPI GameStatisticsImpl_GetMaxStatsPerCategory(
IGameStatistics *iface, IGameStatistics *iface,
WORD *pMax) WORD *pMax)
{ {
FIXME("stub\n"); TRACE("(%p, %p)\n", iface, pMax);
return E_NOTIMPL; if(!pMax)
return E_INVALIDARG;
*pMax = MAX_STATS_PER_CATEGORY;
return S_OK;
} }
static HRESULT WINAPI GameStatisticsImpl_SetCategoryTitle( static HRESULT WINAPI GameStatisticsImpl_SetCategoryTitle(
......
...@@ -260,8 +260,8 @@ static void test_gamestatisticsmgr( void ) ...@@ -260,8 +260,8 @@ static void test_gamestatisticsmgr( void )
ok(wMaxCategories==10, "getting maximum number of categories returned invalid value: %d\n", wMaxCategories); ok(wMaxCategories==10, "getting maximum number of categories returned invalid value: %d\n", wMaxCategories);
hr = IGameStatistics_GetMaxStatsPerCategory(gs, &wMaxStatsPerCategory); hr = IGameStatistics_GetMaxStatsPerCategory(gs, &wMaxStatsPerCategory);
todo_wine ok(hr==S_OK, "getting maximum number of statistics per category failed\n"); 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(wMaxStatsPerCategory==10, "getting maximum number of statistics per category returned invalid value: %d\n", wMaxStatsPerCategory);
/* create name of statistics file */ /* create name of statistics file */
hr = _buildStatisticsFilePath(&guidApplicationId, &lpStatisticsFile); hr = _buildStatisticsFilePath(&guidApplicationId, &lpStatisticsFile);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment