stdui.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifdef HAVE_CONFIG_H
00023 #include <config.h>
00024 #endif
00025
00026 #include <iostream>
00027 #include <cstdlib>
00028 #include <stdui.h>
00029 #include <stdobject.h>
00030
00031
00032 using namespace std;
00033
00034 bool destroy_notify( stdui::stdobject* o)
00035 {
00036 cerr << "object named:[" << o->name() << "] in destructor state..." << endl;
00037 return true;
00038 }
00039
00040 int main(int argc, char *argv[])
00041 {
00042 cout << "Hello, world!" << endl;
00043 stdui::stdobject * object = new stdui::stdobject(0l,"stdobject test");
00044
00045
00046 (void)object->destroy_delegate( sigc::ptr_fun(&destroy_notify) );
00047 cerr << "a stdobject is created, and one destroy delegate has been connected..." << endl;
00048 sleep(2);
00049 cerr << "now deleting the object and see if the delegate function is called ..." << endl;
00050 delete object;
00051
00052 return EXIT_SUCCESS;
00053 }
API Documentation Generated by:
1.4.0
About the author |

Site started with trial version of DreamWeaver MX 2004 |
Finalizing with

|
Contact | ©2005, Serge Lussier ( Bretzel )