comp.lang.ada
 help / color / mirror / Atom feed
* WIN32 DialogBox and  OPENGL
@ 1998-08-14  0:00 Colson E.
  0 siblings, 0 replies; only message in thread
From: Colson E. @ 1998-08-14  0:00 UTC (permalink / raw)


Hello,

I try desesperately to display a modal dialog box in an OpenGL application.
The problem  is that I don't see the frame of the box, just the controls
(edit, buttons,...).
But it's not systematic : when I use a DLGPROC procedure, I don't see the
frame, but without 
procedure, there's no problem because I can see all controls and box frame.

There's the code which is write with Ada95 :

with ada.text_io;

    
	procedure la_porte is
		ok:win32.INT;
		Lresultat:win32.LONG;
	begin
		ok:=winuser.DialogBox(hInstance, 
				          LPCSTR(winuser.MAKEINTRESOURCE
						(PACK_RESSOURCES.IDD_MOT_DE_PASSE)),
				         hFenetre,
				         DlgProc'access);

	end la_porte;
    
	function DlgProc	(hwnd:   Win32.Windef.HWND;
        				 message:    Win32.UINT;
		                         wParam: Win32.WPARAM;
                        		 lParam: Win32.LPARAM)
		                         return Win32.BOOL is 
		use type Interfaces.C.UNSIGNED_SHORT;                             
		ok:win32.INT;
	begin
		Case message is 
			when winuser.WM_INITDIALOG =>
		                    resultat:=win32.TRUE;                                
                 
		            when Winuser.WM_COMMAND =>
		            declare
				cmdId: Win32.WORD; 
			begin
				cmdID:=windef.LOWORD(win32.DWORD(wparam));
				if cmdID=PACK_RESSOURCES.ID_ANNULER then
					resultat:=winuser.EndDialog(hwnd,0);
		                    	end if;
		            end ;
			when others =>
		            	null;
	        end case;

        	        return win32.TRUE;

    end DlgProc;
    
If someone have an idea...

By advance

Colson Eric


				






^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1998-08-14  0:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-08-14  0:00 WIN32 DialogBox and OPENGL Colson E.

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox