[gnome-maps/gnome-43] sendToDialog: Use GLib.uri_escape_string()
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-maps/gnome-43] sendToDialog: Use GLib.uri_escape_string()
- Date: Thu, 22 Sep 2022 19:56:01 +0000 (UTC)
commit 0f43ea97c2624f81d35b8bc48ba46e361ee9cdb8
Author: Marcus Lundblad <ml dfupdate se>
Date: Thu Sep 22 21:33:36 2022 +0200
sendToDialog: Use GLib.uri_escape_string()
Change from libsoup's URI escape functionallity
to using the one from GLib, as that API is removed
in libsoup3.
src/sendToDialog.js | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/src/sendToDialog.js b/src/sendToDialog.js
index caa4ae96..549d2f54 100644
--- a/src/sendToDialog.js
+++ b/src/sendToDialog.js
@@ -24,7 +24,6 @@ import GLib from 'gi://GLib';
import GObject from 'gi://GObject';
import Gtk from 'gi://Gtk';
import GWeather from 'gi://GWeather';
-import Soup from 'gi://Soup';
import {Application} from './application.js';
import {PlaceFormatter} from './placeFormatter.js';
@@ -180,8 +179,8 @@ export class SendToDialog extends Gtk.Dialog {
_emailSummary() {
let title = new PlaceFormatter(this._place).title;
let summary = "%s\n%s".format(this._getSummary(), this._getOSMURI());
- let uri = 'mailto:?subject=%s&body=%s'.format(Soup.URI.encode(title, null),
- Soup.URI.encode(summary, null));
+ let uri = 'mailto:?subject=%s&body=%s'.format(GLib.uri_escape_string(title, null, false),
+ GLib.uri_escape_string(summary, null, false));
try {
Gio.app_info_launch_default_for_uri(uri, this._getAppLaunchContext());
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]