Add parameter (bool immediate) to TextChanged signal in interface 75/255875/3
authorBowon Ryu <bowon.ryu@samsung.com>
Wed, 24 Mar 2021 10:17:05 +0000 (19:17 +0900)
committerBowon Ryu <bowon.ryu@samsung.com>
Fri, 26 Mar 2021 08:36:15 +0000 (17:36 +0900)
virtual void TextChanged(bool immediate) = 0;
using immediate, can decide whether we only emit the signal when OnRelayout() is called next time,
otherwise emits it immediately.

* there is a issue that the timing of callback calls has been delayed
due to a recent patch that limits unnecessary callbacks.
(33ccee79d16a90d5f7ab427de1503ccc5bee4324)

Because of this, there is a problem that the TC like example below fails.
This patch can prevents the following issues.

/* example */

bool textChanged;

...

static void OnTextChanged(TextField control)
{
  textChanged = true;
}

...

field.TextChangedSignal().Connect(&OnTextChanged);
textChanged = false;
field.SetProperty(TextField::Property::TEXT, "hello");
DALI_TEST_CHECK(textChanged); // At this point, textChanged is false, so TC Fail occurs.

/* example */

Change-Id: If0a331c56f35eae931b34d128b4fe4282fc686b6
Signed-off-by: Bowon Ryu <bowon.ryu@samsung.com>

No differences found