home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / ool_main.zip / ool / samples / sample1 / sample1.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-01-25  |  1.3 KB  |  43 lines

  1. /* sample1 i a simple text-editor which uses the sytem-multiline-entryfield */
  2. /* to edit the text.                                                        */
  3. /* sample1 shows you how to                                                 */
  4. /* - create multithraeded programms                                         */
  5. /* - use menubars                                                           */
  6. /* - use the xfile-class                                                    */
  7. /* - accept drag-events                                                     */
  8. /* - use the system defined filedialog                                      */
  9.  
  10. #include "resource.h"      //include definitionf for resources
  11.  
  12. #define MY_MLE     300     //id for the mle-control
  13.  
  14.  
  15. #define INCL_OOL_WIN
  16. #define INCL_OOL_FILE
  17. #include "ool.h"
  18.  
  19. class SearchDialog;
  20.  
  21. /* the derived framewindow */
  22. class MyAppWindow: public XFrameWindow
  23. {
  24.       friend class MyMLE;
  25.       friend class SearchDialog;
  26.    public:
  27.       MyAppWindow( ULONG );
  28.       ~MyAppWindow();
  29.       BOOL DoCommand( LONG );                //overridden
  30.       BOOL QueryForClose ( void );           //overriden
  31.       BOOL LoadFile( char*);
  32.       BOOL SaveFile(void);
  33.    private:
  34.       XMenuBar * menu;
  35.       XMultiLineEdit * mle;
  36.       BOOL saved;
  37.       BOOL loaded;
  38.       XString path;
  39.       BOOL loading;
  40.       SearchDialog * dlg;
  41. };
  42.  
  43.