myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ramiro Pereira de Magalhães <rpm_mail...@yahoo.com.br>
Subject Res: [jira] Commented: (TOMAHAWK-799) Use of the actionListener event of datascroller to maintain the index of the first row inside a managed bean.
Date Wed, 15 Jul 2009 21:12:21 GMT
Guys,

could anyone handle this issue, please? It seems it is very simple and fast to solve since
its solution is well described and seems not to cause any damage to the Data Scroller component.

Should anyone need more information or description about it, I think I can help.

Thanks,
RPM






________________________________
De: Ramiro Pereira de Magalhães (JIRA) <dev@myfaces.apache.org>
Para: dev@myfaces.apache.org
Enviadas: Quarta-feira, 15 de Julho de 2009 18:05:15
Assunto: [jira] Commented: (TOMAHAWK-799) Use of the actionListener event of datascroller
to maintain the index of the first row inside a managed bean.


    [ https://issues.apache.org/jira/browse/TOMAHAWK-799?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12731685#action_12731685
] 

Ramiro Pereira de Magalhães commented on TOMAHAWK-799:
------------------------------------------------------

Hey, guys, I do indeed need such fine controll that Jorge described. I was studying the problem
and concluded that a good solution was already proposed here, in this ticket. That is, in
file AbstractHtmlDataScroller.java, move line number 254 where you read

            broadcastToActionListener(scrollerEvent);

to below the line 333 so that it reads

        }
        broadcastToActionListener(scrollerEvent);
    }

It makes a lot more sense to me this way.

> Use of the actionListener event of datascroller to maintain the index of the first row
inside a managed bean.
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: TOMAHAWK-799
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-799
>             Project: MyFaces Tomahawk
>          Issue Type: Improvement
>          Components: Data Scroller
>    Affects Versions: 1.1.5-SNAPSHOT
>         Environment: Windows XP, jakarta-tomcat-5.0.28.
>            Reporter: Jorge Andrés Vásquez
>            Priority: Minor
>
> The the HtmlDataScroller class is currently using the actionListener event (in particular
the ScrollerActionEvent) to maintain the firstRow index of the dataTable.  My idea is that
if someone needs to control this variable from inside a managed bean for example in order
to maintain the page number in a master/detail scenario then that person can use this actionEvent
too.  But in order for broadcast method of HtmlDataScroller component class to not overwrite
the control logic that one can implement from the bean the suggestion is to modify method:
 "public void broadcast(FacesEvent event)" changing the broadcastToActionListener(scrollerEvent);
to the end of the if (event instanceof ScrollerActionEvent)...portion of the code.  This change
allows anyone to control the rowIndex from a bean with a simple event-based logic.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


      ____________________________________________________________________________________
Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com
Mime
View raw message