锘??xml version="1.0" encoding="utf-8" standalone="yes"?>99久久综合狠狠综合久久,精品久久久无码中文字幕天天,国产成人久久精品区一区二区http://www.shnenglu.com/einz/category/9162.htmlzh-cnFri, 17 Jul 2009 22:44:36 GMTFri, 17 Jul 2009 22:44:36 GMT60OnClosehttp://www.shnenglu.com/einz/articles/71351.htmlEiNEiNTue, 06 Jan 2009 08:26:00 GMThttp://www.shnenglu.com/einz/articles/71351.htmlhttp://www.shnenglu.com/einz/comments/71351.htmlhttp://www.shnenglu.com/einz/articles/71351.html#Feedback0http://www.shnenglu.com/einz/comments/commentRss/71351.htmlhttp://www.shnenglu.com/einz/services/trackbacks/71351.html
enum TCloseAction { caNone, caHide, caFree, caMinimize };
typedef void __fastcall (__closure *TCloseEvent)(System::TObject* Sender, TCloseAction &Action);
__property TCloseEvent OnClose = {read=FOnClose, write=FOnClose, stored=IsForm};

Description

Use OnClose to perform special processing when the form closes. The OnClose event specifies which event handler to call when a form is about to close. The handler specified by OnClose might, for example, test to make sure all fields in a data-entry form have valid contents before allowing the form to close.

A form is closed by the Close method or when the user chooses Close from the form's system menu.

The TCloseEvent type points to a method that handles the closing of a form. The value of the Action parameter determines if the form actually closes. These are the possible values of Action:

Value    Meaning

caNone    The form is not allowed to close, so nothing happens.
caHide    The form is not closed, but just hidden. Your application can still access a hidden form.
caFree    The form is closed and all allocated memory for the form is freed.
caMinimize    The form is minimized, rather than closed. This is the default action for MDI child forms.

If a form is an MDI child form, and its BorderIcons property is biMinimize, then the default Action is caMinimize. If a MDI child form does not have these settings, the default Action is caNone, meaning that nothing happens when the user attempts to close the form.

If a form is an SDI child form, Action defaults to caHide.

To close the form and free it in an OnClose event, set Action to caFree.

Note:    When the application shuts down, the main form receives an OnClose event, but any child forms do not receive the OnClose event.


EiN 2009-01-06 16:26 鍙戣〃璇勮
]]>
灝忚鏋勪歡http://www.shnenglu.com/einz/articles/71034.htmlEiNEiNFri, 02 Jan 2009 14:21:00 GMThttp://www.shnenglu.com/einz/articles/71034.htmlhttp://www.shnenglu.com/einz/comments/71034.htmlhttp://www.shnenglu.com/einz/articles/71034.html#Feedback0http://www.shnenglu.com/einz/comments/commentRss/71034.htmlhttp://www.shnenglu.com/einz/services/trackbacks/71034.html鎽樿嚜BCB鐨勪緥瀛?瓚婄湅瓚婃湁鐐硅糠緋?榪樿秺瑙夊緱niubility.鍍忚瀵熻呭張鑲畾涓嶆槸,瀹炲湪鏄墰...

Main.cpp:

//----------------------------------------------------------------------------
//Borland C++Builder
//Copyright (c) 1987, 1998-2002 Borland International Inc. All Rights Reserved.
//----------------------------------------------------------------------------
//-------------------------------------------------------------------------
//    minicomp.cpp - uses the TCounter example component
//-------------------------------------------------------------------------
#include "minicomp.h"
#include 
<stdio.h>
#include 
<stdlib.h>
#include 
<condefs.h>
//-------------------------------------------------------------------------
USEUNIT("counter.cpp");
//---------------------------------------------------------------------------
main()
{
  TExample example;

  
return 0;
}
//-------------------------------------------------------------------------
TExample::TExample()
{
  TCounter Counter(
7);
  
int i;
  
//鎶婃帶浠禖ounter鐨勬帴鍙Multiple鍜屽閮ㄥ疄鐜癕ultipleReached榪炴帴涓?/span>
  Counter.OnMultiple = MultipleReached;

  
for (i=0; i < 100; i++)
    Counter.Increment();
}
//-------------------------------------------------------------------------
void TExample::MultipleReached(TCounter *Sender)
{
  printf(
"Multiple=%d reached with val=%d\n", Sender->Multiple, Sender->Val);
}
//-------------------------------------------------------------------------

