mirror of
https://github.com/YGGverse/Yoda.git
synced 2025-03-10 12:41:34 +00:00
hide pin widget by argument
This commit is contained in:
parent
3d33be7e24
commit
77303d548e
@ -6,17 +6,25 @@ use gtk::prelude::BoxExt;
|
|||||||
|
|
||||||
pub fn new() -> Box
|
pub fn new() -> Box
|
||||||
{
|
{
|
||||||
let label = Box::builder().orientation(
|
let label = Box::builder()
|
||||||
gtk::Orientation::Horizontal
|
|
||||||
).build();
|
|
||||||
|
|
||||||
label.append(
|
// Tuneup
|
||||||
&pin::new()
|
.orientation(
|
||||||
);
|
gtk::Orientation::Horizontal
|
||||||
|
)
|
||||||
|
|
||||||
label.append(
|
.build();
|
||||||
&title::new()
|
|
||||||
);
|
// Components
|
||||||
|
label.append(
|
||||||
|
&pin::new(
|
||||||
|
false
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
label.append(
|
||||||
|
&title::new()
|
||||||
|
);
|
||||||
|
|
||||||
return label;
|
return label;
|
||||||
}
|
}
|
@ -1,10 +1,18 @@
|
|||||||
use gtk::Image;
|
use gtk::Image;
|
||||||
|
|
||||||
pub fn new() -> Image
|
pub fn new(
|
||||||
|
visible : bool
|
||||||
|
) -> Image
|
||||||
{
|
{
|
||||||
let pin = Image::builder().icon_name(
|
return Image::builder()
|
||||||
"view-pin-symbolic"
|
|
||||||
).build();
|
|
||||||
|
|
||||||
return pin;
|
.icon_name(
|
||||||
|
"view-pin-symbolic"
|
||||||
|
)
|
||||||
|
|
||||||
|
.visible(
|
||||||
|
visible
|
||||||
|
)
|
||||||
|
|
||||||
|
.build();
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user