Skip to main content



      Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Message / Information when ViewPart is activated/inactivated
Message / Information when ViewPart is activated/inactivated [message #440171] Fri, 25 November 2005 10:56 Go to next message
Eclipse UserFriend
Hi,

I have a ViewPart that needs to get information if activated. This
Viewpart only contains a Composite with a Tree (TreeViewer).

My first attempt was to overwrite setFocus(). Unfortunatly there are
some cases, when setFocus() isn't called when it's ViewPart is
activated. For example when the ViewPart contains a Control, that
already has focus when the Viewpart ist acitvated (f.e. by clicking
inside the ViewPart).

Is there an other way to be informed when a ViewPart is activated or
inactivated?

Thanks in advance,
Andreas
Re: Message / Information when ViewPart is activated/inactivated [message #440198 is a reply to message #440171] Fri, 25 November 2005 14:53 Go to previous message
Eclipse UserFriend
Andreas Dolk schrieb:
> Hi,
>
> I have a ViewPart that needs to get information if activated. This
> Viewpart only contains a Composite with a Tree (TreeViewer).
>
> My first attempt was to overwrite setFocus(). Unfortunatly there are
> some cases, when setFocus() isn't called when it's ViewPart is
> activated. For example when the ViewPart contains a Control, that
> already has focus when the Viewpart ist acitvated (f.e. by clicking
> inside the ViewPart).
>
> Is there an other way to be informed when a ViewPart is activated or
> inactivated?
>
> Thanks in advance,
> Andreas


.... think I got ist: IPartListener2#activatePart should do it. The
Listener needs to be added to WorkbenchPart...

Andreas
Previous Topic:Hello RCP: unable to run
Next Topic:preferencestore
Goto Forum:
  


Current Time: Mon Oct 27 04:57:11 EDT 2025

Powered by FUDForum. Page generated in 0.03501 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top