minicomp.h:

//-------------------------------------------------------------------------
//    minicomp.h - uses the TCounter example component
//-------------------------------------------------------------------------
#include "counter.h"
//-------------------------------------------------------------------------
class TExample
{
private:
  
void MultipleReached(TCounter *Sender);
public:
  TExample();
};
//-------------------------------------------------------------------------

counter.h:

//-------------------------------------------------------------------------
//    counter.h. - example of a small, non-visual counter component
//-------------------------------------------------------------------------
class TCounter;         // forward

typedef 
void (__closure *TCounterEvent)(TCounter *Sender);
//-------------------------------------------------------------------------
class TCounter 
{
private:
  TCounterEvent FOnMultiple; 
//榪欏氨鏄釜鍑芥暟鎺ュ彛
  int FVal;
  
int FMultiple;
public:
  __property 
int Val = {read=FVal, write=FVal};
  __property 
int Multiple = {read=FMultiple};
  __property TCounterEvent OnMultiple 
= {read=FOnMultiple, write=FOnMultiple};
  
void Clear();
  
void Increment();
  TCounter(
int Multiple);
};
//-------------------------------------------------------------------------

counter.cpp:

//-------------------------------------------------------------------------
//    counter.cpp - example of a small, non-visual counter component
//-------------------------------------------------------------------------
#include "counter.h"
//-------------------------------------------------------------------------
TCounter::TCounter(int Multiple)
{
  FMultiple 
= Multiple;
}
//-------------------------------------------------------------------------
void TCounter::Clear()
{
  FVal 
= 0;
}
//-------------------------------------------------------------------------
void TCounter::Increment()
{
  
//榪欏彞鎵ц鏃墮兘鏄閮ㄦ潵璋冪敤鐨?姝ゆ椂OnMultiple宸茬粡鍜屽闈㈤偅涓嚱鏁版帴鍙h繛鎺ヤ笂浜?br>  //涔熷氨鏄皟鐢ㄧ殑鍏跺疄鏄闈㈣繘鏉ョ殑閭d釜鍑芥暟,鎶妕his浼犲嚭鍘?璁╁閮ㄩ偅涓嚱鏁版搷浣?br>  //TExample::MultipleReached(this)
  if (((++FVal) % FMultiple) == 0)
      OnMultiple(
this);
}
//-------------------------------------------------------------------------



EiN 2009-01-02 22:21 鍙戣〃璇勮
]]>
New Applicationhttp://www.shnenglu.com/einz/articles/70885.htmlEiNEiNWed, 31 Dec 2008 15:10:00 GMThttp://www.shnenglu.com/einz/articles/70885.htmlhttp://www.shnenglu.com/einz/comments/70885.htmlhttp://www.shnenglu.com/einz/articles/70885.html#Feedback0http://www.shnenglu.com/einz/comments/commentRss/70885.htmlhttp://www.shnenglu.com/einz/services/trackbacks/70885.htmlProject1.cpp:

//---------------------------------------------------------------------------

#include 
<vcl.h>
#pragma hdrstop
//---------------------------------------------------------------------------
USEFORM("Unit1.cpp", Form1); //璋冪敤榪欎釜vcl妯″潡,璇﹁Unit1.cpp
//---------------------------------------------------------------------------
//榪欓噷寰堟悶絎?娌$粰鍙傛暟鍚嶉噸鍐?涓嶇煡閬撹繖鏍峰嚱鏁伴噷闈㈣兘涓嶈兘鐢ㄥ埌榪欏嚑涓弬鏁?img src="http://www.shnenglu.com/Images/dot.gif">
//涓嶈繃濂藉儚涔熷氨娌$敤
WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
{
    
try
    {
         Application
->Initialize();
         
//The owner of the new form is the Application object
         
//__classid榪斿洖涓涓寚鍚慣Form1鐨剉table鐨勬寚閽?榪欑偣榪樿鍐嶇湅鐪嬪疄鐜拌繃紼?/span>
         Application->CreateForm(__classid(TForm1), &Form1);
         Application
->Run();
    }
    
catch (Exception &exception)
    {
         Application
->ShowException(&exception);
    }
    
catch ()
    {
         
try
         {
             
throw Exception("");
         }
         
catch (Exception &exception)
         {
             Application
->ShowException(&exception);
         }
    }
    
return 0;
}
//---------------------------------------------------------------------------


