home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2011 November
/
CHIP_2011_11.iso
/
Programy
/
Narzedzia
/
AIMP2
/
aimp_2.61.583.exe
/
$TEMP
/
YandexPackSetup.msi
/
filE57BBF321F07B368647934F23B85F253
< prev
next >
Wrap
Extensible Markup Language
|
2010-07-12
|
6KB
|
165 lines
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE stylesheet [
<!ENTITY % yasearchDTD SYSTEM "chrome://yasearch/locale/yasearch.dtd">
%yasearchDTD;
<!ENTITY % yasearchFTabDTD SYSTEM "chrome://yasearch/locale/ftab/ftab.dtd" >
%yasearchFTabDTD;
]>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.w3.org/1999/xhtml">
<xsl:output method="xml" encoding="UTF-8" indent="no"/>
<xsl:param name="secURLParam" select="3"/>
<xsl:param name="thumbsInRow" select="3"/>
<xsl:param name="thumbsInCol"/>
<xsl:param name="thumbsNmb" select="$thumbsInRow * $thumbsInCol"/>
<xsl:param name="thumbsTdWidth" select="100 div $thumbsInRow"/>
<xsl:param name="showNumbers" select="boolean($thumbsNmb <= 9)"/>
<xsl:template match="pages">
<table flex="1">
<xsl:call-template name="forCol"/>
</table>
</xsl:template>
<xsl:template name="forCol">
<xsl:param name="i" select="1"/>
<xsl:if test="$i <= $thumbsInCol">
<tr>
<xsl:call-template name="forRow">
<xsl:with-param name="j" select="1"/>
<xsl:with-param name="indx" select="$i"/>
</xsl:call-template>
</tr>
<xsl:call-template name="forCol">
<xsl:with-param name="i" select="$i + 1"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
<xsl:template name="forRow">
<xsl:param name="j" select="1"/>
<xsl:param name="indx"/>
<xsl:if test="$j <= $thumbsInRow">
<xsl:call-template name="page">
<xsl:with-param name="indx" select="($j + ($indx - 1) * $thumbsInRow)"/>
</xsl:call-template>
<xsl:call-template name="forRow">
<xsl:with-param name="j" select="$j + 1"/>
<xsl:with-param name="indx" select="$indx"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
<xsl:template name="page">
<xsl:param name="indx"/>
<xsl:param name="pg" select="page[@index = $indx]"/>
<td class="thumb" width="{$thumbsTdWidth}%">
<a class="thumb-holder"
yaThumbIndex="{$indx}"
yaThumbState="{$pg/@state}">
<xsl:if test="boolean($pg/@url)">
<xsl:attribute name="href">
<xsl:value-of select="$pg/@url"/>
</xsl:attribute>
</xsl:if>
<div class="thumb-shadow"/>
<div class="thumb-container">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 600 450">
<defs>
<linearGradient id="bg-gradient" gradientUnits="userSpaceOnUse"
x1="0" x2="0" y1="0" y2="100%">
<stop offset="0" stop-color="rgb(246,246,246)"/>
<stop offset="8%" stop-color="rgb(240,240,240)"/>
<stop offset="15%" stop-color="rgb(232,232,232)"/>
<stop offset="35%" stop-color="rgb(225,225,225)"/>
<stop offset="40%" stop-color="rgb(230,230,230)"/>
<stop offset="60%" stop-color="rgb(243,243,243)"/>
<stop offset="100%" stop-color="rgb(246,246,246)"/>
</linearGradient>
<linearGradient id="bg-gradient-hover" gradientUnits="userSpaceOnUse"
x1="0" x2="0" y1="0" y2="100%">
<stop offset="0" stop-color="rgb(248,248,249)"/>
<stop offset="30%" stop-color="rgb(243,243,243)"/>
<stop offset="60%" stop-color="rgb(243,243,243)"/>
<stop offset="100%" stop-color="rgb(248,248,249)"/>
</linearGradient>
</defs>
<rect x="0" y="0" width="100%" height="100%" style="fill:rgb(240,240,240);"/>
<rect x="0" y="0" width="100%" height="100%" style="fill: url(#bg-gradient-hover)"/>
<rect class="hover-off" x="0" y="0" width="100%" height="100%" style="fill: url(#bg-gradient)"/>
<image xmlns:xlink="http://www.w3.org/1999/xlink"
class="thumb-img"
xlink:href="about:yandex-tabs?sec={$secURLParam}&image={$pg/@url}"
x="0" y="0"
width="100%" height="100%"/>
<g class="error" style="display: none;">
<rect x="0" y="0" width="100%" height="100%" fill="rgb(246,246,248)"/>
<g transform="translate(300,200),rotate(45)">
<circle cx="0" cy="0" r="120" fill="#ccc"/>
<rect x="-90" y="-18" width="180" height="36" fill="rgb(248,248,248)"/>
<rect x="-18" y="-90" width="36" height="180" fill="rgb(248,248,248)"/>
</g>
</g>
</svg>
<div class="text-holder">
<div class="thumb-empty">
<p>&yaftab.thumb.add.1.label;</p>
<p>&yaftab.thumb.add.2.label;</p>
<p>&yaftab.thumb.add.3.label;</p>
</div>
<div class="thumb-title"><p>
<xsl:choose>
<xsl:when test="string($pg/@custom_title) != ''">
<xsl:value-of select="$pg/@custom_title"/>
</xsl:when>
<xsl:when test="string($pg/@title) != ''">
<xsl:value-of select="$pg/@title"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$pg/@url"/>
</xsl:otherwise>
</xsl:choose>
</p>
<div class="shade"/>
</div>
<xsl:if test="$showNumbers">
<div class="thumb-number">
<div class="thumb-number-value" style="background-position: -{number(-1+$indx) * 40}px 0;"/>
</div>
</xsl:if>
</div>
<div class="throbber"/>
<div class="control-holder">
<a class="control-prefs" tooltiptext="&yaftab.thumb.edit.label;"/>
<a class="control-remove" tooltiptext="&yaftab.thumb.remove.label;"/>
</div>
</div>
</a>
</td>
</xsl:template>
</xsl:stylesheet>