diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2012-07-23 13:59:40 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2012-07-23 13:59:40 (GMT) |
commit | 571fd220b0be2da05b1a6e8bb32e0b9a447ed288 (patch) | |
tree | 46a3064598e4a36c7ca561f9c08f5d22de4b2b9e /generic/ttk/ttkWidget.c | |
parent | ed7fb54396eee6e5122bfe611b2a14cf422970fa (diff) | |
download | tk-571fd220b0be2da05b1a6e8bb32e0b9a447ed288.zip tk-571fd220b0be2da05b1a6e8bb32e0b9a447ed288.tar.gz tk-571fd220b0be2da05b1a6e8bb32e0b9a447ed288.tar.bz2 |
Much more cleaning up of result handling.
Diffstat (limited to 'generic/ttk/ttkWidget.c')
-rw-r--r-- | generic/ttk/ttkWidget.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/generic/ttk/ttkWidget.c b/generic/ttk/ttkWidget.c index d5e0484..016653d 100644 --- a/generic/ttk/ttkWidget.c +++ b/generic/ttk/ttkWidget.c @@ -440,7 +440,8 @@ int TtkWidgetConstructorObjCmd( error: if (WidgetDestroyed(corePtr)) { - Tcl_SetResult(interp, "Widget has been destroyed", TCL_STATIC); + Tcl_SetObjResult(interp, Tcl_NewStringObj( + "widget has been destroyed", -1)); } else { Tk_DestroyWindow(tkwin); } @@ -634,8 +635,8 @@ int TtkWidgetConfigureCommand( return status; if (mask & READONLY_OPTION) { - Tcl_SetResult(interp, - "Attempt to change read-only option", TCL_STATIC); + Tcl_SetObjResult(interp, Tcl_NewStringObj( + "attempt to change read-only option", -1)); Tk_RestoreSavedOptions(&savedOptions); return TCL_ERROR; } @@ -649,7 +650,8 @@ int TtkWidgetConfigureCommand( status = corePtr->widgetSpec->postConfigureProc(interp,recordPtr,mask); if (WidgetDestroyed(corePtr)) { - Tcl_SetResult(interp, "Widget has been destroyed", TCL_STATIC); + Tcl_SetObjResult(interp, Tcl_NewStringObj( + "widget has been destroyed", -1)); status = TCL_ERROR; } if (status != TCL_OK) { |