X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fbutton.h;h=962b2e11908e0608b2ced7133274a0d0e648ec59;hb=81c4024fb6acf37df702a803dc4efdf82a81525a;hp=844fe88c30fe786d9c460030f35a87ad11f78a10;hpb=1597579a34a8d87d4dea0a0cdc0895e6247b6126;p=libs%2Fgltk.git diff --git a/source/button.h b/source/button.h index 844fe88..962b2e1 100644 --- a/source/button.h +++ b/source/button.h @@ -3,6 +3,7 @@ #include #include +#include "mspgltk_api.h" #include "text.h" #include "widget.h" @@ -13,10 +14,10 @@ namespace GLtk { A clickable button widget. Buttons can have a text label, which is displayed in a spacial part "text". */ -class Button: public Widget +class MSPGLTK_API Button: public Widget { public: - class Loader: public DataFile::DerivedObjectLoader + class MSPGLTK_API Loader: public DataFile::DerivedObjectLoader { public: Loader(Button &); @@ -28,8 +29,8 @@ public: private: Text text; - const GL::Texture2D *icon; - bool pressed; + const GL::Texture2D *icon = nullptr; + bool pressed = false; public: Button(const std::string & = std::string());