home *** CD-ROM | disk | FTP | other *** search
- /*
- * TextField autoinit and autoterminate functions
- * for SAS/C 6.50 and up.
- *
- * If you just compile and link this into your application
- * then TextFieldBase and TextFieldClass will be
- * automatically initialized before main() is called.
- *
- * Your application will only need to use TextFieldClass
- * when calling NewObject() and include <proto/textfield.h>.
- */
-
- #include <exec/types.h>
- #include <intuition/classes.h>
-
- #include <proto/exec.h>
- #include <proto/textfield.h>
-
- struct Library *TextFieldBase;
- Class *TextFieldClass;
-
- int _STI_200_TextFieldInit(void)
- {
- TextFieldBase = OpenLibrary("gadgets/textfield.gadget", 0);
- if (TextFieldBase) {
- TextFieldClass = TEXTFIELD_GetClass();
- return 0;
- } else {
- return 1;
- }
- }
-
- void _STD_200_TextFieldTerm(void)
- {
- CloseLibrary(TextFieldBase);
- TextFieldClass = NULL;
- TextFieldBase = NULL;
- }
-