Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » RCP Text Example under 3.1?
RCP Text Example under 3.1? [message #437676] Sat, 01 October 2005 12:08 Go to next message
CM is currently offline CMFriend
Messages: 2
Registered: July 2009
Junior Member
Hi,

I was wondering if anyone could help me converting the RCP Text Editor example
to Eclipse 3.1. It's working, but there are some already depricated methods used.

public void preWindowOpen(IWorkbenchWindowConfigurer configurer)
{
super.preWindowOpen(configurer);
configurer.setInitialSize(new Point(600, 450));
configurer.setShowCoolBar(true);
configurer.setShowStatusLine(true);
}

This one is rather easy, I just have to use
"WorkbenchWindowAdvisor.preWindowOpen()" and get the configurer with
"IWorkbenchWindowConfigurer configurer = getWindowConfigurer();"

public void fillActionBars(IWorkbenchWindow window,
IActionBarConfigurer configurer, int flags)
{
super.fillActionBars(window, configurer, flags);

if(fActionBuilder == null)
fActionBuilder = new WorkbenchActionBuilder(window);

fActionBuilder.makeAndPopulateActions(getWorkbenchConfigurer (), configurer);
}

public void postShutdown()
{
if(fActionBuilder != null)
fActionBuilder.dispose();
}

These two give me trouble. I've tried to move it to the method suggested in the
docs, which is "ActionBarAdvisor.fillActionBars(int)", but I don't know how to
get the WorkbenchConfigurer from there, or if I even need it. What's the
suggested way of doing the above under 3.1 RCP?

regards,
Chris
Re: RCP Text Example under 3.1? [message #437685 is a reply to message #437676] Sun, 02 October 2005 03:46 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
Chris,
Try build rcp example (new - plugin project
and check rcp application and add text editor from old
text editor example
Peco
CM wrote:

> Hi,
>
> I was wondering if anyone could help me converting the RCP Text Editor
> example to Eclipse 3.1. It's working, but there are some already
> depricated methods used.
>
> public void preWindowOpen(IWorkbenchWindowConfigurer configurer)
> {
> super.preWindowOpen(configurer);
> configurer.setInitialSize(new Point(600, 450));
> configurer.setShowCoolBar(true);
> configurer.setShowStatusLine(true);
> }
>
> This one is rather easy, I just have to use
> "WorkbenchWindowAdvisor.preWindowOpen()" and get the configurer with
> "IWorkbenchWindowConfigurer configurer = getWindowConfigurer();"
>
> public void fillActionBars(IWorkbenchWindow window,
> IActionBarConfigurer configurer, int flags)
> {
> super.fillActionBars(window, configurer, flags);
>
> if(fActionBuilder == null)
> fActionBuilder = new WorkbenchActionBuilder(window);
>
> fActionBuilder.makeAndPopulateActions(getWorkbenchConfigurer (),
> configurer);
> }
>
> public void postShutdown()
> {
> if(fActionBuilder != null)
> fActionBuilder.dispose();
> }
>
> These two give me trouble. I've tried to move it to the method suggested
> in the docs, which is "ActionBarAdvisor.fillActionBars(int)", but I don't
> know how to get the WorkbenchConfigurer from there, or if I even need it.
> What's the suggested way of doing the above under 3.1 RCP?
>
> regards,
> Chris
Re: RCP Text Example under 3.1? [message #437713 is a reply to message #437676] Mon, 03 October 2005 17:09 Go to previous message
Tom Hofmann is currently offline Tom HofmannFriend
Messages: 770
Registered: July 2009
Senior Member
Chris,

I have updated the RCP text editor example to 3.1 - check it out under
[1]. Feedback welcome...

-tom

[1]
http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/plat form-text-home/development/rcp/examples/index.html
Previous Topic:Loading IAdaptable with DynamicProxy
Next Topic:Show a view as a 'detached view' by code ?
Goto Forum:
  


Current Time: Mon Dec 02 23:28:51 GMT 2024

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

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

Back to the top