Hopefully someone like Robin or Will can check this and o.k. it for inclusion in a future version.
Patches were done against wxPython 2.8.8.1 Unicode on Windows.
*numctrl *
- it did not implement the ChangeValue method - event free programmatic change of the value
I copied the SetValue and _SetValue methods and made the appropriate changes.
*maskedit.maskedit*
- the ClearValue method would fire a change event as it used SetValue to reset the control to its default value.
I copied the ClearValue method to ClearValueAlt method and changed it to use ChangeValue.
ClearValueAlt is maybe not the best name, but I could not think of anything better.
Found some more SetValue calls being used during initialization, i.e. when doing SetParameters.
Will do some more testing and provide an updated patch, probably tomorrow.
Attached the two updated patches.
Additional changes need to be made as follows:
*numctrl*
- In method SetParameters I changed SetValue to ChangeValue
*maskedit.maskedit*
- In method _configure I changed SetValue to ChangeValue
- In method _SetInitialValue I changed SetValue to ChangeValue
At this point setup/initialization of the controls and using ChangeValue will not fire any change event.
I hope that this can make it into a future version of wxPython.
Werner
I found one more problem.
In _SetInitialValue the maskedit.combobox case was not handled, i.e. needed to check isInstance(self, wx.TextCtrl) in two places before using ChangeValue instead of SetValue.
I hope that I got it all now. I checked it against my application which makes pretty heavy use of maskedit controls and I also checked the wxPython demo.
The attached patch is again against version 2.8.8.1 and is all inclusive (i.e. not just this last correction).
if __name__ == "__main__":
app = wx.PySimpleApp(0)
Browser().Show()
app.MainLoop()
When I click on a "test link" in the alert section, javascript don't works.
If I open the same page with Safari, javascript works properly.
Any idea?
PS: if I load script.aculo.us home page and related demos with webkitctrl, these demos works fine!!! Is scriptaculous based on javascript??? and why scriptaculous works and a simple alert not?