Update of /cvsroot/plib/plib/src/puAux
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1453
Modified Files:
puAux.h
Log Message:
Adding a new list box widget to the puAux library
Index: puAux.h
===================================================================
RCS file: /cvsroot/plib/plib/src/puAux/puAux.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- puAux.h 6 May 2005 18:54:08 -0000 1.5
+++ puAux.h 6 May 2005 19:00:35 -0000 1.6
@@ -42,6 +42,7 @@
#define PUCLASS_SLIDERWITHINPUT 0x04000000
#define PUCLASS_COMPASS 0x08000000
#define PUCLASS_CHOOSER 0x10000000
+#define PUCLASS_LIST 0x20000000
// Widget Declarations
@@ -58,6 +59,7 @@
class puaCompass ;
class puaSliderWithInput ;
class puaChooser ;
+class puaList ;
// A File selector widget
@@ -834,6 +836,36 @@
static void menuCleanup ( puObject * ) ;
} ;
+/**
+ * A scrolling list for PUI.
+ *
+ * Believe it or not, PUI does not have one of these.
+ */
+class puaList : public puGroup
+{
+ UL_TYPE_DATA
+
+ char ** _contents;
+ puFrame * _frame;
+ puListBox * _list_box;
+ puSlider * _slider;
+ puArrowButton * _up_arrow;
+ puArrowButton * _down_arrow;
+
+protected:
+ virtual void init (int w, int h);
+
+public:
+ puaList (int x, int y, int w, int h);
+ puaList (int x, int y, int w, int h, char ** contents);
+ virtual ~puaList ();
+
+ virtual void newList (char ** contents);
+ // TODO: other string value funcs
+ virtual char * getListStringValue ();
+ virtual int getListIntegerValue();
+};
+
#endif
|