[xiph-commits] r3927 - in arkaiv/trunk: arkaiv/controllers arkaiv/lib arkaiv/model arkaiv/templates data/templates

dcrowdy at svn.annodex.net dcrowdy at svn.annodex.net
Thu May 14 23:03:32 PDT 2009


Author: dcrowdy
Date: 2009-05-14 23:03:31 -0700 (Thu, 14 May 2009)
New Revision: 3927

Modified:
   arkaiv/trunk/arkaiv/controllers/__init__.pyc
   arkaiv/trunk/arkaiv/controllers/error.pyc
   arkaiv/trunk/arkaiv/lib/base.pyc
   arkaiv/trunk/arkaiv/model/__init__.pyc
   arkaiv/trunk/arkaiv/model/cmmlparser.pyc
   arkaiv/trunk/arkaiv/model/oggzinfo.pyc
   arkaiv/trunk/arkaiv/templates/playlists.mak
   arkaiv/trunk/data/templates/addannodexform.mak.pyc
   arkaiv/trunk/data/templates/autohandler.pyc
   arkaiv/trunk/data/templates/collections.mak.pyc
   arkaiv/trunk/data/templates/displayitem.mak.py
   arkaiv/trunk/data/templates/displayitem.mak.pyc
   arkaiv/trunk/data/templates/mainpage.mak.pyc
Log:
Re-implemented playlist deletion


Modified: arkaiv/trunk/arkaiv/controllers/__init__.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/controllers/error.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/lib/base.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/model/__init__.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/model/cmmlparser.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/model/oggzinfo.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/arkaiv/templates/playlists.mak
===================================================================
--- arkaiv/trunk/arkaiv/templates/playlists.mak	2009-05-15 04:00:08 UTC (rev 3926)
+++ arkaiv/trunk/arkaiv/templates/playlists.mak	2009-05-15 06:03:31 UTC (rev 3927)
@@ -3,11 +3,19 @@
 Playlists
 </h2>
 
+<table>
 % for p in c.playlists:
-<li>
-${ h.link_to(p['name'], h.url_for(action="displayplaylist", id=p['index'], name=p['name']))}
-</li>
+<tr>
+<td>${ h.link_to(p['name'], h.url_for(action="displayplaylist", id=p['index'], name=p['name']))}</td>
+${ h.form(h.url_for(action='deleteplaylist'), multipart=True) }
+<td>
+${ h.submit('Delete') }
+</td>
+${ h.hidden_field('playlistname', value=p['name']) }
+${ h.end_form() } 
+</tr>
 % endfor
+<table>
 
 <hr>
 Add new playlist:

Modified: arkaiv/trunk/data/templates/addannodexform.mak.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/data/templates/autohandler.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/data/templates/collections.mak.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/data/templates/displayitem.mak.py
===================================================================
--- arkaiv/trunk/data/templates/displayitem.mak.py	2009-05-15 04:00:08 UTC (rev 3926)
+++ arkaiv/trunk/data/templates/displayitem.mak.py	2009-05-15 06:03:31 UTC (rev 3927)
@@ -3,8 +3,8 @@
 __M_dict_builtin = dict
 __M_locals_builtin = locals
 _magic_number = 5
-_modified_time = 1241694262.4571321
-_template_filename='/home/dcrowdy/src/arkaiv/trunk/arkaiv/templates/displayitem.mak'
+_modified_time = 1242363498.105473
+_template_filename='/home/dcrowdy/src/arkaiv/working/trunk/arkaiv/templates/displayitem.mak'
 _template_uri='/displayitem.mak'
 _template_cache=cache.Cache(__name__, _modified_time)
 _source_encoding=None
@@ -56,7 +56,7 @@
             __M_writer(u"<video src='")
             __M_writer(unicode(c.sourcedict['urlpath']))
             __M_writer(unicode(c.sourcedict['clipdetail']))
-            __M_writer(u'\' controls=\'controls\' ontimeupdate="Vupdatetime()" width=320 height=240></video>\n')
+            __M_writer(u'\' controls=\'controls\' ontimeupdate="Updatetime()" width=320 height=240></video>\n')
         # SOURCE LINE 21
         __M_writer(u'\n')
         # SOURCE LINE 22
@@ -65,219 +65,235 @@
             __M_writer(u"<audio src='")
             __M_writer(unicode(c.sourcedict['urlpath']))
             __M_writer(unicode(c.sourcedict['clipdetail']))
-            __M_writer(u'\' controls=\'controls\' ontimeupdate="Aupdatetime()"></audio>\n')
+            __M_writer(u'\' controls=\'controls\' ontimeupdate="Updatetime()"></audio>\n')
         # SOURCE LINE 25
-        __M_writer(u'\n\n')
-        # SOURCE LINE 28
-        __M_writer(u'<form name="api">\n<table style="font-size:small">\n<tr>\n<td>Time:</td>\n<td><input name="tfield" cols="10"></textarea></td>\n</tr>\n')
-        # SOURCE LINE 38
+        __M_writer(u'\n\n<form name="api">\n<table style="font-size:small">\n<tr>\n<td>Time:</td>\n<td><input name="tfield" cols="8"></textarea></td>\n<td>Go to:</td>\n<td><input name="gfield" cols="6" onchange=\'Gototime("')
+        # SOURCE LINE 33
+        __M_writer(unicode(c.sourcedict['urlpath']))
+        __M_writer(u'?t=")\'></textarea></td>\n</tr>\n')
+        # SOURCE LINE 40
         __M_writer(u'</table>\n</form>\n\n')
-        # SOURCE LINE 42
+        # SOURCE LINE 44
         __M_writer(u'<hr>\nHead:\n')
-        # SOURCE LINE 44
+        # SOURCE LINE 46
         __M_writer(unicode( h.form(h.url_for(action='editheadinfo'), multipart=True) ))
         __M_writer(u'\nid:\n')
-        # SOURCE LINE 46
+        # SOURCE LINE 48
         __M_writer(unicode( h.text_field('headid', value=c.headdict['id']) ))
         __M_writer(u'\nTitle:\n')
-        # SOURCE LINE 48
+        # SOURCE LINE 50
         __M_writer(unicode( h.text_field('headtitle', value=c.headdict['title']) ))
         __M_writer(u'\n')
-        # SOURCE LINE 49
+        # SOURCE LINE 51
         __M_writer(unicode( h.hidden_field('itemid', value=c.itemid) ))
         __M_writer(u'\n\n')
-        # SOURCE LINE 51
+        # SOURCE LINE 53
         __M_writer(unicode( h.submit('Edit') ))
         __M_writer(u' \n')
-        # SOURCE LINE 52
+        # SOURCE LINE 54
         __M_writer(unicode( h.end_form() ))
         __M_writer(u' \n<br />\n<hr>\n\nMeta information:<br />\n<table style="font-size:small">\n<tr>\n  <td>Name</td>\n  <td>Content</td>\n</tr>\n')
-        # SOURCE LINE 62
+        # SOURCE LINE 64
         for metainfo in c.metalist:
-            # SOURCE LINE 63
+            # SOURCE LINE 65
             __M_writer(u'<tr>\n<td>\n<p id="editmetaname">')
-            # SOURCE LINE 65
+            # SOURCE LINE 67
             __M_writer(unicode(metainfo['name']))
             __M_writer(u'</p>\n<script type="text/javascript">\n new Ajax.InPlaceEditor(\'editmetaname\', \'/page/editheadmetaname\', { callback: function(form, value) { return \'id=')
-            # SOURCE LINE 67
+            # SOURCE LINE 69
             __M_writer(unicode(metainfo['id']))
             __M_writer(u'&field=name&itemid=')
             __M_writer(unicode(c.itemid))
             __M_writer(u'&myparam=\' + escape(value) }});\n</script>\n</td>\n<td>\n<p id="editmetacontent">')
-            # SOURCE LINE 71
+            # SOURCE LINE 73
             __M_writer(unicode(metainfo['content']))
             __M_writer(u'</p>\n<script type="text/javascript">\n new Ajax.InPlaceEditor(\'editmetacontent\', \'/page/editheadmetaname\', { callback: function(form, value) { return \'id=')
-            # SOURCE LINE 73
+            # SOURCE LINE 75
             __M_writer(unicode(metainfo['id']))
             __M_writer(u'&field=content&itemid=')
             __M_writer(unicode(c.itemid))
             __M_writer(u"&myparam=' + escape(value) }});\n</script>\n</td>\n<td>\n")
-            # SOURCE LINE 77
+            # SOURCE LINE 79
             __M_writer(unicode( h.form(h.url_for(action='deletemeta'), multipart=True) ))
             __M_writer(u'\n')
-            # SOURCE LINE 78
+            # SOURCE LINE 80
             __M_writer(unicode( h.submit('Delete') ))
             __M_writer(u'\n')
-            # SOURCE LINE 79
+            # SOURCE LINE 81
             __M_writer(unicode( h.hidden_field('metaid', value=metainfo['index']) ))
             __M_writer(u'\n')
-            # SOURCE LINE 80
+            # SOURCE LINE 82
             __M_writer(unicode( h.hidden_field('itemid', value=c.itemid) ))
             __M_writer(u'\n')
-            # SOURCE LINE 81
+            # SOURCE LINE 83
             __M_writer(unicode( h.hidden_field('headid', value=c.headdict['index']) ))
             __M_writer(u'\n')
-            # SOURCE LINE 82
+            # SOURCE LINE 84
             __M_writer(unicode( h.end_form() ))
             __M_writer(u' \n\n</td>\n</tr> \n')
-        # SOURCE LINE 87
+        # SOURCE LINE 89
         __M_writer(u'</table>\n<hr>\nAdd new meta tag:\n')
-        # SOURCE LINE 90
+        # SOURCE LINE 92
         __M_writer(unicode( h.form(h.url_for(action='addmetainfo'), multipart=True) ))
         __M_writer(u'\n<table style="font-size:small">\n<tr>\n    <td>Id</td>\n    <td>Name</td>\n    <td>Content</td>\n</tr>\n\n<tr>\n  <td>')
-        # SOURCE LINE 99
+        # SOURCE LINE 101
         __M_writer(unicode( h.text_field('metaid', size=5) ))
         __M_writer(u'</td>\n  <td>')
-        # SOURCE LINE 100
+        # SOURCE LINE 102
         __M_writer(unicode( h.text_field('metaname') ))
         __M_writer(u'</td>\n  <td>')
-        # SOURCE LINE 101
+        # SOURCE LINE 103
         __M_writer(unicode( h.text_field('metacontent') ))
         __M_writer(u'</td>\n</tr>\n</table>\n')
-        # SOURCE LINE 104
+        # SOURCE LINE 106
         __M_writer(unicode( h.hidden_field('metascheme') ))
         __M_writer(u'\n')
-        # SOURCE LINE 105
+        # SOURCE LINE 107
         __M_writer(unicode( h.hidden_field('headindex', value = c.headdict['index']) ))
         __M_writer(u'\n')
-        # SOURCE LINE 106
+        # SOURCE LINE 108
         __M_writer(unicode( h.hidden_field('itemid', value=c.itemid) ))
         __M_writer(u'\n\n')
-        # SOURCE LINE 108
+        # SOURCE LINE 110
         __M_writer(unicode( h.submit('Add') ))
         __M_writer(u' \n')
-        # SOURCE LINE 109
+        # SOURCE LINE 111
         __M_writer(unicode( h.end_form() ))
         __M_writer(u' \n\n<hr>\n\n\n<!--div class="sourceinfo"-->\n<table style="font-size:small">\n<tr>\n<td>Duration:</td><td> ')
-        # SOURCE LINE 117
+        # SOURCE LINE 119
         __M_writer(unicode(c.sourcedict['duration']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Bitrate: </td><td>')
-        # SOURCE LINE 120
+        # SOURCE LINE 122
         __M_writer(unicode(c.sourcedict['bitrate']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Resolution: </td><td>')
-        # SOURCE LINE 123
+        # SOURCE LINE 125
         __M_writer(unicode(c.sourcedict['resolution']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Framerate: </td><td>')
-        # SOURCE LINE 126
+        # SOURCE LINE 128
         __M_writer(unicode(c.sourcedict['framerate']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Audio: </td><td>')
-        # SOURCE LINE 129
+        # SOURCE LINE 131
         __M_writer(unicode(c.sourcedict['audio']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Has video: </td><td>')
-        # SOURCE LINE 132
+        # SOURCE LINE 134
         __M_writer(unicode(c.sourcedict['has_video']))
         __M_writer(u'</td>\n</tr>\n<tr>\n<td>Has audio: </td><td>')
-        # SOURCE LINE 135
+        # SOURCE LINE 137
         __M_writer(unicode(c.sourcedict['has_audio']))
         __M_writer(u'</td>\n</tr>\n</table>\n\n\n\n</div>\n\n<table style="font-size:small">\n<tr>\n  <td></td>\n  <td>Time</td>\n  <td></td>\n  <td></td> \n</tr>\n\n')
-        # SOURCE LINE 151
+        # SOURCE LINE 153
         for clipinfo in c.cliplist:
-            # SOURCE LINE 152
+            # SOURCE LINE 154
             __M_writer(u'<tr>\n')
-            # SOURCE LINE 153
+            # SOURCE LINE 155
             if c.sourcedict['has_video'] == "Yes":
-                # SOURCE LINE 154
-                __M_writer(u'   <td><a onclick=\'VideoClipPlay("')
-                __M_writer(unicode(c.sourcedict['urlpath']))
-                __M_writer(u'?t=')
-                __M_writer(unicode(clipinfo['id']))
-                __M_writer(u'")\'><img src="')
-                __M_writer(unicode(c.sourcedict['clipimageurl']))
-                __M_writer(unicode(clipinfo['img_src']))
-                __M_writer(u'"></a></td>\n')
-            # SOURCE LINE 156
+                # SOURCE LINE 156
+                if clipinfo['end_time'] == 0:
+                    # SOURCE LINE 157
+                    __M_writer(u'   <td><a onclick=\'ClipPlay("')
+                    __M_writer(unicode(c.sourcedict['urlpath']))
+                    __M_writer(u'?t=')
+                    __M_writer(unicode(clipinfo['id']))
+                    __M_writer(u'")\'><img src="')
+                    __M_writer(unicode(c.sourcedict['clipimageurl']))
+                    __M_writer(unicode(clipinfo['img_src']))
+                    __M_writer(u'"></a></td>\n')
+                    # SOURCE LINE 158
+                else:
+                    # SOURCE LINE 159
+                    __M_writer(u'   <td><a onclick=\'ClipPlay("')
+                    __M_writer(unicode(c.sourcedict['urlpath']))
+                    __M_writer(u'?t=')
+                    __M_writer(unicode(clipinfo['id']))
+                    __M_writer(u'/')
+                    __M_writer(unicode(clipinfo['end_time']))
+                    __M_writer(u'")\'><img src="')
+                    __M_writer(unicode(c.sourcedict['clipimageurl']))
+                    __M_writer(unicode(clipinfo['img_src']))
+                    __M_writer(u'"></a></td>\n')
+            # SOURCE LINE 162
             __M_writer(u'\n')
-            # SOURCE LINE 157
+            # SOURCE LINE 163
             if c.sourcedict['has_video'] == "No":
-                # SOURCE LINE 158
+                # SOURCE LINE 164
                 if clipinfo['end_time'] == 0:
-                    # SOURCE LINE 159
-                    __M_writer(u'   <td><a onclick=\'AudioClipPlay("')
+                    # SOURCE LINE 165
+                    __M_writer(u'   <td><a onclick=\'ClipPlay("')
                     __M_writer(unicode(c.sourcedict['urlpath']))
                     __M_writer(u'?t=')
                     __M_writer(unicode(clipinfo['id']))
                     __M_writer(u'")\'><img src="/images/blank.png"></a></td>\n')
-                    # SOURCE LINE 160
+                    # SOURCE LINE 166
                 else:
-                    # SOURCE LINE 161
-                    __M_writer(u'   <td><a onclick=\'AudioClipPlay("')
+                    # SOURCE LINE 167
+                    __M_writer(u'   <td><a onclick=\'ClipPlay("')
                     __M_writer(unicode(c.sourcedict['urlpath']))
                     __M_writer(u'?t=')
                     __M_writer(unicode(clipinfo['id']))
                     __M_writer(u'/')
                     __M_writer(unicode(clipinfo['end_time']))
                     __M_writer(u'")\'><img src="/images/blank.png"></a></td>\n')
-            # SOURCE LINE 164
+            # SOURCE LINE 170
             __M_writer(u'\n    <td>')
-            # SOURCE LINE 165
+            # SOURCE LINE 171
             __M_writer(unicode(clipinfo['start_time']))
             __M_writer(u'</td>\n    <td>')
-            # SOURCE LINE 166
+            # SOURCE LINE 172
             __M_writer(unicode(clipinfo['desc']))
             __M_writer(u'</td>\n    <td>')
-            # SOURCE LINE 167
+            # SOURCE LINE 173
             __M_writer(unicode(clipinfo['a_href']))
             __M_writer(u'</td>\n\n')
-            # SOURCE LINE 169
+            # SOURCE LINE 175
             __M_writer(unicode( h.form(h.url_for(action='deleteclip'), multipart=True) ))
             __M_writer(u'\n<td>')
-            # SOURCE LINE 170
+            # SOURCE LINE 176
             __M_writer(unicode( h.submit('Delete') ))
             __M_writer(u' </td>\n')
-            # SOURCE LINE 171
+            # SOURCE LINE 177
             __M_writer(unicode( h.hidden_field('clipid', value=clipinfo['ixc']) ))
             __M_writer(u'\n')
-            # SOURCE LINE 172
+            # SOURCE LINE 178
             __M_writer(unicode( h.hidden_field('itemid', value=c.itemid) ))
             __M_writer(u'\n')
-            # SOURCE LINE 173
+            # SOURCE LINE 179
             __M_writer(unicode( h.end_form() ))
             __M_writer(u' \n\n</tr> \n')
-        # SOURCE LINE 177
+        # SOURCE LINE 183
         __M_writer(u'</table>\n\nAdd new clip:\n<!--')
-        # SOURCE LINE 180
+        # SOURCE LINE 186
         __M_writer(unicode( h.form(h.url_for(action='addclip'), multipart=True) ))
         __M_writer(u'-->\n<form name="addaclip" action="addclip" >\n<table style="font-size:small">\n<tr>\n    <td>Start</td>\n  <td>')
-        # SOURCE LINE 185
+        # SOURCE LINE 191
         __M_writer(unicode( h.text_field('starttime', size=5) ))
         __M_writer(u'</td>\n</tr>\n<tr>\n<tr>\n    <td>End</td>\n  <td>')
-        # SOURCE LINE 190
+        # SOURCE LINE 196
         __M_writer(unicode( h.text_field('endtime', size=5) ))
         __M_writer(u'</td>\n</tr>\n<td>Desc</td>\n  <td>\n  <input type="text" name="desc" size="20" onfocus="disableShortcuts()" onblur="enableShortcuts()" id="desc" />\n  <!--')
-        # SOURCE LINE 195
+        # SOURCE LINE 201
         __M_writer(unicode( h.text_field('desc') ))
         __M_writer(u'--></td>\n</tr>\n<tr>\n    <td>a_text</td>\n  <td>')
-        # SOURCE LINE 199
+        # SOURCE LINE 205
         __M_writer(unicode( h.text_field('a_text') ))
         __M_writer(u'</td>\n</tr>\n<tr>\n    <td>a_href</td>\n  <td>')
-        # SOURCE LINE 203
+        # SOURCE LINE 209
         __M_writer(unicode( h.text_field('a_href') ))
         __M_writer(u'</td>\n</tr>\n</table>\n')
-        # SOURCE LINE 206
+        # SOURCE LINE 212
         __M_writer(unicode( h.hidden_field('headindex', value = c.headdict['index']) ))
         __M_writer(u'\n')
-        # SOURCE LINE 207
+        # SOURCE LINE 213
         __M_writer(unicode( h.hidden_field('itemid', value=c.itemid) ))
         __M_writer(u'\n')
-        # SOURCE LINE 208
+        # SOURCE LINE 214
         __M_writer(unicode( h.hidden_field('hasvideo', value=c.sourcedict['has_video']) ))
         __M_writer(u'\n')
-        # SOURCE LINE 209
+        # SOURCE LINE 215
         __M_writer(unicode( h.submit('Add') ))
         __M_writer(u' \n')
-        # SOURCE LINE 210
+        # SOURCE LINE 216
         __M_writer(unicode( h.end_form() ))
-        __M_writer(u' \n\n\n<script>\n\nvar output = document.api.ofield;\nvar toutput = document.api.tfield;\nvar myVideo = document.getElementsByTagName(\'video\')[0];\nvar myAudio = document.getElementsByTagName(\'audio\')[0];\n\nv.addEventListener("seeked", function() { document.getElementsByTagName("video")[0].play(); }, true);\n\nfunction VideoClipPlay(location) {\n  myVideo.src = location\n  myVideo.load();\n  myVideo.play();\n  //addOutput("Video clip");\n}\n\n\nfunction AudioClipPlay(location) {\n  myAudio.src = location\n  myAudio.load();\n  myAudio.play();\n  //addOutput("Audio clip");\n \n}\n\nfunction Vupdatetime() {\n  addToutput(myVideo.currentTime);\n}\n\nfunction Aupdatetime() {\n  addToutput(myAudio.currentTime);\n}\n\nfunction addToutput(str) {\n  toutput.value = str;\n}\n\nvar outLines = 0;\n\nfunction addOutput(str) {\n  if (outLines == 0) {\n    output.value = str;\n  } else {\n    output.value = str + "\\n" + output.value;\n  }\n  outLines++;\n  if (ou
 tLines == 11) {\n    i = output.value.lastIndexOf("\\n");\n    output.value = output.value.substr(0, i);\n    outLines--;\n  }\n\n}\n</script>\n\n\n')
+        __M_writer(u' \n\n\n<script>\n\nvar output = document.api.ofield;\nvar toutput = document.api.tfield;\nvar gototime = document.api.gfield;\nvar myVideo = document.getElementsByTagName(\'video\')[0];\nvar myAudio = document.getElementsByTagName(\'audio\')[0];\n\nif (myAudio) {\n//  addOutput("Audio");\n  myMedia = myAudio;\n}\nelse {\n//  addOutput("Video");\n  myMedia = myVideo;\n}\n\nv.addEventListener("seeked", function() { document.getElementsByTagName("video")[0].play(); }, true);\n\nfunction ClipPlay(location) {\n  myMedia.src = location\n  myMedia.load();\n  myMedia.play();\n  //addOutput("Audio clip");\n}\n\nfunction Updatetime() {\n  addToutput(myMedia.currentTime);\n}\n\nfunction addToutput(str) {\n  toutput.value = str;\n}\n\nfunction Gototime(location) {\n  t = getGoto();\n//  addOutput(location + t);\n  myMedia.src = location + t;\n  myMedia.load();\n  myMedia.play();\n}\n\nfunction getGoto() {\n  i = parseInt(gototime.value);\n  return isNaN(i) ? 0 : i;\
 n}\n\nvar outLines = 0;\n\nfunction addOutput(str) {\n  if (outLines == 0) {\n    output.value = str;\n  } else {\n    output.value = str + "\\n" + output.value;\n  }\n  outLines++;\n  if (outLines == 11) {\n    i = output.value.lastIndexOf("\\n");\n    output.value = output.value.substr(0, i);\n    outLines--;\n  }\n\n}\n</script>\n\n\n')
         return ''
     finally:
         context.caller_stack._pop_frame()

Modified: arkaiv/trunk/data/templates/displayitem.mak.pyc
===================================================================
(Binary files differ)

Modified: arkaiv/trunk/data/templates/mainpage.mak.pyc
===================================================================
(Binary files differ)



More information about the commits mailing list