| 
      
      
      From: Jaap de W. <ja...@de...> - 2006-10-04 21:11:52
      
     | 
| Hello,
 For the time being I already implemented the onheaderclick.
I did this by rewriting the tabpane caption part, as in the code below.
Of course this is duplicated 8 times, with a few variations.
                                        <td 
class="com_htmli_ui_TabPane__selectedleft_top"> </td>
                                        <td onmousedown="var current = 
application.wrapNode(document.getElementById('{$id__}'));var me = 
application.wrapNode(this);var ev = application.wrapEvent(event);return 
false;" onselectstart="var current = 
application.wrapNode(document.getElementById('{$id__}'));var me = 
application.wrapNode(this);var ev = application.wrapEvent(event);return 
false;" nowrap="nowrap" class="com_htmli_ui_TabPane__selectedright_top">
--> the new code starts here
                      <xsl:attribute name="onclick">var current = 
application.wrapNode(document.getElementById('<xsl:value-of 
select="$id__" />'));var me = application.wrapNode(this);var ev = 
application.wrapEvent(event);current.focusChild(0);<xsl:if 
test="h:tab[1]/@onheaderclick"><xsl:value-of 
select="h:tab[1]/@onheaderclick"/></xsl:if>;return false;</xsl:attribute>
--> the new code ends here.
                      <xsl:if test="h:tab[1]/@icon">
                                                    <img 
src="{h:tab[1]/@icon}" class="com_htmli_ui_TabPane__iconh"/>
                                                </xsl:if>
                                                <xsl:value-of 
select="h:tab[1]/@caption"/>
                                        </td>
Matias Bagini schreef:
> Hello Jaap,
>
> On next release (we hope it'll be ready by tomorrow) we'll add an event 
> called "onheaderclick" to the Tab element, so that you can do:
>
>    <htmli:tabpane>
> 	<htmli:tab onheaderclick="myFillTabFunction(me);">
> 		Some content...
> 	</htmli:tab>
>    <htmli:tabpane>
>
> Do you think this will solve your problem?
>
> Thanks,
>
> Matias
>
>   
>> Hello,
>>
>> I want to do an action when a tab is selected.
>> (Actually I want to fill a tab with values from a httpRequest(), but 
>> thats not the issue).
>> But I can find no way to find the selected tab.
>> According to the documentation I should use the |*getPosition 
>> <cid:par...@de...>*() of the tabpane, but that 
>> returns 'undefined'.
>> I tried to find the selected tab in the onmouseup ||of the tabpane 
>> ||(and in the onmousedown), using the code below, but that always gave 
>> me as a result the page that was selected before (So when I first select 
>> tab1, and then tab2, tab1 is updated when tab2 is selected.
>> I also tried the onselect of the tab, but that does not work before you 
>> actually click in the tab area.
>>
>> Has anyone suggestions?
>>     
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Htmli-user mailing list
> Htm...@li...
> https://lists.sourceforge.net/lists/listinfo/htmli-user
>   
 |