[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference bulova::decw_jan-89_to_nov-90

Title:DECWINDOWS 26-JAN-89 to 29-NOV-90
Notice:See 1639.0 for VMS V5.3 kit; 2043.0 for 5.4 IFT kit
Moderator:STAR::VATNE
Created:Mon Oct 30 1989
Last Modified:Mon Dec 31 1990
Last Successful Update:Fri Jun 06 1997
Number of topics:3726
Total number of notes:19516

3452.0. "Opening the same display twice" by TLE::MANNIX (Frank Mannix) Wed Oct 10 1990 15:27

    
    Is it legal to open the same display twice in the same application?
    
    If it is legal, is it also legal to have both displays in the
    same application context?
    
    Frank
T.RTitleUserPersonal
Name
DateLines
3452.1legal but...STKMKT::SWEENEYPatrick Sweeney in New YorkWed Oct 10 1990 15:5518
    Opening multiple display connections to the same host, server, and
    screen: It's legal but not a good idea.
    
    If the application is toolkit-based, then main loop will dispatch on
    events to each display connection.  There's no reason to do this in
    preference to one display connection.
    
    If the application is not toolkit-based, then the application assumes
    responsibility for read the input queue from each display connection.
    
    I've seen bizzare application behavior where the application doesn't
    read each input event queue in a timely manner, ie the mouse "works" in
    one window but not the other.  Keyboard input is ignored until a button
    is pushed, and then the previously entered keystrokes are processed...
    
    The programmer thought that this would create "priority" for some
    windows in the application.  I had to educate him that the user
    probably expects his input to be processed in the order it was entered.
3452.2OXNARD::KLEEKen LeeWed Oct 10 1990 18:027
    Two connections to the same display is one technique for handling
    UNIX-style signals (interrupts).  One display is used for normal
    requests, the other is used within signal handlers.  As mentioned in .1,
    you do have to be very careful to properly  process events and errors
    on both connections.
    
    Ken