[shotwell/wip/phako/libsecret: 254/254] wip
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [shotwell/wip/phako/libsecret: 254/254] wip
- Date: Thu, 22 Aug 2019 15:20:54 +0000 (UTC)
commit fa7088febd73e6f406803083de0c6094ce188cc5
Author: Jens Georg <mail jensge org>
Date: Thu Aug 22 17:18:40 2019 +0200
wip
plugins/authenticator/shotwell/OAuth1Authenticator.vala | 14 ++++++--------
plugins/shotwell-publishing-extras/GalleryConnector.vala | 4 ++++
2 files changed, 10 insertions(+), 8 deletions(-)
---
diff --git a/plugins/authenticator/shotwell/OAuth1Authenticator.vala
b/plugins/authenticator/shotwell/OAuth1Authenticator.vala
index 4ab19e9d..ca19dc17 100644
--- a/plugins/authenticator/shotwell/OAuth1Authenticator.vala
+++ b/plugins/authenticator/shotwell/OAuth1Authenticator.vala
@@ -73,8 +73,7 @@ namespace Publishing.Authenticator.Shotwell.OAuth1 {
protected void set_persistent_access_phase_username(string? username) {
try {
if (username == null || username == "") {
- Secret.password_clear_sync(this.schema, Secret.COLLECTION_DEFAULT,
- "Shotwell publishing (%s)".printf(this.service),
+ Secret.password_clear_sync(this.schema, null,
"type", SECRET_TYPE_USERNAME);
} else {
Secret.password_store_sync(this.schema, Secret.COLLECTION_DEFAULT,
@@ -88,7 +87,8 @@ namespace Publishing.Authenticator.Shotwell.OAuth1 {
protected string? get_persistent_access_phase_token() {
try {
- return Secret.password_lookup_sync(this.schema, null, "type", SECRET_TYPE_AUTH_TOKEN);
+ return Secret.password_lookup_sync(this.schema, null,
+ "type", SECRET_TYPE_AUTH_TOKEN);
} catch (Error err) {
critical("Failed to lookup auth-token from password store: %s", err.message);
return null;
@@ -98,8 +98,7 @@ namespace Publishing.Authenticator.Shotwell.OAuth1 {
protected void set_persistent_access_phase_token(string? token) {
try {
if (token == null || token == "") {
- Secret.password_clear_sync(this.schema, Secret.COLLECTION_DEFAULT,
- "Shotwell publishing (%s").printf(this.service),
+ Secret.password_clear_sync(this.schema, null,
"type", SECRET_TYPE_AUTH_TOKEN);
} else {
Secret.password_store_sync(this.schema, Secret.COLLECTION_DEFAULT,
@@ -122,9 +121,8 @@ namespace Publishing.Authenticator.Shotwell.OAuth1 {
protected void set_persistent_access_phase_token_secret(string? secret) {
try {
- if (secrent == null || secret == "") {
- Secret.password_clear_sync(this.schema, Secret.COLLECTION_DEFAULT,
- "Shotwell publishing (%s").printf(this.service),
+ if (secret == null || secret == "") {
+ Secret.password_clear_sync(this.schema, null,
"type", SECRET_TYPE_AUTH_TOKEN_SECRET);
} else {
Secret.password_store_sync(this.schema, Secret.COLLECTION_DEFAULT,
diff --git a/plugins/shotwell-publishing-extras/GalleryConnector.vala
b/plugins/shotwell-publishing-extras/GalleryConnector.vala
index 9932862a..36be6bfd 100644
--- a/plugins/shotwell-publishing-extras/GalleryConnector.vala
+++ b/plugins/shotwell-publishing-extras/GalleryConnector.vala
@@ -57,14 +57,18 @@ private class ShotwellPublishingGallery3 : Object, Spit.Module {
// The Pluggable
public class Gallery3Service : Object, Spit.Pluggable,
Spit.Publishing.Service {
+ private const string PASSWORD_SCHEME = "org.gnome.Shotwell.Gallery3";
private const string ICON_FILENAME = "gallery3.png";
private static Gdk.Pixbuf[] icon_pixbuf_set = null;
+ private Secret.Schema? schema = null;
+
public Gallery3Service(GLib.File resource_directory) {
if (icon_pixbuf_set == null)
icon_pixbuf_set = Resources.load_from_resource
(Resources.RESOURCE_PATH + "/" + ICON_FILENAME);
+
}
public int get_pluggable_interface(int min_host_interface,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]