]> git.tdb.fi Git - libs/gltk.git/blobdiff - source/toggle.cpp
Make the Text class interface more obvious by not using a reference to pointer
[libs/gltk.git] / source / toggle.cpp
index 62f46eb52ac94b0ac212535c720a82937c45b13c..d31ff9f320faac8b4f081c369366003684c64c25 100644 (file)
@@ -16,7 +16,7 @@ namespace GLtk {
 
 Toggle::Toggle(const Resources &r, const string &t):
        Widget(r),
-       text(style),
+       text(),
        pressed(false),
        value(false),
        exclusive(false)
@@ -87,7 +87,7 @@ void Toggle::exclude_siblings()
 
 void Toggle::on_style_change()
 {
-       text.update_style();
+       text.set_style(style);
 }