|
고수님에게 질문합니다
자료실에도 있는 유명한 Graphics32를 사용할려구 했습니다
프로그램 내부에는 TLabel컨포넌트에서 OnDragOver이벤트 처리를 쓰고 있고
TImage32에서도 OnDragOver 이벤트를 쓰고 있는데
그런데 컴파일시Ambiguity between 'TDragState' and 'Controls::TDragState'
라는 에러가 발생하였습니다
그래서 제가 알고 있는 지식과 게시판의 내용을 찾아본 결과 비슷한 질답 내용을 보고 아래와 같이 수정을 했습니다
헤더쪽 에서
void __fastcall Label1DragOver(TObject *Sender, TObject *Source, int X,
int Y, Controls::TDragState State, bool &Accept);
void __fastcall Image321DragOver(TObject *Sender, TObject *Source, int X,
int Y, Gr32_layers::TDragState State, bool &Accept);
이런식으로 name space를 붙였고
소스쪽에서도
void __fastcall TForm1::Label1DragOver(TObject *Sender, TObject *Source,
int X, int Y, Controls::TDragState State, bool &Accept)
{
//
}
void __fastcall TForm1::Image321DragOver(TObject *Sender, TObject *Source,
int X, int Y, Gr32_layers::TDragState State, bool &Accept)
{
//
}
와같이 수정을 하여 다시 컴파일을 하니 아래와 같은 내용의 창이 뜨면서
The Label1DragOver method referenced by Label1->OnDragOver has an incompatible parameter list. Remove the refernce?
지울래 말래 취소할래 어쩔래 하는....그래서 안지움으로 선택해서 컴파일 해서 정상적으로 동작은 하나
컴파일 시 마다 계속 이런 내용이 나오는데 이게 제가 제대로 하고 있는건지 아님 잘못된건지 좀 알려주세요
또는 위와같은 메세지가 안나오게 하는 옵션이 있는지요?
|