Category : Files from Magazines
Archive   : NOV92_1.ZIP
Filename : CPPLIB.ASC

 
Output of file : CPPLIB.ASC contained in archive : NOV92_1.ZIP
_DEVELOPING A PORTABLE C++ GUI CLASS LIBRARY_
by Andreas Meyer

Example 1:

class MyDialog : public ModalDialog
{
protected:
DefPushButton aOkButton;
public:
MyDialog( Window* pParent );
void QuitDialog( DefPushButton* pButton );
}

MyDialog::MyDialog( Window* pParent ) :
ModalDialog( pParent ),
aOkButton( this )
{
aOkButton.ChangeClickHdl( LINK( this, MyDialog::QuitDialog ) );
}

void MyDialog::QuitDialog( DefPushButton* pButton )
{
if( ... ) // check dialog state
ModalDialog::EndDialog();
}



Example 2:


(a)

class Object
{
Object GetNext();
}
if( bTest && ( aObj.GetNext() == aObj ) ) ...

(b)

Obj aNext = aObj.GetNext();
if( bTest && ( aNext == aObj ) ) ...


Example 3:

(a)

#define CONCAT( a, b ) a##b
CONCAT( A, B ) // this will throw an error

(b)

#define CONCAT( a, b ) a/**/b



Example 4:

class Base
{
~Base() { foo(); }
virtual foo();
}
class Derived : public Base
{
virtual foo();
}



  3 Responses to “Category : Files from Magazines
Archive   : NOV92_1.ZIP
Filename : CPPLIB.ASC

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/