-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Issue #9: unexpected onChange event after setting the value from …
…the server
- Loading branch information
hanhsu
committed
Oct 9, 2014
1 parent
fb162a1
commit eba7b53
Showing
4 changed files
with
28 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<zk> | ||
<zscript> | ||
String myValue = "initial value"; | ||
public updateMyValue(String newValue) { | ||
myValue = newValue; | ||
editor.setValue(myValue); | ||
//Clients.showNotification("updated myValue to: " + myValue); | ||
} | ||
</zscript> | ||
<vlayout> | ||
<button label="1. update editor value to 'abc'" onClick='updateMyValue("<p>abc</p>");' /> | ||
<button label="2. update editor value to 'XYZ'" onClick='updateMyValue("<p>XYZ</p>");' /> | ||
<button label="3. do something unrelated and show 'myvalue'" | ||
onClick='debugLabel.setValue("myValue: " + myValue);' /> | ||
<label id="debugLabel" /> | ||
<ckeditor id="editor" value="${myValue}" onChange='myValue = self.getValue(); alert("changed")' /> | ||
</vlayout> | ||
</zk> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters