GNOME Bugzilla – Bug 172605
Problems when undoing a Cut + Paste
Last modified: 2005-04-06 23:47:29 UTC
When undoing a Cut followed by a paste in the same location the following error occurs: Traceback (most recent call last):
+ Trace 57688
self._command_manager.undo(self._project)
cmd.undo()
self.execute()
self._execute_undo()
gparent = widget.get_widget_from_gtk_widget(parent)
return gtk_widget.get_data('GladeWidgetDataTag')
To reproduce the bug: 1) Create a window and add a Label 2) Cut the label 3) Paste the label in the same slot as it was cut from 4) Undo bothe the Paste and the Cut
Created attachment 39675 [details] [review] Patch This patch solves the problem for this particular case but I think it's only hiding the real bug. There might be some strangeness is e.g. replace_widget() or similar but I don't know that code that well.
As you said it only fix the problem in this particular case and it also introduces other bugs. I fixed it with very similar code as yours: if not self._placeholder: self._placeholder = placeholder.Placeholder(self._app) It's fixed in trunk