summaryrefslogtreecommitdiffstats
path: root/library/tkfbox.tcl
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2011-10-05 19:18:20 (GMT)
committerdgp <dgp@users.sourceforge.net>2011-10-05 19:18:20 (GMT)
commit7f0c75ac2e61b2457146f5b2a39e252b250196b5 (patch)
tree4fe7f10e2615504ad9f1e944efb5fdb14ba6edd4 /library/tkfbox.tcl
parent7571c73ea570497dcb0c8900ba99fcef9f4cbbfe (diff)
downloadtk-7f0c75ac2e61b2457146f5b2a39e252b250196b5.zip
tk-7f0c75ac2e61b2457146f5b2a39e252b250196b5.tar.gz
tk-7f0c75ac2e61b2457146f5b2a39e252b250196b5.tar.bz2
Revise the proposed "-nocomplain" option to "-confirmoverwrite"
Diffstat (limited to 'library/tkfbox.tcl')
-rw-r--r--library/tkfbox.tcl4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/tkfbox.tcl b/library/tkfbox.tcl
index ffffb3e..214a31b 100644
--- a/library/tkfbox.tcl
+++ b/library/tkfbox.tcl
@@ -986,7 +986,7 @@ proc ::tk::dialog::file::Config {dataName type argList} {
# The "-nocomplain" option is only available for the "save" file dialog.
#
if {$type eq "save"} {
- lappend specs {-nocomplain "" "" "0"}
+ lappend specs {-confirmoverwrite "" "" "1"}
}
# 2: default values depending on the type of the dialog
@@ -1865,7 +1865,7 @@ proc ::tk::dialog::file::Done {w {selectFilePath ""}} {
set Priv(selectFile) $data(selectFile)
set Priv(selectPath) $data(selectPath)
- if {($data(type) eq "save") && !$data(-nocomplain) && [file exists $selectFilePath]} {
+ if {($data(type) eq "save") && $data(-confirmoverwrite) && [file exists $selectFilePath]} {
set reply [tk_messageBox -icon warning -type yesno -parent $w \
-message [mc "File \"%1\$s\" already exists.\nDo you want\
to overwrite it?" $selectFilePath]]