# HG changeset patch
# User Yuki KODAMA <[email protected]>
# Date 1243159339 -32400
# Node ID 7164adba3e0c07b8844be9cc9e243413ca7b3b5a
# Parent  b303eb01df2f58402548114addef683653a9321e
history: confirm overwriting when export a patch

diff --git a/hggtk/history.py b/hggtk/history.py
--- a/hggtk/history.py
+++ b/hggtk/history.py
@@ -618,6 +618,11 @@

         if result:
             if os.path.exists(result):
+                res = Confirm(_('Confirm Overwrite'), [], self,
+                   _('The file "%s" already exists!\n\n'
+                     'Do you want to overwrite it?') % result).run()
+                if res != gtk.RESPONSE_YES:
+                    return
                 os.remove(result)

             # In case new export args are added in the future, merge the

------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, & 
iPhoneDevCamp asthey present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://www.creativitycat.com 
_______________________________________________
Tortoisehg-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tortoisehg-develop

Reply via email to