Author: dreimer
Date: Sat May 16 21:00:03 2015
New Revision: 67788
URL:
http://svn.reactos.org/svn/reactos?rev=67788&view=rev
Log:
[MAZE*]
Loading from ini file works flawless, even on ROS, so... ENABLE it.
Modified:
trunk/rosapps/applications/screensavers/mazescr/maze.c
trunk/rosapps/demos/maze/maze.c
Modified: trunk/rosapps/applications/screensavers/mazescr/maze.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/screensavers/…
==============================================================================
--- trunk/rosapps/applications/screensavers/mazescr/maze.c [iso-8859-1] (original)
+++ trunk/rosapps/applications/screensavers/mazescr/maze.c [iso-8859-1] Sat May 16
21:00:03 2015
@@ -524,18 +524,10 @@
srand((unsigned) time(NULL));
-#if 0
- /* FIXME GetPrivateProfileInt not yet implemented in ReactOS */
- size = GetPrivateProfileInt("maze", "gridsize", 0,
"maze.ini");
- pre_solve_delay = GetPrivateProfileInt("maze", "predelay", 5000,
"maze.ini");
- post_solve_delay = GetPrivateProfileInt("maze", "postdelay",
5000, "maze.ini");
- solve_delay = GetPrivateProfileInt("maze", "solvedelay", 10,
"maze.ini");
-#else
- size = 10;
- pre_solve_delay = 5000;
- post_solve_delay = 5000;
- solve_delay = 1;
-#endif
+ size = GetPrivateProfileIntW(L"maze", L"gridsize", 10,
L"maze.ini");
+ pre_solve_delay = GetPrivateProfileIntW(L"maze", L"predelay",
5000, L"maze.ini");
+ post_solve_delay = GetPrivateProfileIntW(L"maze", L"postdelay",
5000, L"maze.ini");
+ solve_delay = GetPrivateProfileIntW(L"maze", L"solvedelay", 1,
L"maze.ini");
if (size < 2) {
size = 7 + (rand() % 30);
Modified: trunk/rosapps/demos/maze/maze.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/demos/maze/maze.c?rev=6778…
==============================================================================
--- trunk/rosapps/demos/maze/maze.c [iso-8859-1] (original)
+++ trunk/rosapps/demos/maze/maze.c [iso-8859-1] Sat May 16 21:00:03 2015
@@ -830,21 +830,10 @@
srand((unsigned) time(NULL));
-#if 0
- /* FIXME GetPrivateProfileInt not yet implemented in ReactOS */
- size = GetPrivateProfileInt("maze", "gridsize", 0,
"maze.ini");
- pre_solve_delay = GetPrivateProfileInt("maze", "predelay", 5000,
- "maze.ini");
- post_solve_delay = GetPrivateProfileInt("maze", "postdelay", 5000,
- "maze.ini");
- solve_delay = GetPrivateProfileInt("maze", "solvedelay", 10,
- "maze.ini");
-#else
- size = 10;
- pre_solve_delay = 5000;
- post_solve_delay = 5000;
- solve_delay = 20;
-#endif
+ size = GetPrivateProfileIntA("maze", "gridsize", 10,
"maze.ini");
+ pre_solve_delay = GetPrivateProfileIntA("maze", "predelay", 5000,
"maze.ini");
+ post_solve_delay = GetPrivateProfileIntA("maze", "postdelay", 5000,
"maze.ini");
+ solve_delay = GetPrivateProfileIntA("maze", "solvedelay", 1,
"maze.ini");
if (size < 2) {
size = 7 + (rand() % 30);