brop monitor seg violations fixed (for now)

From: Kris Hagel (hagel@comp.tamu.edu)
Date: Thu Nov 14 2002 - 17:21:22 EST

  • Next message: Flemming Videbaek: "Re: brop monitor seg violations fixed (for now)"
    Hello,
    My thanks to Christian for the magic command for running a program in 
    gdb with argument.  I had spent some time looking for the "trick" and 
    did not find one and had (begin VMS unrant) finally concluded  that unix 
    debugging was simply not up the high VMS standards of yesteryear.  But 
    alas I learned from Christian that if I go through the proper cryptic 
    commands in the proper cryptic order that I can do NEARLY as much as I 
    could in VMS.  Of course in VMS I didn't have to do cryptic stuff; just 
    debugging and I didn't even have to ask Christian how to do things which 
    is good because he was probably about knee-high to a jackrabbit when I 
    was doing this advanced VMS debugging (end VMS unrant).  
    
    Anyway this enabled me to find out where I was getting the seg violation 
    when I did the popup canvas I described yesterday.  So for those of you 
    who are interested, here is a condensed version of the story.  In order 
    to decide if I had a double click in the pad, I have a simple helper 
    class which is appended to the pad.  Every time the mouse passes over 
    the pad, the DistanceToPrimitive method of this helper class is called 
    and I can detect in there if I have a single or double click.  I was 
    calling directly from there the routine to pop up the new canvas, but 
    this generated its own X11 event which caused the DistanceToPrimitive 
    method of THistPainter to get called when things were not all the way 
    set up yet.  So what I needed to do was to set a flag instead of direcly 
    call the method and have it inherit from TTimer and do the call finally 
    when the system was going through the loops in the DispatchOneEvent 
    method of TSystem.  The important point is to let the canvas go over its 
    entire loop of fListOfPrimitives before calling something that will 
    modify that.
    
    The modification is checked into the repository and should be ready for 
    big time.
    
    Kris
    


    This archive was generated by hypermail 2.1.5 : Thu Nov 14 2002 - 17:40:58 EST