- Display memory usage in the installer as Kernel Cache and Kernel Pool, instead...
authorAleksey Bragin <aleksey@reactos.org>
Wed, 18 Feb 2009 16:35:14 +0000 (16:35 +0000)
committerAleksey Bragin <aleksey@reactos.org>
Wed, 18 Feb 2009 16:35:14 +0000 (16:35 +0000)
- Remove 40% memory delay hack.
- Patch by Alex Ionescu.

svn path=/trunk/; revision=39662

reactos/base/setup/usetup/interface/usetup.c

index 36281e3..c8ac1be 100644 (file)
@@ -3053,18 +3053,9 @@ SetupUpdateMemoryInfo(IN PCOPYCONTEXT CopyContext,
     }
 
     /* Set current values */
-    ProgressSetStep(CopyContext->MemoryBars[0], PerfInfo.PagedPoolPages);
-    ProgressSetStep(CopyContext->MemoryBars[1], PerfInfo.NonPagedPoolPages);
+    ProgressSetStep(CopyContext->MemoryBars[0], PerfInfo.PagedPoolPages + PerfInfo.NonPagedPoolPages);
+    ProgressSetStep(CopyContext->MemoryBars[1], PerfInfo.ResidentSystemCachePage);
     ProgressSetStep(CopyContext->MemoryBars[2], PerfInfo.AvailablePages);
-
-    /* Check if memory dropped below 40%! */
-    if (CopyContext->MemoryBars[2]->Percent <= 40)
-    {
-        /* Wait a while until Mm does its thing */
-        LARGE_INTEGER Interval;
-        Interval.QuadPart = -1 * 15 * 1000 * 100;
-        NtDelayExecution(FALSE, &Interval);
-    }
 }
 
 static UINT CALLBACK
@@ -3138,7 +3129,7 @@ FileCopyPage(PINPUT_RECORD Ir)
                                                  13,
                                                   44,
                                                   FALSE,
-                                                  "Paged Memory");
+                                                  "Kernel Pool");
 
     /* Create the non paged pool progress bar */
     CopyContext.MemoryBars[1] = CreateProgressBar((xScreen / 2)- (mem_bar_width / 2),
@@ -3148,7 +3139,7 @@ FileCopyPage(PINPUT_RECORD Ir)
                                                   (xScreen / 2)- (mem_bar_width / 2),
                                                   44,
                                                   FALSE,
-                                                  "Nonpaged Memory");
+                                                  "Kernel Cache");
 
     /* Create the global memory progress bar */
     CopyContext.MemoryBars[2] = CreateProgressBar(xScreen - 13 - mem_bar_width,