[Masters] Events disappear when loading prototype.

Victor Gerritsen shared this problem 1 year ago
Known

Goodmorning,


I have ran into this problem on several occasions, where i reload a prototype from disk (or via a shared team prototype) and upon checking the events tab for the master components, the events have disappeared.


The way i have setup the prototype is this roughly:


Progressbar in master


  1. Create a master and have 2 shapes "bg_bar" (width 90% of screen width) and "fg_bar" (width 0), hide these components.
  2. Create a variable named "total_num_questions" and set it to 0.
  3. Create a variable named "current_question_num" and set it to 0.
  4. Create an event "on variable change" for the "total_num_questions" variable with the SHOW action and add a condition "total_num_questions" > 0
  5. Add action to the ELSE to HIDE "bg_bar" and "fg_bar".
  6. Create an event "on variable change" for the "current_question_num" to RESIZE a screen component, the "fg_bar" element.
  7. Select "Calculated" from the width dropdown, and enter the expression:

    round( bg_width / total_num_questions * current_question_num, 0 )

  8. Create a new screen
  9. On page load event set "total_num_questions" to.. lets say 8.
  10. Create a panel with a few layers, and within each layer increment the "current_question_num" on "Panel Active" event
  11. Add a button to change active panel
  12. Drag the master into the screen, below the panel


The goal of this master is to show a progressbar when a quiz screen is active. The variable "total_num_questions" will change and the bar will show, upon changing active panels the "current_question_num" will change and the "fg_bar" (bar on the foreground which indicates progress) will be resized to reflect the progress of the user.

Comments (3)

photo
1

Dear Victor,


Thank you so much for your contribution. I will transfer this information to our development team so they can take this into account on future updates.


Best,


Sonia Durán

photo
1

Hi, Having the same problem only on "on variable change" event, when attached to the screen (top outline item). If you attach the event to an item in the master there is no problem.

Here is the process to create the bug:

- 1: create a master with items in it (rectangles or other doesn't matter).

- 2: add event "variable change" on both screen and an item in the screen.

- 3: close prototype

- 4: open prototype and check events on the master > the one on the screen is not here anymore, the one on the item is still working...

What is strange is if you create an event "on page load" on the screen it doesn't disappear.

Seems to happen on both local and shared prototype.

photo
1

Dear Axel,

Thank you so much for your contribution. I have already transferred the information to our engineers.

Best,

photo