Commit b28aff5e1af6871169c0ba49bcf9952e8bee8d5b
1 parent
61c9a762
v1.19.1.0
Showing
3 changed files
with
8 additions
and
24 deletions
Show diff stats
Vrh.Log4Pro.MaintenanceConsole/ConsoleFunction - ColorConsole.cs
@@ -153,12 +153,11 @@ namespace Vrh.Log4Pro.MaintenanceConsole.ColorConsoleNS | @@ -153,12 +153,11 @@ namespace Vrh.Log4Pro.MaintenanceConsole.ColorConsoleNS | ||
153 | } | 153 | } |
154 | else | 154 | else |
155 | { | 155 | { |
156 | - if (validitylist != null && validitylist.Any()) { prompt += $" Valid values are {'\''+string.Join("','", validitylist)+'\''}."; } | ||
157 | - if (defaultvalue != null) { prompt += $" Default value is '{defaultvalue}'."; } | ||
158 | - if (exitvalue != null) { prompt += $" Enter '{exitvalue}' to exit."; } | 156 | + if (validitylist != null && validitylist.Any()) { prompt += $"Valid values: {'\''+string.Join("','", validitylist)+'\''}. "; } |
157 | + if (defaultvalue != null) { prompt += $"Default value: '{defaultvalue}'. "; } | ||
158 | + if (exitvalue != null) { prompt += $"Enter '{exitvalue}' to exit. "; } | ||
159 | 159 | ||
160 | - Write(text, f, b, bracket, prefix, suffix); | ||
161 | - if (!string.IsNullOrWhiteSpace(text+bracket+prefix+suffix)) WriteLine(); | 160 | + Write(text, f, b, bracket, prefix, suffix); if (!string.IsNullOrWhiteSpace(text+bracket+prefix+suffix)) WriteLine(); |
162 | if (prompt != null) { WriteLine(prompt); } | 161 | if (prompt != null) { WriteLine(prompt); } |
163 | Write("-->"); input = Console.ReadLine(); | 162 | Write("-->"); input = Console.ReadLine(); |
164 | if (defaultvalue!=null && (input == null || input == "")) { input = defaultvalue; } | 163 | if (defaultvalue!=null && (input == null || input == "")) { input = defaultvalue; } |
Vrh.Log4Pro.MaintenanceConsole/ConsoleFunction - Menu.cs
@@ -348,31 +348,16 @@ namespace Vrh.Log4Pro.MaintenanceConsole.MenuNS | @@ -348,31 +348,16 @@ namespace Vrh.Log4Pro.MaintenanceConsole.MenuNS | ||
348 | } | 348 | } |
349 | else | 349 | else |
350 | { | 350 | { |
351 | - ColorConsole.Write(SelectionPrompt, ConsoleColor.Yellow); | ||
352 | - ColorConsole.Write(" --> ", ConsoleColor.White); | ||
353 | - var remembercursorleft = ColorConsole.CursorLeft; | ||
354 | - var remembercursortop = ColorConsole.CursorTop; | 351 | + ColorConsole.WriteLine(SelectionPrompt, ConsoleColor.Yellow); |
355 | if (NumOfMenuItems==0) | 352 | if (NumOfMenuItems==0) |
356 | { | 353 | { |
357 | - ColorConsole.WriteLine(); | ||
358 | ColorConsole.WriteLine("No items in menu!"); | 354 | ColorConsole.WriteLine("No items in menu!"); |
359 | selectionliststr = "EX"; | 355 | selectionliststr = "EX"; |
360 | } | 356 | } |
361 | else | 357 | else |
362 | { | 358 | { |
363 | - if (selectionMode == SelectionMode.Multi) | ||
364 | - { | ||
365 | - ColorConsole.WriteLine(); | ||
366 | - ColorConsole.WriteLine("Multiple selections are separated with comma(,), enter asterisk(*) to select all!"); | ||
367 | - } | ||
368 | - var remembercursorleft2 = ColorConsole.CursorLeft; | ||
369 | - var remembercursortop2 = ColorConsole.CursorTop; | ||
370 | - ColorConsole.SetCursorPosition(remembercursorleft, remembercursortop); | 359 | + if (selectionMode == SelectionMode.Multi) { ColorConsole.WriteLine("Multiple selections are separated with comma(,), enter asterisk(*) to select all!"); } |
371 | selectionliststr = ColorConsole.ReadLine().ToUpper(); | 360 | selectionliststr = ColorConsole.ReadLine().ToUpper(); |
372 | - if (selectionMode == SelectionMode.Multi) | ||
373 | - { | ||
374 | - ColorConsole.SetCursorPosition(remembercursorleft2, remembercursortop2); | ||
375 | - } | ||
376 | } | 361 | } |
377 | } | 362 | } |
378 | if (selectionliststr == "EX") | 363 | if (selectionliststr == "EX") |
Vrh.Log4Pro.MaintenanceConsole/Properties/AssemblyInfo.cs
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices; | @@ -32,5 +32,5 @@ using System.Runtime.InteropServices; | ||
32 | // You can specify all the values or you can default the Build and Revision Numbers | 32 | // You can specify all the values or you can default the Build and Revision Numbers |
33 | // by using the '*' as shown below: | 33 | // by using the '*' as shown below: |
34 | // [assembly: AssemblyVersion("1.0.*")] | 34 | // [assembly: AssemblyVersion("1.0.*")] |
35 | -[assembly: AssemblyVersion("1.19.0.0")] | ||
36 | -[assembly: AssemblyFileVersion("1.19.0.0")] | 35 | +[assembly: AssemblyVersion("1.19.1.0")] |
36 | +[assembly: AssemblyFileVersion("1.19.1.0")] |