nanogui: getting to grips with Nano-X
Subject:
Re: getting to grips with Nano-X
From:
####@####.#### (Erwin Rol)
Date:
15 Jun 2000 14:21:01 -0000
Message-Id: <3948E7AE.ECD94A@q-soft-engineering.com>
Hmm i dunno , but sleeping in event handlers
doesn't seem like a good idea to me.
I assume it basically works the same as on
X11 or MS-Windows where messages are handled
sequential, meaning if you sleep in the handler no
other messages are handled , hence the GUI freezes.
- Erwin
Simon Wood wrote:
>
> The missing code snippet is:
> static void
> handleevent(GR_EVENT *ep)
> {
> if (ep->type == GR_EVENT_TYPE_BUTTON_DOWN) {
> fprintf(stderr, "ouch...");
> GrSetGCForeground(gc1, BLUE);
> GrFillRect(w1, gc1, 10, 10, 40, 40);
>
> #if 1
> sleep(10);
> GrSetGCForeground(gc1, RED);
> GrFillRect(w1, gc1, 10, 10, 40, 40);
> #endif
>
> fprintf(stderr, "!!!");
> }
> }
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####
--
Q - S O F T - E N G I N E E R I N G
Rodachtalweg 11, 81549 Muenchen, Germany
Erwin Rol (Software Engineer) phone: +49-89-68050051
####@####.#### fax : +49-89-68050052