cargo: Update glycin
This commit is contained in:
parent
3f3f366819
commit
0811a14198
4 changed files with 7 additions and 7 deletions
4
Cargo.lock
generated
4
Cargo.lock
generated
|
|
@ -1024,7 +1024,7 @@ dependencies = [
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "glycin"
|
name = "glycin"
|
||||||
version = "2.0.0-alpha"
|
version = "2.0.0-alpha"
|
||||||
source = "git+https://gitlab.gnome.org/sophie-h/glycin#4b0759839322fad9277c7f823438abe4937e4027"
|
source = "git+https://gitlab.gnome.org/sophie-h/glycin#590eb454995a2d7913e9f34053d272ab9d1a0e07"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"async-fs",
|
"async-fs",
|
||||||
"async-io",
|
"async-io",
|
||||||
|
|
@ -1055,7 +1055,7 @@ dependencies = [
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "glycin-utils"
|
name = "glycin-utils"
|
||||||
version = "2.0.0-alpha"
|
version = "2.0.0-alpha"
|
||||||
source = "git+https://gitlab.gnome.org/sophie-h/glycin#4b0759839322fad9277c7f823438abe4937e4027"
|
source = "git+https://gitlab.gnome.org/sophie-h/glycin#590eb454995a2d7913e9f34053d272ab9d1a0e07"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"env_logger",
|
"env_logger",
|
||||||
"gufo-common",
|
"gufo-common",
|
||||||
|
|
|
||||||
|
|
@ -77,13 +77,13 @@ impl UpdateSender {
|
||||||
/// Send occurring errors to renderer
|
/// Send occurring errors to renderer
|
||||||
pub fn spawn_error_handled<F>(&self, f: F) -> glib::JoinHandle<()>
|
pub fn spawn_error_handled<F>(&self, f: F) -> glib::JoinHandle<()>
|
||||||
where
|
where
|
||||||
F: std::future::Future<Output = Result<(), glycin::Error>> + Send + 'static,
|
F: std::future::Future<Output = Result<(), glycin::ErrorCtx>> + Send + 'static,
|
||||||
{
|
{
|
||||||
let update_sender = self.clone();
|
let update_sender = self.clone();
|
||||||
glib::spawn_future(async move {
|
glib::spawn_future(async move {
|
||||||
let update_sender = update_sender.clone();
|
let update_sender = update_sender.clone();
|
||||||
|
|
||||||
let result: Result<(), glycin::Error> = f.await;
|
let result: Result<(), glycin::ErrorCtx> = f.await;
|
||||||
|
|
||||||
if let Err(err) = result {
|
if let Err(err) = result {
|
||||||
if err.unsupported_format().is_some() {
|
if err.unsupported_format().is_some() {
|
||||||
|
|
|
||||||
|
|
@ -210,7 +210,7 @@ impl LpImagePage {
|
||||||
let image = self.image();
|
let image = self.image();
|
||||||
|
|
||||||
if image.is_unsupported() {
|
if image.is_unsupported() {
|
||||||
let message = if glycin::supported_loader_mime_types().await.is_empty() {
|
let message = if glycin::Loader::supported_mime_types().await.is_empty() {
|
||||||
// Translators: {} is replace with a version number
|
// Translators: {} is replace with a version number
|
||||||
gettext_f(
|
gettext_f(
|
||||||
"No image loaders available. Maybe the “glycin-loaders” package with compatibility version “{}+” is not installed.",
|
"No image loaders available. Maybe the “glycin-loaders” package with compatibility version “{}+” is not installed.",
|
||||||
|
|
@ -220,7 +220,7 @@ impl LpImagePage {
|
||||||
let content_type = gio::content_type_from_mime_type(&mime_type).unwrap_or_default();
|
let content_type = gio::content_type_from_mime_type(&mime_type).unwrap_or_default();
|
||||||
let description = gio::content_type_get_description(&content_type).to_string();
|
let description = gio::content_type_get_description(&content_type).to_string();
|
||||||
|
|
||||||
if glycin::DEFAULT_MIME_TYPES.contains(&mime_type.as_str()) {
|
if glycin::Loader::DEFAULT_MIME_TYPES.contains(&mime_type.as_str()) {
|
||||||
// Translators: The first occurance of {} is replace with a description of the
|
// Translators: The first occurance of {} is replace with a description of the
|
||||||
// format and the second with an id (mime-type) of the format.
|
// format and the second with an id (mime-type) of the format.
|
||||||
gettext_f(
|
gettext_f(
|
||||||
|
|
|
||||||
|
|
@ -513,7 +513,7 @@ impl LpWindow {
|
||||||
|
|
||||||
let filter_supported_formats = gtk::FileFilter::new();
|
let filter_supported_formats = gtk::FileFilter::new();
|
||||||
filter_supported_formats.set_name(Some(&gettext("Supported image formats")));
|
filter_supported_formats.set_name(Some(&gettext("Supported image formats")));
|
||||||
for mime_type in glycin::supported_loader_mime_types().await {
|
for mime_type in glycin::Loader::supported_mime_types().await {
|
||||||
filter_supported_formats.add_mime_type(mime_type.as_str());
|
filter_supported_formats.add_mime_type(mime_type.as_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue