Showing posts with label New Features. Show all posts
Showing posts with label New Features. Show all posts

Sunday, November 22, 2009

Carousel does not make the selected row current

Carousel is a realy nice new component in jdeveloper 11 patch1
When you create a data binded carousel item it just uses an iterator and a tree model as a table.
Every item in carusel is from a diferent row of the iterator.
Yet when you select a new item the current row of the iterator is not changed.
So if you want to have other fields of the same iterator in the page or detail view objects iterators the data are not refreshed while navigating in Carousel.
I think a selectionListener as in the table component is missing.

In order to achieve the above behaviour i did the following:
I binded carouselSpinListener property to a backing bean method where
i get the carusel event NewItemKey and i find the Key of the row and i set iterator current row to the carusel selected row.
public void caruselSpin(CarouselSpinEvent event) {
List l =(List)event.getNewItemKey();
Key k = (Key)l.get(0);
DCIteratorBinding iter = getDCBindingContainer .findIteratorBinding ("DepartmentsView1Iterator");
iter.setCurrentRowWithKey(k.toStringFormat(true));


}


Now Every time you select new item in carusel the iterator has the selected row.

Test case:
http://adfbugs.googlecode.com/files/TestCarousel.zip

Friday, November 13, 2009

New Feature Closing a Popup can now be captured.

My first impression of patch 1 of jdeveloper11 is that it looks like a new IDE,
diferent screens for overview and for security,
diferent menus and lots of new properties.

One thing that was missing and I was complaining about in the oracle forums was the capturing of an event when a popup dialog is closed.
http://forums.oracle.com/forums/message.jspa?messageID=3898637#3898637

Now a new property in popup component popupCanceledListener solves this problem.


You can just assign a backing bean method on it and it works no mater how you close the popup (with Cancel, with 'x' button or with ESC key).


This was realy needed. Thanks oracle team for the new feature

The only little bug in this is that in design view the popup is not visible when you place it in button facet popup

Test Case
http://adfbugs.googlecode.com/files/TestPopup.zip