Commit 862da160 authored by Felipe Borges's avatar Felipe Borges 👣 Committed by Felipe Borges

wizard: Notify when unable to add RDP server

Whenever Boxes is compiled without RDP support (rdp=false build
option) and the user wants to add an rdp:// address, we present
an human-readable error message notifying that.

This is a counter measure because we want to advertise the RDP
support in the "Enter an URL" dialog, but the RDP support is
optional (build option).
parent 5360ea5f
......@@ -347,7 +347,7 @@
<property name="max-width-chars">64</property>
<property name="halign">start</property>
<property name="xalign">0.0</property>
<property name="label" translatable="yes">Enter an address for the box you want to add. Addresses can be of installation images, SPICE and VNC servers, or oVirt or Libvirt brokers.</property>
<property name="label" translatable="yes">Enter an address for the box you want to add. Addresses can be of installation images, SPICE, RDP and VNC servers, or oVirt or Libvirt brokers.</property>
</object>
<packing>
<property name="expand">True</property>
......
......@@ -363,9 +363,10 @@ private void prepare_for_uri (string uri_as_text, string? filename = null) throw
source.source_type = "spice";
} else if (uri.scheme == "vnc") {
// accept any vnc:// uri
#if HAVE_RDP
} else if (uri.scheme == "rdp") {
// accept any rdp:// uri
#if !HAVE_RDP
throw new Boxes.Error.INVALID (_("Boxes was compiled without RDP support"));
#endif
} else if (uri.scheme.has_prefix ("qemu")) {
// accept any qemu..:// uri
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment