Friday, November 27, 2009

Super Cool Drag n Drop Sidebar Widget (Eclipse RCP / Lotus Expeditor plug-in)

I've just ended our PoC (Proof of Concept) on a multi featured Eclipse / Expeditor based Drag n Drop Widget, and the product managers and sales guys are ecstatic. They are all really excited and explodes with new ideas to the component.

This is what it look like, right now.... (please remember it's the first PoC so it will have to undergo some UI corrections and better practices ;)





Just to mention some of the features, as it is currently....
  • It's split up into to concepts
    • A drop enabled viewer part with a filter functionality (configured to fetch and show documents from views)
    • A drop pad (here users can drop documents on the current selected target document in the current Notes context, from the inbox, calender....whatever...)
A little word on some of the features:
  • The widget is extremely configurable
  • The widget can listen to Notes document selections coming from any view, folder or alike. And if any of the selected document has a form name that matches one from the configuration....well then it's a potential drop target.
  • You can have sticky targets (targets that stays tight, even when you select other potential target documents)
  • When you drop a bunch of documents they can either get copied and "responsed" on the target / main document or you can configure it to create a DND (Drag n Drop) main document in the target database and make the drop get "responsed" on that DND document instead, enabling you to do some processing on the drop before the dropped documents gets "responsed" on the real target / main document
  • You can configure agents to run on the target document (via the NOTEID) after a drop, enabling you to do some post processing
  • The user can use the viewer to directly open the documents and databases
  • And much much more....


Here is a shot of a drop of mails in the viewer part

 

Here is a shot of a drop of mails onto the drop pad (relating to a current selected target document, which could have been selected in a random Notes view in a random application.



Here you can see some of the setup possibilities in the relating preference pages. Focus on the tabbed folder component to see the different configuration settings.

The Database Tab:



The Viewer Tab:



The Drag n Drop Tab:



The Target Tab:



Cool right? Feel free to supply with any comments and ideas.

So what's the plan now???....Well now the widget has to undergo some further investigation in a complete features set, testing, release plan and other stuff (and we are thinking of distributing it for free!!!!) but let's see what happens in the end.

Thursday, November 26, 2009

Looking for Eclipse icons

I'am out looking for icon sites that has nice Eclipse RCP icons and images.

I've found some sites and will keep updating this blog entry when I find more sites or tips.

Remember you can also search your "eclipse/plugins" folder for *.gif and *.png images.

Here is my "list" of Eclipse oriented icon sites:
If you have any knowledge on valuable Eclipse based icon sites please comment this blog entry.

Wednesday, March 11, 2009

Launching a url using a browser component

If you need to launch a url in Lotus Expeditor based clients, you have several options depending on how you want to present it.

Here's a few ways on how to do it:
  • Using a Browser Widget ( added to a Composite)
  • Using the EmbeddedBrowser View

Using a Browser Widget ( added to a Composite)
Eclipse and Lotus Expeditor offers each a simple browser widget that can be added to a composite. They a very much alike.

Here's a sample using the core Eclipse SWT browser widget:

Browser browser;
try {

browser = new Browser(composite, SWT.NONE);
browser.setLayoutData( new GridData(SWT.FILL, SWT.FILL, true, true));
browser.setUrl("http://www.ibm.com");

} catch (SWTError e) {
// Handle any errors.
}

And here's a sample with the Lotus Expeditor equivalent:

WebBrowser browser;
try {

browser = new WebBrowser(composite, SWT.NONE);
browser.setLayoutData( new GridData(SWT.FILL, SWT.FILL, true, true));
browser.setUrl("http://www.ibm.com");

} catch (SWTError e) {
// Handle any errors.
}


You can use the browser.setText("...") method to add custom HTML content into the browser, if needed.
You also have the ability to listen to events and traverse the DOM (Document Object Model).

Using the EmbeddedBrowser View
The Lotus Expeditor platform also gives you a viewpart based browser component.

// Every instance needs it's own unique id.
String id = "com.rcpcompany.lotus.notes.spy.browserview.sample";

// Create a map with all the needed properties.
Map configMap = new HashMap();
configMap.put(BrowserPreference.ID, id);
configMap.put(BrowserPreference.INITIAL_URL, url);

// Get the active page
IWorkbench workbench = PlatformUI.getWorkbench();
IWorkbenchWindow window = workbench.getActiveWorkbenchWindow();
IWorkbenchPage page = window.getActivePage();

// Create the browser instance.
EmbeddedBrowser browser = BrowserFactory.launch(page, configMap, id);

// Maximize the new browser view if needed.
page.setPartState(page.getActivePartReference(), IWorkbenchPage.STATE_MAXIMIZED);

Search This Blog

Eclipse Live: Equinox Ganymede

The creator of an Eclipse Bible, introduces Equinox and its building blocks for creating applications. We overview the architecture and technology, and demonstrate many of the building blocks.
by Jeff McAffer (Code 9)