mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-01 17:15:28 +00:00
draft link parser
This commit is contained in:
parent
454feaeba5
commit
860f76ce49
7 changed files with 147 additions and 13 deletions
|
|
@ -4,6 +4,7 @@ mod text;
|
|||
use text::Text;
|
||||
|
||||
use gtk::{
|
||||
glib::Uri,
|
||||
prelude::{BoxExt, WidgetExt},
|
||||
Box, Orientation,
|
||||
};
|
||||
|
|
@ -29,7 +30,7 @@ impl Content {
|
|||
}
|
||||
|
||||
// Actions
|
||||
pub fn reset(&self, mime: Mime, data: &str) {
|
||||
pub fn reset(&self, mime: Mime, base: &Uri, data: &str) {
|
||||
// Cleanup
|
||||
while let Some(child) = self.widget.last_child() {
|
||||
self.widget.remove(&child)
|
||||
|
|
@ -38,7 +39,7 @@ impl Content {
|
|||
// Compose
|
||||
match mime {
|
||||
Mime::TextGemini => {
|
||||
self.widget.append(Text::gemini(data).widget());
|
||||
self.widget.append(Text::gemini(data, base).widget());
|
||||
}
|
||||
Mime::TextPlain => {
|
||||
todo!()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue