[Avida-cvs] [avida-svn] r472 - branches/developers/avida-edward/source/python/AvidaGui2
baerb@myxo.css.msu.edu
baerb at myxo.css.msu.edu
Wed Feb 15 13:04:14 PST 2006
Author: baerb
Date: 2006-02-15 16:04:14 -0500 (Wed, 15 Feb 2006)
New Revision: 472
Modified:
branches/developers/avida-edward/source/python/AvidaGui2/pyPetriConfigureCtrl.py
branches/developers/avida-edward/source/python/AvidaGui2/pyPetriDishCtrl.py
Log:
Partially solved problem with starting black rectangle in the petri dish
Modified: branches/developers/avida-edward/source/python/AvidaGui2/pyPetriConfigureCtrl.py
===================================================================
--- branches/developers/avida-edward/source/python/AvidaGui2/pyPetriConfigureCtrl.py 2006-02-12 23:31:52 UTC (rev 471)
+++ branches/developers/avida-edward/source/python/AvidaGui2/pyPetriConfigureCtrl.py 2006-02-15 21:04:14 UTC (rev 472)
@@ -78,6 +78,10 @@
PYSIGNAL("petriDishDroppedInPopViewSig"), self.petriDropped)
self.ChangeMutationTextSlot()
self.ChangeWorldSizeTextSlot()
+ self.m_session_mdl.m_session_mdtr.emit(
+ PYSIGNAL("setAvidaSig"),
+ (self.m_avida,))
+
self.populated = False
def destruct(self):
@@ -384,7 +388,8 @@
self.m_session_mdl.m_current_freezer, self.m_session_mdl.m_tempdir,
self.m_session_mdl.m_tempdir_out)
self.m_session_mdl.m_session_mdtr.emit(
- PYSIGNAL("doInitializeAvidaPhaseIISig"), (os.path.join(self.m_session_mdl.m_tempdir, "genesis.avida"),))
+ PYSIGNAL("doInitializeAvidaPhaseIISig"),
+ (os.path.join(self.m_session_mdl.m_tempdir, "genesis.avida"),))
def Form2Dictionary(self):
descr()
Modified: branches/developers/avida-edward/source/python/AvidaGui2/pyPetriDishCtrl.py
===================================================================
--- branches/developers/avida-edward/source/python/AvidaGui2/pyPetriDishCtrl.py 2006-02-12 23:31:52 UTC (rev 471)
+++ branches/developers/avida-edward/source/python/AvidaGui2/pyPetriDishCtrl.py 2006-02-15 21:04:14 UTC (rev 472)
@@ -123,12 +123,15 @@
if(self.m_avida):
pass
- self.m_change_list = self.m_avida.m_avida_threaded_driver.GetChangeList()
-
- self.m_world_w = cConfig.GetWorldX()
- self.m_world_h = cConfig.GetWorldY()
+ if (self.m_avida):
+ self.m_change_list = self.m_avida.m_avida_threaded_driver.GetChangeList()
+ self.m_world_w = cConfig.GetWorldX()
+ self.m_world_h = cConfig.GetWorldY()
+ else:
+ self.m_world_w = 30
+ self.m_world_h = 30
+
self.m_initial_target_zoom = int(self.m_target_dish_width / self.m_world_w)
-
self.emit(PYSIGNAL("zoomSig"), (self.m_initial_target_zoom,))
if self.m_canvas: del self.m_canvas
@@ -236,7 +239,7 @@
def zoomSlot(self, zoom_factor):
if hasattr(self,"m_world_h") == False:
- return
+ return
self.m_zoom_factor = zoom_factor
self.m_world_matrix = QWMatrix()
More information about the Avida-cvs
mailing list