| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The oVirt foreign menu support reused some existing bits from the older
SPICE controller foreign menu code. However, this controller code is
only built when spice-gtk support is built, while the oVirt foreign menu
code could be used with VNC as well. Trying to build the ovirt foreign
menu code without spice-gtk causes build issues due to missing
functions, or missing declarations, ...
The libgovirt/spice-gtk code which is entangled is the code to update
the foreign menu when its content changes, or when a new window is
opened. Making the oVirt-specific code independant from the
spice-gtk-specific code is not too complicated, but this comes at the
expense of a bit of code duplication, but this is only simple code
iterating over the GHashTable storing the opened windows.
Resolves: rhbz#1127156
|
|
|
|
|
| |
There's no need to ref the SpiceDisplay widget when adding it to a
container. The container will take its own ref.
|
|
|
|
| |
Don't leak priv->uri or priv->domkey from VirtViewer class
|
|
|
|
| |
Change g_warning to g_debug as suggested by Marc-Andre
|
|
|
|
|
|
| |
Instead of returning 0 for success and -1 for failure, change to a
boolean success value to be more consistent with the rest of the
virt-viewer code.
|
|
|
|
|
| |
When collect_credentials() returns a failure status, 'username' was
potentially leaked.
|
|
|
|
|
|
| |
Minor fixes from patch review
rhbz#1061826
|
|
|
|
|
|
|
|
| |
We have to force displays to update geometry when the agent connects to
ensure the client will have the guest with the right resolution when the
guest has rebooted or the agent has crashed.
https://bugzilla.redhat.com/sho_bug.cgi?id=1021841
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
As virt-viewer uses GtkAccelMap for shortcuts and that GTK only can have
one key binding per accelerator (in accel_map_add_entry), let's also add
support specificly for the numpad keys in the virt-viewer code
https://bugzilla.redhat.com/show_bug.cgi?id=883433
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the .vv file has an [ovirt] section, we should try to create a foreign
menu out of it. This will allow remote-viewer to offer a menu to change the
currenty inserted cdrom.
Contrary to the ovirt:// case when we already have fetched an OvirtAPI
and OvirtVm instance in order to get the SPICE/VNC connection details,
when working from a .vv file, we'll need to get them from the REST API.
Authentication should happen through the JSESSIONID cookie, if that
fails we want to give up on using the foreign menu, so we don't need to
set up authentication callbacks.
|
|
|
|
|
| |
They will be useful to implement foreign menu support through
oVirt REST API
|
|
|
|
|
|
| |
For foreign menu support, we'll need a way to pass oVirt-specific
information in the .vv file. This will be done through an additional
[ovirt] section, this commit is in preparation for that.
|
|
|
|
|
| |
After the previous commit which introduced the OvirtForeignMenu
class, we can now make use of it in the remote-viewer UI code.
|
|
|
|
|
|
|
| |
This class is used to implement the so-called oVirt 'foreign menu'
which is a menu populated with ISO images available on the
oVirt instance that the user can dynamically insert into the
virtual machine he is currently viewing.
|
|
|
|
|
|
|
|
|
|
|
|
| |
The 'path' part of the URI will always start with a '/' when present as
this is what separates it from the hostname. When rebuilding the final
URI, the current code inserts a '/' by itself between the hostname and
the path, which results in URIs with an extra '/':
https://ovirt.example.com//some/path/api
This is not only cosmetic as this can cause issues with cookie handling
if libgovirt accesses //some/path/api while the cookie is set for
/some/path/api.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the user launches remote-viewer with an ovirt URI of the form
ovirt://user@host/vmname
Pre-populate the authentication dialog with the specified username. We
don't support specifying the password on the commandline, since that is
a potential security risk.
rhbz#1061826
|
|
|
|
|
|
|
|
|
| |
When launching from a vv-file, we want to use the ca specified in the vv
file and not load additional certs from the fallback ca-file. This
ensures that the ca-file property of the spice session is unset when
loading a ca from a vv-file.
Resolves: rhbz#1127762
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
use <display>:<monitor>;<display>:<monitor> instead of simply implying the
display from the array index (e.g. <monitor>;<monitor>). This allows you to set
up sparse guest displays (e.g. display 1 + 3).
For example, to configure display 1 to be fullscreen on monitor 2 and display 2
to be fullscreen on monitor 3:
monitor-mapping=1:2;2:3
|
|
|
|
|
|
| |
This allows the user to obtain the GUID and vm name of the currently-connected
guest. Obviously, this only works with spice. In the future, it will allow them
to set guest-specific configuration options (using a GUID as a key)
|
|
|
|
|
|
|
| |
Going to fullscreen, and then exiting causes these messages to show up
on the console:
(remote-viewer:14481): GLib-CRITICAL **: Source ID 784 was not found
when attempting to remove it
|
| |
|
|
|
|
| |
The 'app' parameter is used in the function.
|
|
|
|
|
| |
The vfunc implementation is only chaining to its parent, removing it
will achieve the same result.
|
|
|
|
|
|
| |
glib documentation says this should be the last thing done in the
dispose() call, which makes sense as this could invalidate still-needed
data in the parent object.
|
|
|
|
|
| |
The XML menu accelerators conflict with accelerator set in the code and
prevent using them. This is a regression from d29fc63d.
|
|
|
|
|
|
| |
Filter only our own debug messages.
https://bugzilla.redhat.com/show_bug.cgi?id=1118365
|
|
|
|
|
|
| |
Avoid creating empty settings files, always set the ask-quit key.
https://bugzilla.redhat.com/show_bug.cgi?id=1006737
|
|
|
|
| |
spice_channel_get_error() is not guarantee to return a GError.
|
|
|
|
|
|
|
| |
Make ctrl-[+-] zoom in/out in fullscreen
with mouse over the control bar.
https://bugzilla.redhat.com/show_bug.cgi?id=987549
|
|
|
|
|
|
| |
It may be useful to provide more detailed reason for disconnection.
https://bugzilla.redhat.com/show_bug.cgi?id=1115986
|
|
|
|
|
| |
Add a function to create an application dialog. In the following
commit, we will add more details for connection failures.
|
|
|
|
|
|
|
|
| |
Encapsulate things a bit better by adding
virt_viewer_app_get_option_group() which provides a GOptionGroup rather
than exposing an array of options. This option is then set as the main
option group, and additional options can be added by subclasses, so the
effect to the user should be equivalent.
|
|
|
|
|
|
| |
Use g_option_context_set_summary() to provide a brief description of the
executable instead of tacking the summary onto the end of the
commandline.
|
|
|
|
|
|
|
| |
The man page already has a description of the vv-file format, but the
--help output didn't mention it how to use it.
References: rhbz#970825
|
|
|
|
|
|
|
|
| |
Declaring a local variable as part as a for loop
such as 'for (unsigned int i; i < N; i++)' is a C99 specific feature.
Running configure with --enable-compile-warnings=minimal does not add
-std=c99 to the compile flags, so it's better if the codebase does not
require C99 support from the compiler.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit 6edde5786 introduced a regression wrt shrinking windows on windows
guests. This seems to be because resizing a display often causes the notebook
widget to switch to the status page temporarily (often so quickly that it's not
noticeable to the eye). This causes a quick 'unmap' and 'map' event sequence on
the display widget. Apparently the timing of these events varies enough between
linux and windows guests that it is only noticeable on windows gueststhe timing
of these events varies enough between linux and windows guests that it is only
noticeable on windows guests. The exact sequence that causes the bug appears to
be as follows:
1 user resizes window smaller
2 display widget gets a new allocation, which causes it to send a display
reconfiguration to the guest
3 client receives a new show-hint for the display which causes it to switch
temporarily to the 'status' notebook page
4 display widget gets unmapped
5 Client receives another new show-hint, which causes the display widget to get
re- mapped, which causes client to send a display reconfiguration to the guest
(using the old size)
6 client receives new (smaller, from step 2) display size and temporarily
changes to the new size
7 client receives new (larger, from step 5) display size and changes back to
original size.
To fix the issue, we only explicitly request a resize in response to the very
first map event, and for any subsequent map events, we simply call
_make_resizable() as before.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
You can reproduce the error by starting the client in kiosk and shuting
down the guest.
#0 0x000000317e432915 in raise (sig=6) at
../nptl/sysdeps/unix/sysv/linux/raise.c:64
#1 0x000000317e4340f5 in abort () at abort.c:92
#2 0x000000317fc4a98a in g_logv (log_domain=0x318730e657 "Gtk",
log_level=<value optimized out>, format=
0x31873a50a8 "A floating object was finalized. This means that
someone\ncalled g_object_unref() on an object that had only a
floating\nreference; the initial floating reference is not owned by
anyone\nand must be remo"..., args1=0x7fffffffd5f0)
at gmessages.c:557
#3 0x000000317fc4aa23 in g_log (log_domain=<value optimized out>,
log_level=<value optimized out>,
format=<value optimized out>) at gmessages.c:577
#4 0x000000318717ba72 in ?? () from /usr/lib64/libgtk-x11-2.0.so.0
#5 0x0000000000426eb5 in
virt_viewer_display_spice_finalize (obj=0x6fec20
[VirtViewerDisplaySpice])
at virt-viewer-display-spice.c:67
#6 0x0000003180c106a4 in g_object_unref (_object=0x6fec20) at
gobject.c:2712
#7 0x0000000000425b5d in destroy_display (data=0x6fec20) at
virt-viewer-session-spice.c:596
#8 0x000000317fc1667b in g_ptr_array_foreach (array=0x74a040,
func=0x425ae7 <destroy_display>, user_data=0x0)
at garray.c:1306
#9 0x000000317fc16e7b in g_ptr_array_free (farray=0x74a040,
free_segment=1) at garray.c:938
#10 0x000000317fc2906a in g_data_set_internal (datalist=<value optimized
out>, key_id=1297, data=0x0, destroy_func=0)
at gdataset.c:351
#11 g_datalist_id_set_data_full (datalist=<value optimized out>,
key_id=1297, data=0x0, destroy_func=0) at gdataset.c:598
#12 0x00000000004268d0 in
virt_viewer_session_spice_channel_destroy (s=0x800000 [SpiceSession],
channel=
|
|
|
|
|
|
| |
This unref doesn't seem to be related to any reference, although it
was probably introduced in the first place to clear the floating ref,
wrongly. See following commit for a working solution.
|
|
|
|
| |
glib_check_version() returns NULL if version is higher or equal.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
rhbz#1104064 had a couple of symptoms. The first was fixed in
6edde57862ac30e74ce6412c93a2fa925ae4ea67.
The second symptom is that displays could also become tiny when clicking 'View >
Zoom > Normal Size'. This was because VirtViewerDisplay returned early from
_display_set_zoom_level() if the zoom level was being set to the current zoom
setting. However, the calling function (_window_set_zoom_level()) also tries to
queue a resize event for itself after setting the zoom level on the display. If
the display doesn't queue a resize event for itself, its size request will only
be 50x50 during the window resize negotiation. This causes the display to become
tiny and zoomed out. Queueing a resize on the display widget ensures that it
will request the proper size during the next allocation.
|
|
|
|
|
|
| |
Fixes guest can not be resized to expected window size after zoom out.
https://bugzilla.redhat.com/show_bug.cgi?id=1105528
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When enabling a new display on linux guests, the new window would be tiny
(50x50) and zoomed way out. This was caused by the fact that when the display
widget received the 'map' event, it unconditionally cleared the 'dirty' flag,
which meant that it would only request 50x50 size. This behavior was intended to
fix a bug on the windows client which wprevented windows from resized smaller
than the guest display resolution. Unfortunately, due to the timing of the 'map'
and allocate events, the widget became very small.
Instead of clearing the 'dirty' flag directly when a widget is mapped, we
now queue a resize event, which will guarantee that the widget attains its
desired size and will then clear its dirty flag (allowing it to be resized).
Testing on windows indicates that this fix still solves the 'unshrinkable
window' problem while also preventing the tiny secondary display bug.
Resolves: rhbz#1104064
|
| |
|
|
|
|
|
|
|
| |
On RHEL6, with old glib, all g_log messages are printed.
Filter the messages with a custom handler instead.
https://bugzilla.redhat.com/show_bug.cgi?id=1107518
|
|
|
|
|
|
|
| |
Get rid of the following warning:
(virt-viewer:7262): virt-viewer-WARNING **: Can't hide windows in kiosk mode
https://bugzilla.redhat.com/show_bug.cgi?id=1107518
|
|
|
|
| |
https://bugzilla.redhat.com/show_bug.cgi?id=1107518
|