Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-ui-dev] Change to workbench lifecycle?


As a general rule, getActiveWindow() and getActivePage() should be avoided if at all possible.
An action or part should know its context (i.e. part.getSite().getPage()) and should pass it through the code to where it's needed.

Nick




Eduardo Pereira/Ottawa/IBM@IBMCA
Sent by: platform-ui-dev-admin@xxxxxxxxxxx

02/07/03 12:32 PM
Please respond to platform-ui-dev

       
        To:        platform-ui-dev@xxxxxxxxxxx
        cc:        
        Subject:        Re: [platform-ui-dev] Change to workbench lifecycle?




We did not change the lifecycle of view but I fixed a bug related to fast
views/lazy initialization. To fix this I moved the place where the part
control is created. It may be the cause of your problem. Please log a bug
report against Platform UI and I will investigate it.

Anyway, you may be able to fix/workaround it by using getSite().getPage().

Eduardo.




                                                                                                                             
                     Jared Burns                                                                                            
                     <jared-eclipse@xxxxx.c        To:       platform-ui-dev@xxxxxxxxxxx                                    
                     om>                           cc:                                                                      
                     Sent by:                      Subject:  [platform-ui-dev] Change to workbench lifecycle?                
                     platform-ui-dev-admin@                                                                                  
                     eclipse.org                                                                                            
                                                                                                                             
                                                                                                                             
                     02/07/2003 11:43 AM                                                                                    
                     Please respond to                                                                                      
                     platform-ui-dev                                                                                        
                                                                                                                             
                                                                                                                             




I have a view (the good 'old EditorList) that references the active
workbench
page via PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage
()
inside the createPartControl(Composite) method. In recent builds, this call

has started to always return null if the view is being created at startup.

Has the workbench lifecycle changed in some way such that there is no
longer
an active page during startup? Or is this just a bug?

Thanks,
- Jared
_______________________________________________
platform-ui-dev mailing list
platform-ui-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-ui-dev




_______________________________________________
platform-ui-dev mailing list
platform-ui-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-ui-dev



Back to the top