← Back to team overview

yade-dev team mailing list archive

[Branch ~yade-pkg/yade/git-trunk] Rev 3747: Drop old commented stuff in python-scrips.

 

------------------------------------------------------------
revno: 3747
committer: Anton Gladky <gladky.anton@xxxxxxxxx>
timestamp: Thu 2015-12-03 18:42:44 +0100
message:
  Drop old commented stuff in python-scrips.
modified:
  core/main/yade-batch.in
  doc/sphinx/book/confManual.py
  doc/sphinx/book/confReference.py
  doc/sphinx/book/confTheory.py
  doc/sphinx/conf.py
  gui/qt4/__init__.py
  gui/qt5/__init__.py
  py/plot.py


--
lp:yade
https://code.launchpad.net/~yade-pkg/yade/git-trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-pkg/yade/git-trunk/+edit-subscription
=== modified file 'core/main/yade-batch.in'
--- core/main/yade-batch.in	2014-05-27 11:24:16 +0000
+++ core/main/yade-batch.in	2015-12-03 17:42:44 +0000
@@ -115,13 +115,6 @@
 		ret+='<td>%d%s</td>'%(self.nCores,(' ('+','.join([str(c) for c in self.cores])+')') if self.cores and self.status=='RUNNING' else '')
 		# TODO: make clickable so that it can be served full-size
 		if os.path.exists(self.plotsFile):
-			if 0: pass
-				## all this mess to embed SVG; clicking on it does not work, though
-				## question posted at http://www.abclinuxu.cz/poradna/linux/show/314041
-				## see also http://www.w3schools.com/svg/svg_inhtml.asp and http://dutzend.blogspot.com/2010/04/svg-im-anklickbar-machen.html
-				#img='<object data="/jobs/%d/plots" type="%s" width="300px" alt="[plots]"/>'%(self.num,yade.remote.plotImgMimetype)
-				#img='<iframe src="/jobs/%d/plots" type="%s" width="300px" alt="[plots]"/>'%(self.num,yade.remote.plotImgMimetype)
-				#img='<embed src="/jobs/%d/plots" type="%s" width="300px" alt="[plots]"/>'%(self.num,yade.remote.plotImgMimetype)a
 			img='<img src="/jobs/%d/plots" width="300px" alt="[plots]">'%(self.num)
 			ret+='<td><a href="/jobs/%d/plots">%s</a></td>'%(self.num,img)
 		else: ret+='<td> (no plots) </td>'

=== modified file 'doc/sphinx/book/confManual.py'
--- doc/sphinx/book/confManual.py	2015-11-20 00:42:30 +0000
+++ doc/sphinx/book/confManual.py	2015-12-03 17:42:44 +0000
@@ -102,12 +102,6 @@
 	else:
 		uri=(('%%yade.wrapper#yade.wrapper.%s'%target) if writer=='latex' else 'yade.wrapper.html#yade.wrapper.%s'%target)
 		#print writer,uri
-	if 0:
-		refnode=addnodes.pending_xref(rawtext,reftype=role,refexplicit=explicitText,reftarget=target)
-		#refnode.line=lineno
-		#refnode+=nodes.literal(rawtext,text,classes=['ref',role])
-		return [refnode],[]
-		#ret.rawtext,reftype=role,
 	else:
 		return nodes.reference(rawtext,docutils.utils.unescape(text),refuri=uri,**options)
 	#return [refnode],[]

=== modified file 'doc/sphinx/book/confReference.py'
--- doc/sphinx/book/confReference.py	2015-11-20 00:42:30 +0000
+++ doc/sphinx/book/confReference.py	2015-12-03 17:42:44 +0000
@@ -102,12 +102,6 @@
 	else:
 		uri=(('%%yade.wrapper#yade.wrapper.%s'%target) if writer=='latex' else 'yade.wrapper.html#yade.wrapper.%s'%target)
 		#print writer,uri
-	if 0:
-		refnode=addnodes.pending_xref(rawtext,reftype=role,refexplicit=explicitText,reftarget=target)
-		#refnode.line=lineno
-		#refnode+=nodes.literal(rawtext,text,classes=['ref',role])
-		return [refnode],[]
-		#ret.rawtext,reftype=role,
 	else:
 		return nodes.reference(rawtext,docutils.utils.unescape(text),refuri=uri,**options)
 	#return [refnode],[]

=== modified file 'doc/sphinx/book/confTheory.py'
--- doc/sphinx/book/confTheory.py	2015-11-20 00:42:30 +0000
+++ doc/sphinx/book/confTheory.py	2015-12-03 17:42:44 +0000
@@ -102,12 +102,6 @@
 	else:
 		uri=(('%%yade.wrapper#yade.wrapper.%s'%target) if writer=='latex' else 'yade.wrapper.html#yade.wrapper.%s'%target)
 		#print writer,uri
