X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;ds=sidebyside;f=otk%2Fbutton.cc;h=fd23a5698d74d54ff15851df3c25255834459025;hb=9860b76c50e5ecacc85921539058eab4c655c38d;hp=8dea882e461c41b07405be9f6d4f868a27242882;hpb=4d1a90b0d22927c7a4cba0f347bb39c868204bc6;p=chaz%2Fopenbox diff --git a/otk/button.cc b/otk/button.cc index 8dea882e..fd23a569 100644 --- a/otk/button.cc +++ b/otk/button.cc @@ -12,15 +12,24 @@ OtkButton::OtkButton(OtkWidget *parent) : OtkFocusLabel(parent), _pressed(false), _pressed_focus_tx(0), _pressed_unfocus_tx(0), _unpr_focus_tx(0), _unpr_unfocus_tx(0) { + setStyle(getStyle()); +} + +OtkButton::~OtkButton() +{ +} + + +void OtkButton::setStyle(Style *style) +{ + OtkFocusLabel::setStyle(style); + setTexture(getStyle()->getButtonFocus()); setUnfocusTexture(getStyle()->getButtonUnfocus()); _pressed_focus_tx = getStyle()->getButtonPressedFocus(); _pressed_unfocus_tx = getStyle()->getButtonPressedUnfocus(); } -OtkButton::~OtkButton() -{ -} void OtkButton::press(unsigned int mouse_button) {