Unit1.h:

//---------------------------------------------------------------------------

#ifndef Unit1H
#define Unit1H
//---------------------------------------------------------------------------
//閮藉彧鏄簺澹版槑閮ㄥ垎,鎵浠ュ寘鍚湪澶存枃浠墮噷闈?/span>
#include <Classes.hpp> //TPersistent, TComponent
#include <Controls.hpp> //TControl, TWinControl
#include <StdCtrls.hpp> //TButton
#include <Forms.hpp> //TApplication, TForm
//---------------------------------------------------------------------------
/*

TObject(RTTI,鍨冨溇鍥炴敹絳夋渶鍩烘湰鐨?
    |
    |--TList(stores an array of pointers)
    |
    |--TStream(read and write to some media)
    |   |
    |   |--TFileStream,TStringStream,TWinSocketStrem
    |
    |--TFiler(璇誨啓鎺т歡[objects]灞炴?姣斿淇濆瓨dfm鏂囦歡淇℃伅,鍦ㄥ唴瀛樹腑鏆傚瓨鎺т歡淇℃伅絳?
    |   |
    |   |--TReader
    |   |--TWriter(鍏蜂綋瀹炵幇Filer鍔熻兘)
    |
    |--TPersistent(have assignment and streaming capabilities)
        |
        |--TStrings(for objects that represent a list of strings)
        |   |
        |   |--TStringList(鍏蜂綋瀹炵幇)
        |
        |--TComponent(鎺т歡鐖剁被,鍖呮嫭鍙樉紺哄拰涓嶅彲鏄劇ず)
            |
            |--TApplication(鎶借薄WindowsGUI鐜,娑堟伅鏈哄埗褰撶劧榪樻湁閽堝web鐨勭幆澧?
            |
            |--TControl(鍙鎺т歡)
                |
                |--TWinControl(閽堝Windows鐨勫彲瑙嗘帶浠?
                    |
                    |--TButtonControl(Button鐨勬娊璞?
                    |   |
                    |   |--TButton(Button鐨勫叿浣撳疄鐜?
                    |
                    |--TScrollingWinControl(鏀寔婊氬姩鏉$殑Windows鎺т歡)
                        |
                        |--TCustomForm
                            |
                            |--TForm
*/
//---------------------------------------------------------------------------
class TForm1 : public TForm
{
__published:    
// IDE-managed Components
private:    // User declarations
public:        // User declarations
    __fastcall TForm1(TComponent* Owner); //Owner鏄垱閫犺?Parent鏄憟鐜拌?鍙浜庡彲瑙嗘帶浠?
};
//---------------------------------------------------------------------------
/*

鎶婅繖涓獀cl(Form1)瀵煎嚭,鍏朵粬妯″潡浣跨敤榪欎釜澶存枃浠舵椂灝卞憡璇夌紪璇戝櫒,榪欎釜vcl鍦ㄥ埆澶勫叿浣撳畾涔?br>
*/
extern PACKAGE TForm1 *Form1;
//---------------------------------------------------------------------------
#endif
 

Unit1.cpp:

//---------------------------------------------------------------------------

#include 
<vcl.h>
#pragma hdrstop 
//涔嬪墠鐨勫ご鏂囦歡鍙互浣跨敤澶存枃浠剁紦瀛樻妧鏈?鍏朵粬鍖呭惈vcl.h鐨勭紪璇戝潡灝辯紪璇戜竴嬈?/span>

