diff MoinMoin/theme/__init__.py @ 515:1b9f0d6b9f48

fixed double CSS class attribute for nonexistent links, removed ugly formatter.url attrs keyword handling code imported from: moin--main--1.5--patch-519
author Thomas Waldmann <tw@waldmann-edv.de>
date Tue, 28 Mar 2006 21:52:01 +0000
parents 3ede5fa7001a
children 6c572f52899f
line wrap: on
line diff
--- a/MoinMoin/theme/__init__.py	Tue Mar 28 19:47:18 2006 +0000
+++ b/MoinMoin/theme/__init__.py	Tue Mar 28 21:52:01 2006 +0000
@@ -467,7 +467,7 @@
         d['title'] = title % d
         d['i18ntitle'] = self.request.getText(d['title'], formatted=False)
         img_src = self.make_icon(icon, d)
-        return wikiutil.link_tag(self.request, page_params % d, img_src, attrs='title="%(i18ntitle)s"' % d)
+        return wikiutil.link_tag(self.request, page_params % d, img_src, title="%(i18ntitle)s" % d)
 
     def msg(self, d):
         """ Assemble the msg display
@@ -1089,18 +1089,18 @@
         if self.showBothEditLinks() and guiworks:
             text = _('Edit (Text)', formatted=False)
             params = params + 'text'
-            attrs = 'name="texteditlink"'
+            attrs = {'name': "texteditlink"}
         else:
             text = _('Edit', formatted=False)
             if guiworks:
                 # 'textonly' will be upgraded dynamically to 'guipossible' by JS
                 params = params + 'textonly'
-                attrs = 'name="editlink"'
+                attrs = {'name': "editlink"}
             else:
                 params = params + 'text'
-                attrs = 'name="texteditlink"'
+                attrs = {'name': "texteditlink"}
         
-        return wikiutil.link_tag(self.request, params, text, attrs=attrs)
+        return wikiutil.link_tag(self.request, params, text, **attrs)
 
     def showBothEditLinks(self):
         """ Return True if both edit links should be displayed """