3 This file is part of libmspgltk
4 Copyright © 2007 Mikko Rasa, Mikkosoft Productions
5 Distributed under the LGPL
14 Button::Button(const Resources &r, const std::string &t):
22 void Button::set_text(const std::string &t)
27 void Button::button_press(int, int, unsigned btn)
36 void Button::button_release(int x, int y, unsigned btn)
40 if(geom.is_inside_relative(x, y))
41 signal_clicked.emit();
48 void Button::pointer_leave()
50 Widget::pointer_leave();
54 void Button::render_special(const Part &part) const
56 if(part.get_name()=="text")
57 render_text(part, text);
61 Button::Loader::Loader(Button &btn):
64 add("text", &Button::text);
67 Button &Button::Loader::get_object() const
69 return static_cast<Button &>(wdg);