-	if 0:
-		refnode=addnodes.pending_xref(rawtext,reftype=role,refexplicit=explicitText,reftarget=target)
-		#refnode.line=lineno
-		#refnode+=nodes.literal(rawtext,text,classes=['ref',role])
-		return [refnode],[]
-		#ret.rawtext,reftype=role,
 	else:
 		return nodes.reference(rawtext,docutils.utils.unescape(text),refuri=uri,**options)
 	#return [refnode],[]

=== modified file 'doc/sphinx/conf.py'
--- doc/sphinx/conf.py	2015-11-20 00:42:30 +0000
+++ doc/sphinx/conf.py	2015-12-03 17:42:44 +0000
@@ -102,12 +102,6 @@
 	else:
 		uri=(('%%yade.wrapper#yade.wrapper.%s'%target) if writer=='latex' else 'yade.wrapper.html#yade.wrapper.%s'%target)
 		#print writer,uri
-	if 0:
-		refnode=addnodes.pending_xref(rawtext,reftype=role,refexplicit=explicitText,reftarget=target)
-		#refnode.line=lineno
-		#refnode+=nodes.literal(rawtext,text,classes=['ref',role])
-		return [refnode],[]
-		#ret.rawtext,reftype=role,
 	else:
 		return nodes.reference(rawtext,docutils.utils.unescape(text),refuri=uri,**options)
 	#return [refnode],[]

=== modified file 'gui/qt4/__init__.py'
--- gui/qt4/__init__.py	2013-12-04 21:49:34 +0000
+++ gui/qt4/__init__.py	2015-12-03 17:42:44 +0000
@@ -56,15 +56,6 @@
 		else: webWindows=webWindows[1:]+[webWindows[0]]
 	web=webWindows[-1]
 	web.load(QUrl(url)); web.setWindowTitle(url);
-	if 0:
-		def killSidebar(result):
-			frame=web.page().mainFrame()
-			frame.evaluateJavaScript("var bv=$('.bodywrapper'); bv.css('margin','0 0 0 0');")
-			frame.evaluateJavaScript("var sbw=$('.sphinxsidebarwrapper'); sbw.css('display','none');")
-			frame.evaluateJavaScript("var sb=$('.sphinxsidebar'); sb.css('display','none'); ")
-			frame.evaluateJavaScript("var sb=$('.sidebar'); sb.css('width','0px'); ")
-			web.loadFinished.disconnect(killSidebar)
-		web.loadFinished.connect(killSidebar)
 	web.show();	web.raise_()
 
 

=== modified file 'gui/qt5/__init__.py'
--- gui/qt5/__init__.py	2015-08-27 09:47:31 +0000
+++ gui/qt5/__init__.py	2015-12-03 17:42:44 +0000
@@ -59,15 +59,6 @@
 		else: webWindows=webWindows[1:]+[webWindows[0]]
 	web=webWindows[-1]
 	web.load(QUrl(url)); web.setWindowTitle(url);
-	if 0:
-		def killSidebar(result):
-			frame=web.page().mainFrame()
-			frame.evaluateJavaScript("var bv=$('.bodywrapper'); bv.css('margin','0 0 0 0');")
-			frame.evaluateJavaScript("var sbw=$('.sphinxsidebarwrapper'); sbw.css('display','none');")
-			frame.evaluateJavaScript("var sb=$('.sphinxsidebar'); sb.css('display','none'); ")
-			frame.evaluateJavaScript("var sb=$('.sidebar'); sb.css('width','0px'); ")
-			web.loadFinished.disconnect(killSidebar)
-		web.loadFinished.connect(killSidebar)
 	web.show();	web.raise_()
 
 

=== modified file 'py/plot.py'
--- py/plot.py	2015-12-03 17:42:44 +0000
+++ py/plot.py	2015-12-03 17:42:44 +0000
@@ -604,16 +604,6 @@
 		# pylab.show() # this blocks for some reason; call show on figures directly
 		for f in figs:
 			f.show()
-			# should have fixed https://bugs.launchpad.net/yade/+bug/606220, but does not work apparently
-			if 0:
-				import matplotlib.backend_bases
-				if 'CloseEvent' in dir(matplotlib.backend_bases):
-					def closeFigureCallback(event):
-						ff=event.canvas.figure
-						# remove closed axes from our update list
-						global currLineRefs
-						currLineRefs=[l for l in currLineRefs if l.line.axes.get_figure()!=ff] 
-					f.canvas.mpl_connect('close_event',closeFigureCallback)
 	else:
 		figs=list(set([l.line.get_figure() for l in currLineRefs]))
 		if len(figs)==1: return figs[0]