Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » SingleSourcing: How to determine between RCP and RAP
SingleSourcing: How to determine between RCP and RAP [message #869777] Fri, 04 May 2012 09:50 Go to next message
Marc T. is currently offline Marc T.Friend
Messages: 17
Registered: November 2009
Junior Member
Hallo,

I have a simple question:

Is there any method to determine from within a plugin, if it is running under RCP or RAP environment ?

I want some GUI elements to behave different under RAP and RCP environment and want to avoid fragments because of some minor differences.

Kind of:

if(PlatformUI.getType()==SWT.RAP)
button.setText("Is RAP");
else
button.setText("Is RCP");

Regards

Marc
Re: SingleSourcing: How to determine between RCP and RAP [message #869793 is a reply to message #869777] Fri, 04 May 2012 10:17 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 335
Registered: July 2009
Senior Member
Marc,

use "rap".equals( SWT.getPlatform() ) to detect RAP.

HTH
Rüdiger

On 04.05.2012 11:50, Missing name Mising name wrote:
> Hallo,
>
> I have a simple question:
>
> Is there any method to determine from within a plugin, if it is running
> under RCP or RAP environment ?
>
> I want some GUI elements to behave different under RAP and RCP
> environment and want to avoid fragments because of some minor differences.
>
> Kind of:
>
> if(PlatformUI.getType()==SWT.RAP)
> button.setText("Is RAP");
> else button.setText("Is RCP");
>
> Regards
>
> Marc
--
Rüdiger Herrmann
http://codeaffine.com
Re: SingleSourcing: How to determine between RCP and RAP [message #869821 is a reply to message #869793] Fri, 04 May 2012 12:06 Go to previous messageGo to next message
Marc T. is currently offline Marc T.Friend
Messages: 17
Registered: November 2009
Junior Member
Thanks,

I knew, there must be a simple solution. Maybe something for the RAP FAQs ?

Marc
Re: SingleSourcing: How to determine between RCP and RAP [message #869876 is a reply to message #869821] Fri, 04 May 2012 15:43 Go to previous message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 335
Registered: July 2009
Senior Member
On 04.05.2012 14:06, Marc T. wrote:
> Thanks,
>
> I knew, there must be a simple solution. Maybe something for the RAP FAQs ?
Sure, feel free to add a section.

- Rüdiger
>
> Marc
Previous Topic:FileDialog usage questions
Next Topic:SingleSourcing: Server Side Image
Goto Forum:
  


Current Time: Sun Oct 17 14:11:04 GMT 2021

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

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

Back to the top