프로젝트

일반

사용자정보

개정판 39d5c40a

ID39d5c40a32b6e4d507be18cb489a2f380c56f6b3
상위 17ccec42
하위 7da8145f, 75060f7c

함의성이(가) 약 6년 전에 추가함

build issue #701: fix xml load

차이점 보기:

DTI_PID/DTI_PID/Shapes/EngineeringUnknownItem.py
189 189
            points = [[int(float(coord)) for coord in pt.split(',')] for pt in node.find('POINTS').text.split('\n')]
190 190

  
191 191
            line_indicator_node = node.find('LINEINDICATOR')
192
            if line_indicator_node:
192
            if line_indicator_node is not None:
193 193
                lineIndicator = line_indicator_node.text.split('#')
194 194
                if lineIndicator[0] == 'True':
195 195
                    item = QEngineeringUnknownItem(points, 'True', lineIndicator[1], [int(lineIndicator[2]), int(lineIndicator[3]), int(lineIndicator[4]), int(lineIndicator[5])])
......
197 197
                    item = QEngineeringUnknownItem(points, 'Match', lineIndicator[1], [int(lineIndicator[2]), int(lineIndicator[3]), int(lineIndicator[4]), int(lineIndicator[5])])
198 198
                else:
199 199
                    item = QEngineeringUnknownItem(points, 'False')
200
            else:
201
                item = QEngineeringUnknownItem(points, 'False')
200 202
            
201 203
            if node.find('AREA') is None:
202 204
                appDocData = AppDocData.instance()
......
212 214
            else:
213 215
                item.area = node.find('AREA').text
214 216
        except Exception as ex:
217
            from App import App
215 218
            message = 'error occured({}) in {}:{}'.format(ex, sys.exc_info()[-1].tb_frame.f_code.co_filename, sys.exc_info()[-1].tb_lineno)
216 219
            App.mainWnd().addMessage.emit(MessageType.Error, message)
217 220

  

내보내기 Unified diff

클립보드 이미지 추가 (최대 크기: 500 MB)