From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56010) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aaaPs-0007Gq-Rg for qemu-devel@nongnu.org; Mon, 29 Feb 2016 21:52:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aaaPo-0004z0-RD for qemu-devel@nongnu.org; Mon, 29 Feb 2016 21:52:04 -0500 Received: from mx1.redhat.com ([209.132.183.28]:37853) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aaaPo-0004yw-LZ for qemu-devel@nongnu.org; Mon, 29 Feb 2016 21:52:00 -0500 Date: Tue, 1 Mar 2016 10:51:54 +0800 From: Fam Zheng Message-ID: <20160301025154.GH15213@ad.usersys.redhat.com> References: <20160301015925.GF15213@ad.usersys.redhat.com> <54BE62FA-5E47-4E08-82BC-2021064FE29B@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <54BE62FA-5E47-4E08-82BC-2021064FE29B@gmail.com> Subject: Re: [Qemu-devel] How to make changes to qapi-types.h List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Programmingkid Cc: qemu-devel qemu-devel On Mon, 02/29 21:38, Programmingkid wrote: > > On Feb 29, 2016, at 8:59 PM, Fam Zheng wrote: > > > On Mon, 02/29 20:26, Programmingkid wrote: > >> I need to add a variable to the QKeyCode enum in the file qapi-types.h. This > >> file is auto-generated so using traditional means to create a patch is not > >> possible. Would anyone know how I can add to this file? > > > > The file to look at is qapi-schema.json. The generator is also documented in > > docs/qapi-code-gen.txt. > > Thank you very much for your help, but the information in the files you sent > did not seem to help. Maybe I should say exactly what I'm trying to do. > > In the file qapi-types.h, there is an enum called QKeyCode. I want to add > this to the enum: > > Q_KEY_CODE_KP_EQUALS = 125, > > Would anyone know how to do this so I can submit this change as a patch? You missed what I was trying to point out. diff --git a/qapi-schema.json b/qapi-schema.json index 7b8f2a1..ad50b06 100644 --- a/qapi-schema.json +++ b/qapi-schema.json @@ -3096,7 +3096,7 @@ 'left', 'up', 'down', 'right', 'insert', 'delete', 'stop', 'again', 'props', 'undo', 'front', 'copy', 'open', 'paste', 'find', 'cut', 'lf', 'help', 'meta_l', 'meta_r', 'compose', 'pause', 'ro', - 'kp_comma' ] } + 'kp_comma', 'kp_equals' ] } ## # @KeyValue