Win32Lib bug in registerControl()

new topic     » topic index » view thread      » older message » newer message

So I've been playing around with custom controls, and I'm pretty sure I found bug. The documentation for registerControl() states:

classType
return the control type the library should consider your control to belong to. Default is -1. For instance, return RichEdit if your contol is to be sent RichEdit-specific messages.

However, in the code (around line 26296), there is this:

26296    lClass = call_func(pRID[kCRID_Control], {"classType", -1}) 
26297    classAlias[lControl] = lClass 
26298    classType[lControl] = classType[lClass] 

If the "Control" routine returns the default -1 as stated in the docs, the application crashes since it is trying to use lClass as an index into classType.

C:\EUPHORIA\Win32Lib\Include\win32lib.ew:26298 in function registerControl() 
subscript value -1 is out of bounds, reading from a sequence of length 62 

And I'm honestly not too sure how to go about fixing it. getlost

-Greg

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu