a auto fade window like tooltip[resolved]

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

silenttree
Not too shy to talk
Not too shy to talk
Posts: 30
Joined: Wed Nov 01, 2006 05:59
Contact:

a auto fade window like tooltip[resolved]

Postby silenttree » Thu Nov 09, 2006 04:35

i notice that tooltip can auto fadein and fadeout.

for some reason, i need a window like this.

so i inherit a class from CEGUI::Window, and override updateSelf() method like Tooptip. and mark multi-window-state such as Active/FadeOut

then i create a window with it, like below

Code: Select all

MyOwnWindow* WindowPtr = static_cast<MyOwnWindow*>(m_WindowMgr->createWindow(WindowType, WindowName))


like System::setDefaultTooltip does below

Code: Select all

d_defaultTooltip = static_cast<Tooltip*>(WindowManager::getSingleton().createWindow(tooltipType, "CEGUI::System::default__auto_tooltip__"));


but, nothing happen!

the system does not invoke my updateSelf implement.
:oops:

is there something goes wrong?
Last edited by silenttree on Tue Nov 14, 2006 20:01, edited 1 time in total.

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Postby CrazyEddie » Thu Nov 09, 2006 09:54

Hi,

Obvious question, but do you add your window to the 'active' hierarchy? The method is only called if the system can reach it at some level from the active root sheet (else it would not display anyway ;) ).

If you're doing that, the only other thing I could think of was that if you added that override some time after the initial version of your code, it could be some strange 'minimal rebuild' issue. I've seen such strangeness before with adding overrides - did you try a clean / full rebuild?

If it's not either of those, is there any other information you could offer?

CE.

silenttree
Not too shy to talk
Not too shy to talk
Posts: 30
Joined: Wed Nov 01, 2006 05:59
Contact:

Postby silenttree » Thu Nov 09, 2006 14:26

at the first. say sorry to EC for my bad expression.

my origin goal is: make a window auto fade by given time.

i notice that "tooltip" can do this well.

so i read it in cegui - solution, and make a new copy for my own.

but its "doesnt work"(window show directly, but didnt invoke MyOwnWindowClass::updateSelf() method that i override from CEGUI::Window), so i cant make a window auto fade-out like tooltip. :?

and i dont know why. :roll:

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Postby CrazyEddie » Mon Nov 13, 2006 09:42

Just to confirm... the window is appearing, but no fading is occurring? You've traced it somewhat and the updateSelf member of your new class is not being called?

Could you post some relevant code (i.e. a minimal amount that demonstrates the issue).

Cheers,

CE.

silenttree
Not too shy to talk
Not too shy to talk
Posts: 30
Joined: Wed Nov 01, 2006 05:59
Contact:

Postby silenttree » Tue Nov 14, 2006 19:53

problem is resolved by adding a timer.:lol:

thank you CE!:wink:

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Postby CrazyEddie » Thu Nov 16, 2006 09:13

hehe, cool :D


Return to “Help”

Who is online

Users browsing this forum: No registered users and 16 guests