]> git.tdb.fi Git - libs/gltk.git/blobdiff - source/dropdown.cpp
Simplify constructors with C++11
[libs/gltk.git] / source / dropdown.cpp
index ef0fa22f97c8f150009988b3487c716b1e576cf2..68c1beed1321fea803981b36701246576273a397 100644 (file)
@@ -27,8 +27,6 @@ void Dropdown::init()
 {
        input_type = INPUT_NAVIGATION;
 
-       dropped = false;
-
        add(list);
        list.set_visible(false);
        list.set_view_all();
@@ -108,7 +106,7 @@ bool Dropdown::navigate(Navigation nav)
        return true;
 }
 
-void Dropdown::on_geometry_change()
+void Dropdown::on_size_change()
 {
        if(dropped)
                resize_list();
@@ -191,7 +189,7 @@ void Dropdown::list_item_selected(unsigned index)
        text.set(list.get_data().get_string(index));
 
        signal_item_selected.emit(index);
-       rebuild();
+       mark_rebuild();
 }
 
 void Dropdown::list_selection_cleared()