def doConfigDialog(self, Locomotif): print "open configuration dialog" dialog = ConfigDialog(self) dialog.setModal(1) ret = dialog.exec_() # transfer (new) map sizes mapWidth = configData.getMapWidth() g_rundata.setMapWidth( mapWidth ) self.ui.cmdMapWidth.setText(str(mapWidth)) mapHeight = configData.getMapHeight() g_rundata.setMapHeight( mapHeight ) self.ui.cmdMapHeight.setText(str(mapHeight)) # transfer (new) google maps settings mapWidth = configData.getGoogleMapWidth() g_rundata.setGoogleMapWidth( mapWidth ) g_tabwidgets.t1GMMapWidth.setText(str(mapWidth)) g_tabwidgets.t1GM2MapWidth.setText(str(mapWidth)) mapHeight = configData.getGoogleMapHeight() g_rundata.setGoogleMapHeight( mapHeight ) g_tabwidgets.t1GMMapHeight.setText(str(mapHeight)) g_tabwidgets.t1GM2MapHeight.setText(str(mapHeight)) maptype = configData.getGoogle1Maptype() g_rundata.setGoogle1Maptype( maptype ) # following values must fit to combobox in configuration if maptype == "hybrid": g_tabwidgets.t1GMmaptype.setChecked(True) if maptype == "satellite": g_tabwidgets.t1GMmaptype_2.setChecked(True) if maptype == "roadmap": g_tabwidgets.t1GMmaptype_3.setChecked(True) if maptype == "terrain": g_tabwidgets.t1GMmaptype_4.setChecked(True) maptype = configData.getGoogle2Maptype() g_rundata.setGoogle2Maptype( maptype ) # following values must fit to combobox in configuration if maptype == "hybrid": g_tabwidgets.t1GM2maptype.setChecked(True) if maptype == "satellite": g_tabwidgets.t1GM2maptype_2.setChecked(True) if maptype == "roadmap": g_tabwidgets.t1GM2maptype_3.setChecked(True) if maptype == "terrain": g_tabwidgets.t1GM2maptype_4.setChecked(True)
def doSelectGMMaptype4(self, Locomotif): g_rundata.setGoogle1Maptype("terrain"); if g_rundata.getWorkingState()>=3: self.work.markDataOnGoogleMap( g_tabwidgets, g_rundata )