hook up popover button signals
This commit is contained in:
parent
1fa7b8243a
commit
36d317a3e3
3 changed files with 33 additions and 10 deletions
|
|
@ -198,9 +198,18 @@ impl GroupGrid {
|
|||
.connect_local("new-group", false, glib::clone!(@weak self_ => @default-return None, move |args| {
|
||||
let m = self_.group_model();
|
||||
match args[1].get::<String>() {
|
||||
Ok(_name) => {
|
||||
// m.items_changed(m.n_items() - 2, 0, 1);
|
||||
todo!();
|
||||
Ok(name) => {
|
||||
let new_group = AppGroup::new(BoxedAppGroupType::Group(AppGroupData {
|
||||
id: 0,
|
||||
name: name,
|
||||
icon: "folder".to_string(),
|
||||
mutable: false,
|
||||
app_names: Vec::new(),
|
||||
category: "".to_string(),
|
||||
})).upcast::<Object>();
|
||||
|
||||
m.insert(m.n_items() - 1, &new_group);
|
||||
self_.store_data();
|
||||
}
|
||||
_ => unimplemented!(),
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue