From 76d3460fa14973dff6612c230463abad35cac321 Mon Sep 17 00:00:00 2001 From: kodjomoustapha <107993382+kodjodevf@users.noreply.github.com> Date: Tue, 14 Nov 2023 09:58:38 +0100 Subject: [PATCH] Update --- README.md | 5 +++-- native/hub/src/imagecrop.rs | 22 ++++++++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index cb059eb..ddc92e9 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ Mangayomi is free an open source manga reader and anime streaming cross-platefor ## Features Features include: -* [Supports external sources](https://github.com/kodjodevf/mangayomi-extensions) +* [Supports external sources](https://github.com/kodjodevf/mangayomi-extensions), utilizing the capabilities of the [dart_eval](https://pub.dev/packages/dart_eval) package * Online reading from a variety of sources * Watch anime from a variety of sources * Local reading of downloaded content @@ -52,7 +52,7 @@ Get the app from our [releases page](https://github.com/kodjodevf/mangayomi/rele ## Using Rust Inside Flutter -This project leverages Flutter for GUI and Rust for the backend logic, +This project use Rust for the [auto-image-cropper](https://github.com/ritiek/auto-image-cropper) crate, utilizing the capabilities of the [Rinf](https://pub.dev/packages/rinf) framework. @@ -94,6 +94,7 @@ flutter run For detailed instructions on writing Rust and Flutter together, please refer to Rinf's [documentation](https://rinf-docs.cunarist.com). + ## License Copyright 2023 Moustapha Kodjo Amadou diff --git a/native/hub/src/imagecrop.rs b/native/hub/src/imagecrop.rs index 95c5846..7edf15f 100644 --- a/native/hub/src/imagecrop.rs +++ b/native/hub/src/imagecrop.rs @@ -1,7 +1,29 @@ +/* MIT License +Copyright (c) 2017 Ritiek Malhotra + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE.*/ + use crate::bridge::api::{RustOperation, RustRequest, RustResponse}; use image::{DynamicImage, GenericImageView, ImageOutputFormat, ImageResult, Rgba}; use prost::Message; use std::io::Cursor; + pub struct Point { pub x: u32, pub y: u32,