#include 
"Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource 
"*.dfm"
/*
榪欓噷鐨勭枒闂湪浜?澶存枃浠墮噷闈㈠凡緇忔湁涓涓猠xtern鐨勬寚閽?榪欓噷涓轟綍榪樿鍐嶆鎼炲嚭涓寚閽?
娉ㄦ剰鍦≒roject1.cpp閲岄潰鏈変釜USEFORM鐨勫畯,榪欎釜瀹忕殑鍏蜂綋瀹氫箟鍦╲cl\sysclass.h鏂囦歡涓?br>濡備笅:

#ifdef BCBVER1
  #define USEFORM(FileName, FormName) \
    class DELPHICLASS T##FormName;       \
    extern T##FormName *FormName;
#else
  #define USEFORM(FileName, FormName) \
    class DELPHICLASS T##FormName;       \
    extern PACKAGE T##FormName *FormName;
#endif

鍙互鐪嬪嚭榪欓噷FileName鏍規(guī)湰娌$敤涓?鎵浠?鏃㈢劧緇欎簡cpp涔熷氨緇欎簡.h涔熷氨緇欎簡閭d釜extern鎸囬拡"
鐨勬兂娉曟槸閿欒鐨?cpp鏂囦歡鏍規(guī)湰灝辨病鏈夎搗鍒頒換浣曚綔鐢?榪樻槸瀹屽叏渚濊禆榪炴帴鏃墮潬extern鐨勫瓨鍌?br>灞炴у湪obj閲岄潰鍘繪壘.榪欎篃灝辨槸涓轟粈涔坈pp閲岄潰濡傛灉娌℃湁涓嬮潰榪欎釜鎸囬拡澹版槑,鎶ラ敊鐨勪笉鏄疷nit1
鑰屾槸Project1,鍥犱負(fù)鏄湪Project1璋冪敤浜嗚繖涔堜釜娌℃湁瀹氫箟涓寚閽?榪樻湁涓鐐瑰氨鏄?涔嬫墍浠ヤ細(xì)榪?br>鏍鋒槸鍥犱負(fù).h鏄笉浼?xì)缂栬瘧鐨?Project1鍦║nit1.cpp瀵瑰簲鐨刼bj閲岄潰鍘繪壘,褰撶劧鎵句笉鍒?鎵浠ヨ繖閲?br>蹇呴』瑕佸啀嬈″啓涓婁竴鍙?
*/
TForm1 
*Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
    : TForm(Owner)
{
}
//---------------------------------------------------------------------------
 


EiN 2008-12-31 23:10 鍙戣〃璇勮
]]>
久久久久人妻精品一区三寸蜜桃 | 久久久中文字幕| 青青青伊人色综合久久| 久久91精品综合国产首页| 伊人久久精品影院| 久久久国产精品亚洲一区| 9999国产精品欧美久久久久久| 国产AV影片久久久久久| 久久久久久久久久久| 久久99久久99精品免视看动漫| 国产日韩久久免费影院| 亚洲精品无码久久久久sm| 国产精品免费久久久久影院| 亚洲国产精品成人AV无码久久综合影院 | 久久精品中文无码资源站| 久久av高潮av无码av喷吹| 亚洲AV成人无码久久精品老人| 999久久久无码国产精品| 漂亮人妻被中出中文字幕久久| 狠狠色丁香久久综合婷婷| 亚洲精品无码久久久久去q| 久久久受www免费人成| 久久久久亚洲AV无码永不| 国产欧美久久久精品影院| 国产69精品久久久久99尤物| 久久久久久国产精品无码超碰| 久久狠狠一本精品综合网| 久久99精品国产99久久6男男| 中文国产成人精品久久不卡 | 久久久久久亚洲精品无码| 99久久国产综合精品五月天喷水| 久久影院综合精品| 久久国产欧美日韩精品| 色偷偷88欧美精品久久久| 国内精品久久久久久久久电影网| 久久777国产线看观看精品| 青青草原精品99久久精品66| 亚洲伊人久久大香线蕉综合图片| 18禁黄久久久AAA片| 狠狠色丁香久久婷婷综合_中| 久久人妻无码中文字幕|