[gcompris] core: fixed the command line option --difficulty which was not working.
- From: Bruno Coudoin <bcoudoin src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gcompris] core: fixed the command line option --difficulty which was not working.
- Date: Fri, 4 May 2012 22:43:15 +0000 (UTC)
commit 5dc62bc2f332cc06f6fb2028074f5a3025548d9a
Author: Bruno Coudoin <bruno coudoin free fr>
Date: Fri May 4 13:04:56 2012 +0200
core: fixed the command line option --difficulty which was not working.
It was broken for many years probably.
src/gcompris/menu.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/gcompris/menu.c b/src/gcompris/menu.c
index be393c1..77cfbcd 100644
--- a/src/gcompris/menu.c
+++ b/src/gcompris/menu.c
@@ -444,6 +444,11 @@ GList *gc_menu_getlist(gchar *section)
}
else
{
+ if ( (properties->difficulty_filter > 0) &&
+ (properties->filter_style == GCOMPRIS_FILTER_EQUAL) &&
+ (atoi(board->difficulty) != properties->difficulty_filter) )
+ continue;
+
result_list = g_list_append(result_list, board);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]