TextEditor::setText(txt, sendNotification) triggers callback in constructor [ NOT BUG - resolved ]

i'm not sure if this is a bug?

TextEditor::setText (const String& newText, bool sendTextChangeMessage = true);

even if i set sendTextChangeMessage as false the textEditorTextChanged callback still triggered.

i track in the calling stack, ths sequence:


or this only occrs when the texteditor being initialized in the consturctor?

my code is very simple:

in the class MyWnd constructor:


txt.setText("......", false);   //and the callback triggered.

and this only happens 1 time

txt.setText("..aa...", false);   //no event!

txt.setText("...bb.", false);   //no event!


OS: Win7

JUCE: v3.0.8


i just tried JUCE v3.1.0 and this problem still exists.

Can you give me a lump of code that reproduces this, so I can quickly debug it?

I'm so sorry Jules, that's my fault, in my constructor there is another method and it calls myTxtBox.clear(); this causes the triggering.

forgive my stupid behaviour.. even though I have read the topic "Reporting Bugs - Please read this before doing so!".