Bug 1465907

Summary: On Qemu/KVM deselecting any USB target from redirection instantaneously takes effect without validation of the choice.
Product: [Fedora] Fedora Reporter: ricky.tigg
Component: virt-managerAssignee: Cole Robinson <crobinso>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 25CC: alon, berrange, cfergeau, crobinso, hdegoede, marcandre.lureau, pgrunt, sandmann, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-07-17 20:00:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Deselecting any USB target from redirection instantaneously takes effect without validation of the choice. none

Description ricky.tigg 2017-06-28 12:38:05 UTC
Created attachment 1292645 [details]
Deselecting any USB target from redirection instantaneously takes effect without validation of the choice.

Description of problem:
Just by deselecting any USB target from redirection leads to take effect  instantaneously and that even without validation of the choice to be required. 

Version-Release number of selected component (if applicable):
1.4.1-2.fc25 | x86_64

How reproducible:
Steps to Reproduce:
1. On Qemu/KVM run a virtual machine. Verify that for example a USB storage is redirected to the VM. (If not select it in Redirect USB device)
2. Once redirected, deselect it.

Actual results:
Deselecting any USB target (as example a USB storage) from redirection will instantaneously take effect without validation of the choice to be required. 

Expected results:
The validation should obviously in that case require OK to be clicked.

Comment 1 Cole Robinson 2017-06-28 13:10:59 UTC
That UI comes from spice-gtk, so reassigning

Comment 2 Pavel Grunt 2017-06-29 06:31:19 UTC
(In reply to Cole Robinson from comment #1)
> That UI comes from spice-gtk, so reassigning

spice-gtk only gives you the list of usb devices.

the "ok" button is in virt-manager.

I'd suggest renaming "OK" to "Close" (or removing the button)

Comment 3 Cole Robinson 2017-07-17 20:00:59 UTC
Okay I switched the button text from OK -> Close to try and make it more clear that selection takes place immediately. Any change in behavior beyond that will have to start with spice-gtk work since it doesn't allow any different interaction logic than 'click immediately redirects the device'

commit 7d03190cb527ad6921b1ac2cd69834dfe47e6196 (HEAD -> master)
Author: Cole Robinson <crobinso>
Date:   Mon Jul 17 15:46:12 2017 -0400

    spice: s/OK/Close/ in USB redirection dialog (bz 1465907)