From 62263e0e619625f2c5dd0b4364b43bd4fefc8ccd Mon Sep 17 00:00:00 2001 From: Vika Date: Thu, 30 Jan 2025 08:49:22 +0300 Subject: libsecret: 0.6.0 (private fork) -> 0.7.0 (upstream) libsecret is now maintained again! No need for a private fork. --- libsecret/src/enums.rs | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 libsecret/src/enums.rs (limited to 'libsecret/src/enums.rs') diff --git a/libsecret/src/enums.rs b/libsecret/src/enums.rs deleted file mode 100644 index 59de400..0000000 --- a/libsecret/src/enums.rs +++ /dev/null @@ -1,25 +0,0 @@ -use glib::error::ErrorDomain; -use glib::translate::*; - -use crate::Error; - -impl ErrorDomain for Error { - fn domain() -> glib::Quark { - unsafe { from_glib(ffi::secret_error_get_quark()) } - } - - fn code(self) -> i32 { - self.into_glib() - } - - fn from(code: i32) -> Option { - match code { - ffi::SECRET_ERROR_PROTOCOL => Some(Self::Protocol), - ffi::SECRET_ERROR_IS_LOCKED => Some(Self::IsLocked), - ffi::SECRET_ERROR_NO_SUCH_OBJECT => Some(Self::NoSuchObject), - ffi::SECRET_ERROR_ALREADY_EXISTS => Some(Self::AlreadyExists), - ffi::SECRET_ERROR_INVALID_FILE_FORMAT => Some(Self::InvalidFileFormat), - value => Some(Self::__Unknown(value)), - } - } -} -- cgit 1.4.1