Progress HUD for corona app

Hi,

I would like to develop a loading component like (https://github.com/jdg/MBProgressHUD), 

I know how I’ll add activity indicator widget and how to add black rounded background Image.

The problem is . .I want to disable the user interaction on all screen elements, so that none of the ‘touch’ event listener get fired.

Please let me know how to achieve this.

Thanks,

Hello @contact130,

One option for this is to place a big rectangle (vector object) over the entire screen area, make it invisible (but with .isHitTestable = true), apply a touch listener to it, then have that listener just “return true” but do nothing else. This should effectively block all other input to anything below.

If you go this route, remember to properly remove and clean up the listener when you’re done with it.

Best regards,

Brent Sorrentino

Hello @contact130,

One option for this is to place a big rectangle (vector object) over the entire screen area, make it invisible (but with .isHitTestable = true), apply a touch listener to it, then have that listener just “return true” but do nothing else. This should effectively block all other input to anything below.

If you go this route, remember to properly remove and clean up the listener when you’re done with it.

Best regards,

Brent Sorrentino

Brent, I don’t believe your solution would work to grab touches from native.textFields, right?

Any idea on how to disable user interaction on textField as well?

renato, you can try to  use .isEditable = false. it will disable input text in native.newTextBox.

in native.newTextField you can do it yourself in the inputListener(event). why corona don’t have .isEditable on newTextField beats me.

Brent, I don’t believe your solution would work to grab touches from native.textFields, right?

Any idea on how to disable user interaction on textField as well?

renato, you can try to  use .isEditable = false. it will disable input text in native.newTextBox.

in native.newTextField you can do it yourself in the inputListener(event). why corona don’t have .isEditable on newTextField beats me.