Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

First, some housecleaning. Mike Hanson pointed out that I needed a couple of additional lines of code (5 and 6) in my TakeAccepted handler:

CML_UI_ListCheckbox.TakeMouseClick              procedure!,byte
    code
    if keycode() = MouseLeft |
        and self.ListFEQ{PROPLIST:MouseUpZone} = LISTZONE:icon | ! Contributed by Mike Hanson
        and self.ListFEQ{PROPLIST:MouseDownZone} = LISTZONE:icon | ! Contributed by Mike Hanson
        and self.ListFEQ{PROPLIST:MouseUpRow} = self.ListFEQ{PROPLIST:MouseDownRow} |
        and self.ListFEQ{PROPLIST:MouseUpField} = self.ListFEQ{PROPLIST:MouseDownField} |
        and self.ListFEQ{PROPLIST:MouseDownField} = self.ListQCheckboxFieldNumber                 
        get(self.ListQ,choice(self.ListFEQ))
        self.ToggleCurrentCheckbox()
        put(self.ListQ)
    end
    return Level:Benign

Those two lines of code restrict the click operation to just the icon area; without them clicking anywhere in the cell that contains the icon would work. 

But there's another problem with the original method - I'd neglected to return a value, yet the Register function docs specifically say you must return one of three values from the function:

 

 

  • No labels