main.h
上传用户:hzhsqp
上传日期:2007-01-06
资源大小:1600k
文件大小:2k
- /*
- * main.h
- *
- * PWLib application header file for $$PRODUCT_NAME$$
- *
- * Copyright $$YEAR$$ $$MANUFACTURER$$
- *
- * $Log$
- */
- #ifndef _$$APP_CLASS_NAME$$_MAIN_H
- #define _$$APP_CLASS_NAME$$_MAIN_H
- $$IF(IS_SERVICE)
- $$IF(HAS_HTTP)
- #include <ptclib/httpsvc.h>
- $$ELSE
- #include <ptlib/svcproc.h>
- $$ENDIF
- $$ENDIF
- $$IF(IS_GUI)
- class MainWindow : public $$PARENT_WIN_CLASS$$
- {
- PCLASSINFO(MainWindow, $$PARENT_WIN_CLASS$$)
-
- public:
- MainWindow(PArgList & args);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, NewCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, OpenCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, CloseCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, SaveCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, SaveAsCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, PrintCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, PrinterSetupCmd);
- PDECLARE_NOTIFIER(PMenuItem, MainWindow, ExitCmd);
- PDECLARE_COMMAND_ENABLE("Copy", MainWindow, CopyCmd, CanCopy);
- PDECLARE_COMMAND_ENABLE("Copy", MainWindow, PasteCmd, CanPaste);
- private:
- PPrintInfo printInfo;
- };
- $$ENDIF
- class $$APP_CLASS_NAME$$ : public $$PARENT_APP_CLASS$$
- {
- PCLASSINFO($$APP_CLASS_NAME$$, $$PARENT_APP_CLASS$$)
- public:
- $$APP_CLASS_NAME$$();
- void Main();
- $$IF(IS_SERVICE)
- const char * GetServiceDependencies() const;
- BOOL OnStart();
- void OnStop();
- BOOL OnPause();
- void OnContinue();
- void OnControl();
- $$IF(HAS_HTTP)
- void OnConfigChanged();
- PString GetPageGraphic();
- void AddUnregisteredText(PHTML & html);
- $$ENDIF
- BOOL Initialise(const char * initMsg);
- $$ENDIF
- };
- #endif // _$$APP_CLASS_NAME$$_MAIN_H
- // End of File ///////////////////////////////////////////////////////////////