{ TDialog::SetupWindow(); SendDlgItemMessage(HWindow, ID_INPUT, EM_LIMITTEXT, BufferSize - 1, 0); } /* Reads an instance of TInputDialog from the passed ipstream. */ void *TInputDialog::read(ipstream& is) { TDialog::read(is); Prompt = is.freadString(); return this; } /* Writes the TInputDialog to the passed opstream. */ void TInputDialog::write(opstream& os) { TDialog::write(os); os.fwriteString(Prompt); } TStreamable *TInputDialog::build() { return new TInputDialog(streamableInit); } TStreamableClass RegInputDialog("TInputDialog", TInputDialog::build, __DELTA(TInputDialog));
// ObjectWindows - (C) Copyright 1992 by Borland International /* -------------------------------------------------------- BRADIO.CPP Defines type TBRadioButton. This defines the basic behavior for all Borland custom radio buttons. -------------------------------------------------------- */ #include "bradio.h" #include "groupbox.h" /* Constructor for a TBRadioButton object. */ TBRadioButton::TBRadioButton(PTWindowsObject AParent, int AnId, LPSTR ATitle, int X, int Y, int W, int H, PTGroupBox AGroup, PTModule AModule) : TRadioButton(AParent, AnId, ATitle, X, Y, W, H, AGroup, AModule) {} PTStreamable TBRadioButton::build() { return new TBRadioButton(streamableInit); } TStreamableClass RegBRadioButton("TBRadioButton", TBRadioButton::build, __DELTA(TBRadioButton));
farfree(ClientAttr); } /* Reads an instance of TMDIClient from the passed ipstream. */ void *TMDIClient::read(ipstream& is) { TWindow::read(is); ClientAttr = (LPCLIENTCREATESTRUCT)farmalloc(sizeof(CLIENTCREATESTRUCT)); WORD idFirstChild = ClientAttr->idFirstChild; // prevent compiler warning is >> idFirstChild; ClientAttr->hWindowMenu = (HMENU)0; Attr.Param = (LPSTR)ClientAttr; return this; } /* Writes the TMDIClient to the passed opstream. */ void TMDIClient::write(opstream& os) { TWindow::write(os); os << ClientAttr->idFirstChild; } TStreamable *TMDIClient::build() { return new TMDIClient(streamableInit); } TStreamableClass RegMDIClient("TMDIClient", TMDIClient::build, __DELTA(TMDIClient));
{ TWindow::read(is); GetChildPtr(is, (PTWindowsObject)ActiveChild); is >> ClientWnd; if ( ClientWnd ) ClientWnd->Parent = this; is >> ChildMenuPos; return this; } /* Writes the TMDIFrame to the passed opstream. */ void TMDIFrame::write(opstream& os) { TWindow::write(os); PutChildPtr(os, ActiveChild); os << ClientWnd; os << ChildMenuPos; } TStreamable *TMDIFrame::build() { return new TMDIFrame(streamableInit); } TStreamableClass RegMDIFrame("TMDIFrame", TMDIFrame::build, __DELTA(TMDIFrame));
void TCheckBox::BNClicked(TMessage& Msg) { DefWndProc(Msg); if ( Group ) Group->SelectionChanged(Attr.Id); DefNotificationProc(Msg); } /* Reads an instance of TCheckBox from the passed ipstream. */ void *TCheckBox::read(ipstream& is) { TWindow::read(is); GetSiblingPtr(is, (PTWindowsObject)Group); return this; } /* Writes the TCheckBox to the passed opstream. */ void TCheckBox::write(opstream& os) { TWindow::write(os); PutSiblingPtr(os, Group); } TStreamable *TCheckBox::build() { return new TCheckBox(streamableInit); } TStreamableClass RegCheckBox("TCheckBox", TCheckBox::build, __DELTA(TCheckBox));