summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2020-01-18 12:12:46 (GMT)
committerfvogel <fvogelnew1@free.fr>2020-01-18 12:12:46 (GMT)
commit2f09e3e81874d1261f624bbdbec3e1ec2a94446f (patch)
tree2f6460b1fbde06913265ac9c70667ef59e0c64dc /generic
parent31f67224a92cd43e51a0bf7131764f06eb30b742 (diff)
parent3930846c8e8c238310cc93c4214f54ca4fc9e27b (diff)
downloadtk-2f09e3e81874d1261f624bbdbec3e1ec2a94446f.zip
tk-2f09e3e81874d1261f624bbdbec3e1ec2a94446f.tar.gz
tk-2f09e3e81874d1261f624bbdbec3e1ec2a94446f.tar.bz2
Fix [2830360fff]: ttk::entry looses state invalid at focus events. Add non-regression test entry-11.1
Diffstat (limited to 'generic')
-rw-r--r--generic/ttk/ttkEntry.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/generic/ttk/ttkEntry.c b/generic/ttk/ttkEntry.c
index 37b4dbc..842c4b5 100644
--- a/generic/ttk/ttkEntry.c
+++ b/generic/ttk/ttkEntry.c
@@ -676,8 +676,12 @@ static int EntryRevalidate(Tcl_Interp *interp, Entry *entryPtr, VREASON reason)
static void EntryRevalidateBG(Entry *entryPtr, VREASON reason)
{
Tcl_Interp *interp = entryPtr->core.interp;
- if (EntryRevalidate(interp, entryPtr, reason) == TCL_ERROR) {
- Tcl_BackgroundException(interp, TCL_ERROR);
+ VMODE vmode = entryPtr->entry.validate;
+
+ if (EntryNeedsValidation(vmode, reason)) {
+ if (EntryRevalidate(interp, entryPtr, reason) == TCL_ERROR) {
+ Tcl_BackgroundException(interp, TCL_ERROR);
+ }
}
}