[virt-tools-list] [virt-manager PATCH 2/2] details: introduce show_remove_button method

chenhanxiao at cn.fujitsu.com chenhanxiao at cn.fujitsu.com
Fri Apr 25 05:31:31 UTC 2014



> -----Original Message-----
> From: Cole Robinson [mailto:crobinso at redhat.com]
> Sent: Friday, April 25, 2014 1:07 AM
> To: Chen Hanxiao; Chen, Hanxiao/陈 晗霄; virt-tools-list at redhat.com
> Subject: Re: [virt-tools-list] [virt-manager PATCH 2/2] details: introduce
> show_remove_button method
> 
> On 04/24/2014 11:40 AM, Chen Hanxiao wrote:
> >
> > On 04/24/2014 11:29 PM, Cole Robinson wrote:
> >> On 04/24/2014 11:22 AM, Chen Hanxiao wrote:
> >>>
> >>> a)  vm -> details
> >>> b) select one device(not USB controller)
> >>> c) right click on USB controller
> >>> d) we could use the popup menu to remove USB controller
> >>>
> >> Hmm, that doesn't work for me. When I right click, it selects that list entry
> >> before showing the pop up menu, so everything is in the right state. Are you
> >> using gnome-shell? Weirdness like this is often due to gtk on other desktops.
> > Yes, I used gnome-shell.
> > It seemed that right click is ahead of selection.
> >> Regardless, we should fix it by forcing that behavior: before showing the
> >> popup menu, force select the list entry (if it's not already selected).
> >>
> >> - Cole
> >>
> > That's a good idea.
> > Can you give some hints?
> >
> 
> gtktreeview has this function:
> 
> https://developer.gnome.org/gtk3/stable/GtkTreeView.html#gtk-tree-view-get-
> path-at-pos
> 
> Can be used to get the treeiter for the row that was clicked on. You can use
> that to force the selection.
> 
> - Cole

Thanks, I'll have a try.

- Chen





More information about the virt-tools-list mailing list