TypeError: this.project.activeFrame is null

Complete the following questions so forum users and Wick Editor developers can give you the best help possible! If the following questions are not completed, your post may be edited or removed.

Has this bug been reported already?
Dont know

Describe the bug
Error console reports;
error: “TypeError: this.project.activeFrame is null”, url: “##REMOVED##wickeditor.com/editor/corelibs/wick-engine/wickengine.js”, line: 61003}
1.
error: “TypeError: this.project.activeFrame is null”
1.

url: “##REMOVED##wickeditor.com/editor/corelibs/wick-engine/wickengine.js
1.

line: 61003

To Reproduce
Steps to reproduce the bug, if you have them:

  1. Go to wickeditor /editor/
  2. Click on - draw shape - click “make button” - click “Mouseclick” - check Console
  3. Scroll down to ‘…’
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.
No errors.

Screenshots
If applicable, add screenshots to help explain your problem.

*Computer Information

  • OS: MacOS
  • Device Type: Laptop
  • Browser Firefox
    Also on the downloadable software which is why I checked the online software

Do you have a suggested solution to this issue? (ex. has another program fixed this bug a certain way? Are you familiar with where in the code base someone would need to fix this issue?)

Additional context Optional*
Add any other context about the problem here.

Many thanks

1 Like

Seems like the console found an error.
this.project.activeFrame refers to the projects active frame (or the one focused on), so the project might’ve found no value if the active frame wasn’t defined.

I failed to reproduce this bug, however, I did a little experiment that might explain this more.

I created two layers, one with a button, another totally empty, with no existing frames.
Screenshot 2021-01-19 at 8.51.43 PM
First of all, be careful with which layer you focus on
(See that “layer 2” is green? This shows that it’s focused)

In layer one, inside of the button I added there, I had this code in mouseclick:

alert(this.project.activeFrame);

Before I played the project, I focused on layer 1.
Then, after clicking the button, the value was [object, object]
Screenshot 2021-01-19 at 8.56.55 PM

Then, I focused on layer two by selecting it, then played the project without changing anything. The value was “null

Screenshot 2021-01-19 at 8.59.07 PM
This was an expected value since the layer focused on had no active frame, therefore returning no value.

However, this.project.activeFrame is a function used by Wick Editor to find your current frame inside of the editor, so it’s not supposed to show up in the console

Many thanks for your help. I have done a fresh install on a Windows laptop and I have been unable to reproduce the issue, so I guess that it was something odd that I had done. Thanks again for your help!

2 Likes

Oh, it’s the bug in the Editor.