From mint-bounce@lists.fishpool.fi Thu Jan 20 16:39:40 2005 X-Original-To: fnaumann@mail.boerde.de Delivered-To: fnaumann@mail.boerde.de Mime-Version: 1.0 (Apple Message framework v619) Content-Transfer-Encoding: 7bit Message-Id: Content-Type: text/plain; charset=US-ASCII; format=flowed To: mint@lists.fishpool.fi From: =?ISO-8859-1?Q?Philipp_Donz=E9?= Subject: [MiNT] XaAES Bug in graf_mouse? Date: Thu, 20 Jan 2005 16:34:29 +0100 X-Mailer: Apple Mail (2.619) X-ecartis-version: Ecartis v1.0.0 Sender: mint-bounce@lists.fishpool.fi Errors-To: mint-bounce@lists.fishpool.fi X-original-sender: philipp.donze@epfl.ch Precedence: bulk List-help: List-unsubscribe: List-Id: X-List-ID: X-Virus-Scanned: by amavisd-new at relay.boerde.de X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on relay.boerde.de X-Spam-Status: No, hits=2.2 tagged_above=-50.5 required=3.8 tests=AWL, BAYES_99 X-Spam-Level: ** Hi, I'm having trouble with a small GEM application, which is based on a event-loop (see example code). After the evnt_multi() call I determine if it was a mouse button event and then check for the mouse state in second loop. Under MagiC 6.01 everything works nicely: I can press any combination of mouse buttons. After releasing the buttons the loop is quit. Under XaAES the application gets stuck in the loop when I press both buttons at the same time. => Releasing the buttons doesn't leave the loop. This happens under MiNT 1.16.x on Aranym (with latest XaAES from CVS) and on my Falcon under XaAES 0.992. Running MyAES over XaAES the problem doesn't appear. So it's probable that it's a bug in XaAES. Is it a (known) bug? Regards Philipp --------------------- example code ----------------------- #include #include int main (int argc, const char * argv[]) { short ap_id; GRECT s={100,100, 200, 200}; short handle; ap_id=appl_init(); handle = wind_create_grect(NAME|CLOSER, &s); wind_open_grect(handle, &s); int go_on = 1; do { short mx, my, mbutton, mclicks, kstate, key; short which; which = evnt_multi(MU_KEYBD|MU_BUTTON, 0x102, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, NULL , 0L, &mx, &my, &mbutton, &kstate, &key, &mclicks); if(which & MU_KEYBD) { // quit when a key was pressed go_on = 0; } if(which & MU_BUTTON) { while(mbutton) { graf_mkstate(&mx, &my, &mbutton, &kstate); printf("x:%d y:%d clicks:%d button:%d KSTATE:%d\n", mx, my, mclicks, mbutton, kstate); } } }while(go_on); wind_close(handle); wind_delete(handle); appl_exit(); return 0; }