Show
Ignore:
Timestamp:
11/01/09 12:05:07 (3 years ago)
Author:
Erwan Velu <erwan.velu@…>
Children:
079f92a31281573b8a7b152b1730e7a349ac6365
Parents:
a7f6dd2b9fc3f8ad29a05135c99288156961329b
git-author:
Pierre-Alexandre Meyer <pierre@mouraf.org> / 2009-10-31T22:32:26Z-0700
git-committer:
Erwan Velu <erwan.velu@free.fr> / 2009-11-01T13:05:07Z+0100
Message:

hdt: change remaining printf to more_printf (CLI)

A lot of places still had printf() instead of more_printf().
This patch does a bulk update and add missing reset_more_printf(),
used to reset the pager counter between each command call.

This also changes the more_printf() routine to delete the "--More--"
line while scrolling.

Signed-off-by: Pierre-Alexandre Meyer <pierre@…>

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • com32/hdt/hdt-cli-vesa.c

    ra9d9ad rdff898  
    3737                    struct s_hardware *hardware) 
    3838{ 
     39    reset_more_printf(); 
    3940        detect_vesa(hardware); 
    4041        if (hardware->is_vesa_valid == false) { 
    41                 printf("No VESA BIOS detected\n"); 
     42                more_printf("No VESA BIOS detected\n"); 
    4243                return; 
    4344        } 
    44         printf("VESA\n"); 
    45         printf(" Vesa version : %d.%d\n", hardware->vesa.major_version, 
     45        more_printf("VESA\n"); 
     46        more_printf(" Vesa version : %d.%d\n", hardware->vesa.major_version, 
    4647                    hardware->vesa.minor_version); 
    47         printf(" Vendor       : %s\n", hardware->vesa.vendor); 
    48         printf(" Product      : %s\n", hardware->vesa.product); 
    49         printf(" Product rev. : %s\n", hardware->vesa.product_revision); 
    50         printf(" Software rev.: %d\n", hardware->vesa.software_rev); 
    51         printf(" Memory (KB)  : %d\n", hardware->vesa.total_memory * 64); 
    52         printf(" Modes        : %d\n", hardware->vesa.vmi_count); 
     48        more_printf(" Vendor       : %s\n", hardware->vesa.vendor); 
     49        more_printf(" Product      : %s\n", hardware->vesa.product); 
     50        more_printf(" Product rev. : %s\n", hardware->vesa.product_revision); 
     51        more_printf(" Software rev.: %d\n", hardware->vesa.software_rev); 
     52        more_printf(" Memory (KB)  : %d\n", hardware->vesa.total_memory * 64); 
     53        more_printf(" Modes        : %d\n", hardware->vesa.vmi_count); 
    5354} 
    5455 
     
    5758{ 
    5859        detect_vesa(hardware); 
     60        reset_more_printf(); 
    5961        if (hardware->is_vesa_valid == false) { 
    60                 printf("No VESA BIOS detected\n"); 
     62                more_printf("No VESA BIOS detected\n"); 
    6163                return; 
    6264        } 
    63         reset_more_printf(); 
    64         printf(" ResH. x ResV x Bits : vga= : Vesa Mode\n"); 
    65         printf("----------------------------------------\n"); 
     65        more_printf(" ResH. x ResV x Bits : vga= : Vesa Mode\n"); 
     66        more_printf("----------------------------------------\n"); 
    6667 
    6768        for (int i = 0; i < hardware->vesa.vmi_count; i++) { 
     
    7273                 */ 
    7374                if ((mi->h_res == 0) || (mi->v_res == 0)) continue; 
    74                 printf("%5u %5u    %3u     %3d     0x%04x\n", 
     75                more_printf("%5u %5u    %3u     %3d     0x%04x\n", 
    7576                            mi->h_res, mi->v_res, mi->bpp, 
    7677                            hardware->vesa.vmi[i].mode + 0x200,