View File | Revision Log | Show Annotations | Download File | View Changeset
/hippo/hippo-cms6/hippo-cms/branches/Branch-CMS-v6_05_xx/editor/src/site/workbench/transformers/top.xsl
Revision: 604
Committed: Tue Jan 24 10:05:28 2006 UTC (14 years, 5 months ago) by jreijn
Content type: application/xml
Original Path: hippo-cms/trunk/editor/src/site/workbench/transformers/top.xsl
File size: 8209 byte(s)
Error occurred while calculating annotation data.
Log Message:
-- add scriptaculous to top window so it's available.

File Contents

# Content
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!--
3 Top frame
4 Loads the CMS framework javascript classes and startup script
5 Draws tab headers
6 -->
7 <xsl:stylesheet version="1.0"
8 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
9 xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
10 >
11
12 <xsl:param name="username"/>
13 <xsl:param name="fullname"/>
14 <xsl:param name="editUri"/>
15 <xsl:param name="editType"/>
16
17 <xsl:template match="/">
18 <html>
19
20 <head>
21 <title>Hippo CMS Tab Menu</title>
22 <link href="/workbench/css/top.css" rel="stylesheet" type="text/css"/>
23 <link href="/skin/css/workbench/top.css" rel="stylesheet" type="text/css"/>
24
25 <!-- Class framework -->
26 <script type="text/javascript" src="/workbench/js/cfx/Cfx.js">&#160;</script>
27
28 <!-- Load Default and Empty logger -->
29 <script type="text/javascript" src="/workbench/js/hippo/logger.js">&#160;</script>
30
31 <!-- Load helper functions and classes -->
32 <script type="text/javascript" src="/workbench/js/hippo/util.js">&#160;</script>
33
34 <!-- Load CMS startup script + global params&references -->
35 <script type="text/javascript" src="/workbench/js/hippo/cms.js">&#160;</script>
36
37 <!-- Load framework class -->
38 <script type="text/javascript" src="/workbench/js/hippo/framework.js">&#160;</script>
39
40 <!-- Load workbench class -->
41 <script type="text/javascript" src="/workbench/js/hippo/workbench.js">&#160;</script>
42
43 <!-- Load container class -->
44 <script type="text/javascript" src="/workbench/js/hippo/container.js">&#160;</script>
45
46 <!-- Load remote call class -->
47 <!--<script type="text/javascript" src="/workbench/js/hippo/remoteAjax.js"/>-->
48 <script type="text/javascript" src="/workbench/js/hippo/rpc.js">&#160;</script>
49
50 <!-- Load event manager class -->
51 <script type="text/javascript" src="/workbench/js/hippo/events.js">&#160;</script>
52
53 <!-- Load PerspectiveManager class + perspective class -->
54 <script type="text/javascript" src="/workbench/js/hippo/perspectives.js">&#160;</script>
55
56 <!-- Load viewmanager + view + all view implementations -->
57 <script type="text/javascript" src="/workbench/js/hippo/views.js">&#160;</script>
58
59 <!-- Load CMS configuration -->
60 <script type="text/javascript" src="/workbench/js/config.js">&#160;</script>
61
62 <script type="text/javascript" src="/js/scriptaculous/lib/prototype.js">&#160;</script>
63
64 <script>
65
66 var documentIsOpen = "false";
67
68 function openDocument(state)
69 {
70 documentIsOpen = state;
71 }
72
73 function editDocumentFromExternal()
74 {
75 <xsl:if test="string-length($editUri) &gt; 0 and string-length($editType) &gt; 0">
76 //setTimeout("workbench.sm.lookup('cms.eventmanager').fireEvent('editDocument', [{key:'id',val:'<xsl:value-of select="$editUri"/>'},{key:'url',val:'<xsl:value-of select="$editType"/>'}])", 1000);
77 setTimeout("workbench.sm.lookup('cms.eventmanager').fireEvent('selectSource', [{key:'url',val:'<xsl:value-of select="$editUri"/>'}])", 1000);
78 setTimeout("workbench.sm.lookup('cms.eventmanager').fireEvent('selectSource', [{key:'url',val:'<xsl:value-of select="$editUri"/>'}])", 5000);
79 </xsl:if>
80 }
81 </script>
82
83 <xsl:apply-templates select="/root/perspectives-js"/>
84 </head>
85
86 <!-- [DD] locking not supported now -->
87 <!--body onbeforeunload="window.location.href='/login/removeLocks';"-->
88 <body>
89 <table cellpadding="0" cellspacing="0" width="100%" border="0" class="topTable">
90 <tr>
91 <td align="left" height="20">
92 <img src="/skin/images/empty.gif" width="1" height="20" align="left"/>
93 </td>
94 <td align="right">
95 <table cellpadding="0" cellspacing="2" border="0" height="20" width="100%">
96 <tr>
97 <td align="left">
98 <img src="/skin/images/logocms.gif" width="225" height="20"/>
99 </td>
100 <td width="150" align="right" class="logininfo" onclick="window.top.location='/login/logout'">
101 <xsl:choose>
102 <xsl:when test="string-length($fullname)&gt;0">
103 <xsl:value-of select="$fullname"/>
104 </xsl:when>
105 <xsl:otherwise>
106 <xsl:value-of select="$username"/>
107 </xsl:otherwise>
108 </xsl:choose>
109 <a href="/login/logout">
110 <img src="/skin/images/logoff.gif" align="absmiddle" height="16" width="16" alt="topmenu.logoffmessage" i18n:attr="alt" border="0"/>
111 </a>
112 </td>
113 </tr>
114 </table>
115 </td>
116 </tr>
117 <tr>
118 <td height="28" align="left" colspan="2">
119 <table cellpadding="0" cellspacing="0" border="0" height="28" width="100%">
120 <tr>
121 <td width="4">
122 <img src="/skin/images/empty.gif" width="4" height="1"/>
123 </td>
124 <td width="100%" class="nostyle">
125 <table cellspacing="0" cellpadding="0" height="28">
126 <tr>
127 <xsl:apply-templates select="/root/perspectives"/>
128 </tr>
129 </table>
130 </td>
131 <!-- tabs -->
132 <td align="right" valign="bottom" width="24">
133 <div id="waitImage" style="visibility:hidden; vertical-align: bottom;"><img src="/skin/images/clock_04.gif" width="24" height="24" border="0" align="bottom" style="margin-right: 10px;"/></div>
134 </td>
135 <td align="right" style="vertical-align: bottom;">
136 <img src="/skin/images/hippo_cms.gif" />
137 </td>
138 </tr>
139 </table>
140 </td>
141 </tr>
142 </table>
143 </body>
144
145 </html>
146
147 </xsl:template>
148
149 <xsl:template match="perspective">
150 <td align="left">
151 <table height="28" cellpadding="0" cellspacing="0" onclick="workbench.showMenu('{@id}');" border="0">
152 <tr>
153 <!-- volgende TD was uitgecommentarieerd... -->
154 <xsl:if test="position() = 2">
155 <td id="{@id}_left_edge" height="28" align="left" width="3" valign="top" class="tab_button_left_first">
156 <img src="/skin/images/empty.gif" width="3" height="28"/>
157 </td>
158 </xsl:if>
159 <td id="{@id}" class="tab_button" valign="top">
160 <img class="tab_icon" src="/skin/images/icons/24x24/{@icon}.gif" align="absmiddle"/><xsl:value-of select="@label"/>
161 </td>
162 <td id="{@id}_right_edge" align="right" valign="top" width="4">
163 <xsl:attribute name="class">
164 <xsl:choose>
165 <xsl:when test="not(following-sibling::perspective)">tab_button_right_last</xsl:when>
166 <xsl:otherwise>tab_button_right</xsl:otherwise>
167 </xsl:choose>
168 </xsl:attribute>
169 <img src="/skin/images/empty.gif">
170 <xsl:choose>
171 <xsl:when test="not(following-sibling::perspective)">
172 <xsl:attribute name="style">width: 4px;</xsl:attribute>
173 </xsl:when>
174 </xsl:choose>
175 </img>
176 </td>
177 </tr>
178 </table>
179 </td>
180 </xsl:template>
181
182 <xsl:template match="javascript">
183 <xsl:apply-templates/>
184 </xsl:template>
185
186 <xsl:template match="include">
187 <xsl:copy-of select="child::node()"/>
188 </xsl:template>
189
190 </xsl:stylesheet>