Special effects for dialogs

Special effects for dialogs

Postby horacio » Fri Feb 15, 2008 9:25 am

I hope that they like

#include 'fivewin.ch'
#define AW_HOR_POSITIVE 1 // Animates the window from left to right. This flag can be used with roll or slide animation.
#define AW_HOR_NEGATIVE 2 // Animates the window from right to left. This flag can be used with roll or slide animation.
#define AW_VER_POSITIVE 4 // Animates the window from top to bottom. This flag can be used with roll or slide animation.
#define AW_VER_NEGATIVE 8 // Animates the window from bottom to top. This flag can be used with roll or slide animation.
#define AW_CENTER 16 // Makes the window appear to collapse inward if AW_HIDE is used or expand outward if the AW_HIDE is not used.
#define AW_HIDE 65536 // Hides the window. By default, the window is shown.
#define AW_ACTIVATE 131072 // Activates the window.
#define AW_SLIDE 262144 // Uses slide animation. By default, roll animation is used.
#define AW_BLEND 524288 // Uses a fade effect. This flag can be used only if hwnd is a top-level window.

Function Main()

Local oDlg
Local oBtn
Define Dialog oDlg From 10, 10 To 300, 500 Pixel

@ 10, 10 Button oBtn Size 50, 10 Of oDlg Pixel Action oDlg : End()

Activate Dialog oDlg On Init Centra( oDlg ) Centered Valid( Fade( oDlg ), .t. )
Return 0


Function fade( oDlg )

If( AnimateWindow( oDlg : hWnd, 1000, AW_BLEND + AW_HIDE ) == 0 )
oDlg : Hide()
endif
Return 0
Function Centra( oDlg )

AnimateWindow( oDlg : hWnd, 200, AW_CENTER )
Return 0


DLL32 function AnimateWindow( hWnd As LONG, dwTime As LONG, dwFlags As LONG ) AS LONG PASCAL ;
from "AnimateWindow" lib "user32.DLL"
horacio
 
Posts: 1363
Joined: Wed Jun 21, 2006 12:39 am
Location: Capital Federal Argentina

Postby ask » Fri Feb 15, 2008 12:21 pm

this is great stuff!!
ask
 
Posts: 99
Joined: Wed Nov 02, 2005 10:40 am

Postby nageswaragunupudi » Fri Feb 15, 2008 12:46 pm

The earlier discussion on this topic may also give useful information

http://fivetechsoft.com/forums/viewtopi ... matewindow
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10648
Joined: Sun Nov 19, 2006 5:22 am
Location: India


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 33 guests