After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 736081 - Snapshots: Properties view of second window stays insensitive after revert
Snapshots: Properties view of second window stays insensitive after revert
Status: RESOLVED FIXED
Product: gnome-boxes
Classification: Applications
Component: snapshots
3.13.x
Other Linux
: Normal normal
: 3.22
Assigned To: GNOME Boxes maintainer(s)
GNOME Boxes maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2014-09-04 21:42 UTC by Timm Bäder
Modified: 2016-03-31 13:22 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Libvirt-Machine: Reset window on display reconnect (1011 bytes, patch)
2014-09-04 22:01 UTC, Timm Bäder
needs-work Details | Review
Libvirt-Machine: Reset window on display reconnect (1.09 KB, patch)
2014-09-08 20:08 UTC, Timm Bäder
needs-work Details | Review
libvirt-machine: Reset window on display reconnect (1.35 KB, patch)
2014-09-11 23:05 UTC, Timm Bäder
committed Details | Review

Description Timm Bäder 2014-09-04 21:42:35 UTC
I have no idea why exactly this happens, but if you open a VM in another window, then revert to a snapshot, it will first mark the back button and the sidebar insensitive, revert and then mark the back button and sidebar of the original/main window sensitive. The widgets in window2 stay insensitive.

Now, if you go back to window1 and open the vm in another window again (which shouldn't work I guess, but it does), the behavior is reproducible.

I guess that machine.window points to window1 for some reason since the notifications when deleting a snapshot also appear at window1.

This happens *only* after reverting to a snapshot.
Comment 1 Timm Bäder 2014-09-04 22:01:29 UTC
Created attachment 285427 [details] [review]
Libvirt-Machine: Reset window on display reconnect

When reconnecting the display, we first disconnect the display and then
connect it again. Disconnecting however sets the window of a Machine to
null which we want to avoid in the case of reconnecting.
Comment 2 Zeeshan Ali 2014-09-05 14:55:09 UTC
Review of attachment 285427 [details] [review]:

ACK, however if this solves the bug, you should mention in the details section about the issue.
Comment 3 Timm Bäder 2014-09-08 20:08:06 UTC
Created attachment 285676 [details] [review]
Libvirt-Machine: Reset window on display reconnect

When reconnecting the display, we first disconnect the display and then
connect it again. Disconnecting however sets the window of a Machine to
null which we want to avoid in the case of reconnecting. This previously
caused to break reverting to a snapshot of a VM that had been started in
a new window.
Comment 4 Zeeshan Ali 2014-09-09 18:03:20 UTC
Review of attachment 285676 [details] [review]:

Last sentence is a bit ambiguous. Would this be correct "This broke snapshot reverting for VMs that are running in a separate window."? If so, lets go with this instead unless you want to rather describe 'break' (which I'll prefer you do).
Comment 5 Timm Bäder 2014-09-11 23:05:28 UTC
Created attachment 285963 [details] [review]
libvirt-machine: Reset window on display reconnect

When reconnecting the display, we first disconnect the display and then
connect it again. Disconnecting however sets the window of a Machine to
null which we want to avoid in the case of reconnecting. Since Machine
defaults to the application's main_window if the machine's window is
unset, reconnecting the display caused the machine to be displayed in
the main_window and not in the window the user opened specifically for
it.

We fix this by saving the window of the machine, then reconnecting the
display and then just reassigning the window to the machine again.
Comment 6 Zeeshan Ali 2014-09-12 13:45:27 UTC
Review of attachment 285963 [details] [review]:

Perfect :)
Comment 7 Zeeshan Ali 2014-09-12 13:47:32 UTC
Attachment 285963 [details] pushed as a8065b7 - libvirt-machine: Reset window on display reconnect