You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-user@portals.apache.org by Mete Kural <me...@touchtonecorp.com> on 2004/03/31 19:39:14 UTC

Setting WindowState from other portlets

Hello all,

I am developing a portlet application consisting of a set of portlets that need to work together using JSR-168. I have a shared session object in the portlet application session scope that holds certain application state information that all portlets use to render themselves. There is one problem that I haven't yet been able to figure out relating to how to set the WindowState based on the application state in this shared session object.

Let's say there is a portlet application with three portlets: search portlet, results portlet, detail portlet. Let's say that there are three application states A, B, and C. State A is for when the user first goes to the portal page. State B happens afters the user enters a query and clicks on search button in the search portlet and the results are displayed in the search results portlet. State C happens for when the user clicks on one of the results in the search results portlet and views the result in the detail portlet. In state A, the search portlet should be the only one in NORMAL window state and the results portlet and the detail portlet should be MINIMIZED. In state B, the search portlet should stay in NORMAL window state, the results portlet should go from MINIMIZED to NORMAl window stage, and the detail portlet should stay MINIMIZED. In state C, the search portlet should become MINIMIZED, the results portlet should stay NORMAL, and the detail portlet should go from MINIMIZED to NORMAL.

Is it possible to do this using JSR-168?

One idea I had was to set the window states of other portlets from the processAction method of one of the portlets, but how would that be possible? Do you have any other ideas?

Thank you,
Mete Kural