/[enigma]/enigma/src/gui.hh
ViewVC logotype

Diff of /enigma/src/gui.hh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.7 by dheck, Thu Jun 19 22:19:18 2003 UTC revision 1.8 by reallysoft, Sun Jun 22 08:12:07 2003 UTC
# Line 104  namespace gui Line 104  namespace gui
104      class Container : public Widget {      class Container : public Widget {
105      public:      public:
106          Container() {}          Container() {}
107          ~Container();          virtual ~Container();
108    
109          void add_child (Widget *w);          void add_child (Widget *w);
110          void redraw_child (Widget *w, const px::Rect &r);          void redraw_child (Widget *w, const px::Rect &r);
111    
# Line 131  namespace gui Line 132  namespace gui
132      public:      public:
133          void set_spacing (int pixels);          void set_spacing (int pixels);
134      protected:      protected:
135          List(int spacing=5) : m_spacing(spacing)          List(int spacing=5) : m_spacing(spacing) {}
136          {}          virtual ~List() {}
137      private:      private:
138          int m_spacing;          // # of pixels between container items          int m_spacing;          // # of pixels between container items
139      };      };
# Line 175  namespace gui Line 176  namespace gui
176      class Label : public Widget {      class Label : public Widget {
177      public:      public:
178          Label (const std::string &text);          Label (const std::string &text);
179            
180          // Widget interface          // Widget interface
181          void draw (px::GC &gc, const px::Rect &r);          void draw (px::GC &gc, const px::Rect &r);
182    
# Line 193  namespace gui Line 194  namespace gui
194      class Button : public Widget {      class Button : public Widget {
195      protected:      protected:
196          Button() : highlighted(false) {}          Button() : highlighted(false) {}
197            virtual ~Button() {}
198    
199          void draw(px::GC &gc, const px::Rect &r);          void draw(px::GC &gc, const px::Rect &r);
200      protected:      protected:
# Line 208  namespace gui Line 210  namespace gui
210      class PushButton : public Button {      class PushButton : public Button {
211      public:      public:
212          PushButton();          PushButton();
213            virtual ~PushButton() {}
214    
215          bool is_pressed() { return pressed; }          bool is_pressed() { return pressed; }
216      protected:      protected:
217          bool on_event(const SDL_Event &e);          bool on_event(const SDL_Event &e);
# Line 222  namespace gui Line 226  namespace gui
226      class TextButton : public PushButton {      class TextButton : public PushButton {
227      public:      public:
228          TextButton(const std::string &t, ActionListener *al=0);          TextButton(const std::string &t, ActionListener *al=0);
229            virtual ~TextButton() {}
230    
231          void set_text(const std::string &t);          void set_text(const std::string &t);
232      private:      private:
233          // Widget interface.          // Widget interface.
# Line 240  namespace gui Line 246  namespace gui
246      public:      public:
247          ImageButton(const std::string &unselected,          ImageButton(const std::string &unselected,
248                      const std::string &selected,                      const std::string &selected,
249                      ActionListener *al=0);                      ActionListener    *al = 0);
250            virtual ~ImageButton() {}
251      private:      private:
252          // Widget interface.          // Widget interface.
253          void draw(px::GC &gc, const px::Rect &r);          void        draw(px::GC &gc, const px::Rect &r);
254          std::string fname_sel, fname_unsel;          std::string fname_sel, fname_unsel;
255      };      };
256    

Legend:
Removed from v.1.7  
changed lines
  Added in v.1.8

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26