Print Page | Close Window

Custom Animation for Menus

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=434
Printed Date: 23 December 2024 at 11:54am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Custom Animation for Menus
Posted By: coradinibr
Subject: Custom Animation for Menus
Date Posted: 10 February 2004 at 8:11am

Hi,

I was using Xtreme Toolkit Standard and my company changed to Professional.

I am trying to set custom animation as I did with CXTCoolMenu but I cannot figure out how to do it !!!

In the documentation of Xtreme Toolkit Pro, there is a sample to set the customized animation but the variable m_nAnimationType is not a member of CXTCoolMenu !!!

Other information that does not match is that in the enumeration XTPAnimationType there is any definition for custom animations.

I've the overriden function for the custom animation and called the CXTAnimationMemDC::SetCustomAnimation( function ), but is does not call the the function for any type of animation, even the defaults.

Is it possible to set custom animation in the Professional version ?

Thanks in advance.

Evandro Coradini

 




Replies:
Posted By: Oleg
Date Posted: 10 February 2004 at 2:27pm

Hello, in new version need to override PainrManagers:

 

class CXTPOfficeThemeA : public CXTPOfficeTheme

{

void Animate(CDC* pDestDC, CDC* pSrcDC, CRect rc, XTPAnimationType animationType)

{

int nSteps = m_nAnimationSteps;

int nAnimationTime = m_nAnimationTime;

for (int i = 0; i < rc.Height();

i += (1 + (rc.Height() / nSteps)))

{

pDestDC->StretchBlt(rc.left, rc.top, rc.Width(), i, pSrcDC,

0, 0, rc.Width(), rc.Height(), SRCCOPY);

Sleep(nAnimationTime / nSteps);}

}

}

};

 

and set the theme

CXTPPaintManager::SetCustomTheme(new CXTPOfficeThemeA());

 

but in CXTPPaintManager Animate isn't declared as virtual, so add it yourself. In next version it will be fixed.

virtual void Animate(CDC* pDestDC, CDC* pSrcDC, CRect rc, XTPAnimationType animationType);

 



-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net