qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v4] ui/cocoa.m: Adds console items to the View m


From: Programmingkid
Subject: Re: [Qemu-devel] [PATCH v4] ui/cocoa.m: Adds console items to the View menu
Date: Mon, 11 May 2015 10:29:11 -0400

On May 11, 2015, at 9:20 AM, Peter Maydell wrote:

> On 11 May 2015 at 01:32, Programmingkid <address@hidden> wrote:
>> This patch adds the VGA, Monitor, Serial, and Parallel menu item to the view
>> menu.
>> 
>> Signed-off-by: John Arbuckle <address@hidden>
> 
>> +    // set the console variables for the consoles we have
>> +    while(qemu_console_lookup_by_index(index) != NULL) {
>> +        console_name =
>> qemu_console_get_label(qemu_console_lookup_by_index(index));
>> +        if(strstr(console_name, "VGA") != NULL) {
>> +            graphics_console = index;
>> +        } else if (strstr(console_name, "monitor") != NULL) {
>> +            monitor_console = index;
>> +        } else if (strstr(console_name, "serial") != NULL) {
>> +            serial_console = index;
>> +        } else if (strstr(console_name, "parallel") != NULL) {
>> +            parallel_console = index;
>> +        } else {
>> +            printf("Error in initConsoleVariables(): given value %s\n",
>> console_name);
> 
> Can't we just create a menu with an item for every console,
> and set its menu text to the result of qemu_console_get_label() ?
> I don't see why we need to special case these four and only
> display those.
> 
> thanks
> -- PMM

We *could* do it that way, but it wouldn't look pretty. Instead of having these 
menu items:

VGA, Monitor, Serial, Parallel

We would have these menu items:

VGA
compat_monitor0
serial0
parallel0

They look very anti-pretty.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]