mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-01 09:05:27 +00:00
remove extra getters
This commit is contained in:
parent
649d8f92f6
commit
3ce272cd70
7 changed files with 48 additions and 112 deletions
|
|
@ -13,7 +13,7 @@ use std::rc::Rc;
|
|||
|
||||
// Main
|
||||
pub struct Request {
|
||||
widget: Rc<Widget>,
|
||||
pub widget: Rc<Widget>,
|
||||
}
|
||||
|
||||
impl Request {
|
||||
|
|
@ -90,12 +90,8 @@ impl Request {
|
|||
|
||||
// Getters
|
||||
|
||||
pub fn widget(&self) -> &Rc<Widget> {
|
||||
&self.widget
|
||||
}
|
||||
|
||||
pub fn uri(&self) -> Option<Uri> {
|
||||
match Uri::parse(&self.widget.gobject().text(), UriFlags::NONE) {
|
||||
match Uri::parse(&self.widget.entry.text(), UriFlags::NONE) {
|
||||
Ok(uri) => Some(uri),
|
||||
_ => None,
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue