changeset 698:0c9cd543daac

Merge with main.
author Alexander Schremmer <alex AT alexanderweb DOT de>
date Tue, 16 May 2006 14:56:03 +0200
parents 699f9301ede0 (current diff) e420833c5f08 (diff)
children ea6dab2f43f7
files
diffstat 8 files changed, 17 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/converter/text_html_text_x_moin.py	Tue May 16 14:41:17 2006 +0200
+++ b/MoinMoin/converter/text_html_text_x_moin.py	Tue May 16 14:56:03 2006 +0200
@@ -1093,6 +1093,8 @@
                 else: 
                     raise ConvertError("Invalid InterWiki link: '%s'" % href)
             elif class_ == "badinterwiki" and title:
+                if href == "/": # we used this as replacement for empty href
+                    href = ""
                 pagename = href
                 interwikiname = "%s:%s" % (title, href)
             if interwikiname and pagename == text: 
--- a/MoinMoin/formatter/text_gedit.py	Tue May 16 14:41:17 2006 +0200
+++ b/MoinMoin/formatter/text_gedit.py	Tue May 16 14:56:03 2006 +0200
@@ -53,7 +53,7 @@
         if not on:
             return self.url(0) # return '</a>'
         html_class = 'badinterwiki' # we use badinterwiki in any case to simplify reverse conversion
-        href = wikiutil.quoteWikinameURL(pagename)
+        href = wikiutil.quoteWikinameURL(pagename) or "/" # FCKeditor behaves strange on empty href
         title = kw.get('title', interwiki)
         return self.url(1, href, title=title, do_escape=1, css=html_class) # interwiki links with pages with umlauts
 
--- a/MoinMoin/request/TWISTED.py	Tue May 16 14:41:17 2006 +0200
+++ b/MoinMoin/request/TWISTED.py	Tue May 16 14:56:03 2006 +0200
@@ -9,7 +9,7 @@
 import sys, os
 
 from MoinMoin import config
-from MoinMoin.request import RequestBase
+from MoinMoin.request import RequestBase, MoinMoinFinish
 
 class Request(RequestBase):
     """ specialized on Twisted requests """
--- a/MoinMoin/support/htmlmarkup.py	Tue May 16 14:41:17 2006 +0200
+++ b/MoinMoin/support/htmlmarkup.py	Tue May 16 14:56:03 2006 +0200
@@ -204,6 +204,8 @@
         'span', 'src', 'start', 'style', 'summary', 'tabindex',
         'target', 'title', 'type', 'usemap', 'valign', 'value',
         'vspace', 'width'])
+    ignore_tags = frozenset(['html', 'body'])
+    
     uri_attrs = frozenset(['action', 'background', 'dynsrc', 'href',
                            'lowsrc', 'src'])
     safe_schemes = frozenset(['file', 'ftp', 'http', 'https', 'mailto',
@@ -217,6 +219,9 @@
     def handle_starttag(self, tag, attrs):
         if self.waiting_for:
             return
+        if tag in self.ignore_tags:
+            return
+        
         if tag not in self.safe_tags:
             self.waiting_for = tag
             return
@@ -268,6 +273,9 @@
             self.out.write(escape(data, quotes=False))
 
     def handle_endtag(self, tag):
+        if tag in self.ignore_tags:
+            return
+
         if self.waiting_for:
             if self.waiting_for == tag:
                 self.waiting_for = None
--- a/docs/CHANGES	Tue May 16 14:41:17 2006 +0200
+++ b/docs/CHANGES	Tue May 16 14:56:03 2006 +0200
@@ -65,6 +65,7 @@
     * on action "info" page, "revert" link will not be displayed for empty page
       revisions (but you just can delete the current page to get an empty rev.)
     * fix vanishing strike markup after gui editor usage
+    * fix deletion of empty Interwiki links ([wiki:MoinMaster: mm entry page])
 
 Version 1.5.current:
   Developer notes:
--- a/setup.py	Tue May 16 14:41:17 2006 +0200
+++ b/setup.py	Tue May 16 14:56:03 2006 +0200
@@ -204,7 +204,7 @@
         'MoinMoin.logfile',
         'MoinMoin.macro',
         'MoinMoin.parser',
-        'MoinMoin.processor',
+        'MoinMoin.request',
         'MoinMoin.script',
         'MoinMoin.script.account',
         'MoinMoin.script.cli',
--- a/wiki/server/moinmodpy.htaccess	Tue May 16 14:41:17 2006 +0200
+++ b/wiki/server/moinmodpy.htaccess	Tue May 16 14:56:03 2006 +0200
@@ -39,6 +39,6 @@
 #  PythonPath "['/path/to/moin/lib/python','/path/to/wikiconfig']+sys.path"
 #
 #  # choose the ModPy Request class as handler
-#  PythonHandler MoinMoin.request.MODPY::Request.run
+#  PythonHandler MoinMoin.request.MODPYTHON::Request.run
 #
 #</Files>
--- a/wiki/server/moinmodpy.py	Tue May 16 14:41:17 2006 +0200
+++ b/wiki/server/moinmodpy.py	Tue May 16 14:56:03 2006 +0200
@@ -54,9 +54,9 @@
 del config
 
 
-from MoinMoin.request import MODPY
+from MoinMoin.request import MODPYTHON
 
 def handler(request):
-    moinreq = MODPY.Request(request)
+    moinreq = MODPYTHON.Request(request)
     return moinreq.run(request)