Bug? mouse events not detected in progressbar & others

John-E

Member
Licensed User
Longtime User
In a dummy project containing
Private Slider1 As Slider
Private ProgressBar1 As ProgressBar
Private ImageView1 As ImageView
Private Label1 As Label
Private Pane1 As Pane
Private ProgressIndicator1 As ProgressIndicator

These never get called:

Sub ProgressBar1_MouseClicked (EventData As MouseEvent)
Log("ProgressBar1_MouseClicked")
End Sub

Sub ImageView1_MouseClicked (EventData As MouseEvent)
Log("ImageView1_MouseClicked")
End Sub

Sub ProgressIndicator1_MouseClicked (EventData As MouseEvent)
Log("ProgressIndicator1_MouseClicked")
End Sub

The others work as expected. Semm to be a bug. Any advice?

Regards, John
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Please use [code]code here...[/code] tags when posting code.

ImageView mouse click does work. If it doesn't work for you then start a new thread in the questions forum.

The events are added to all views. However there are some views that consume the events internally so they cannot be used although they appear (the events belong to the common base class). This is the case with ProgressBar and ProgressIndicator. It is possible to add a special listener with Reflector.
 

John-E

Member
Licensed User
Longtime User
Please use [code]code here...[/code] tags when posting code.

ImageView mouse click does work. If it doesn't work for you then start a new thread in the questions forum.

The events are added to all views. However there are some views that consume the events internally so they cannot be used although they appear (the events belong to the common base class). This is the case with ProgressBar and ProgressIndicator. It is possible to add a special listener with Reflector.

Thanks for the response Erel.

I understand; and I didn't add and image to the ImageView, that might make a difference. Not a bug exactly, then, but if an event is not actually usable directly, perhaps it shouldn't be available to be added with a simple box check in the Designer?
I'll go and learn about Reflector.

Regards, John
 
Top