364 self.previewSV.takeWidget() |
364 self.previewSV.takeWidget() |
365 del self.mainWidget |
365 del self.mainWidget |
366 self.mainWidget = None |
366 self.mainWidget = None |
367 |
367 |
368 # load the file |
368 # load the file |
369 with contextlib.suppress(Exception): |
369 with contextlib.suppress( |
|
370 ImportError, NotImplementedError, SyntaxError, TypeError |
|
371 ): |
370 self.mainWidget = uic.loadUi(fn) |
372 self.mainWidget = uic.loadUi(fn) |
371 |
373 |
372 if self.mainWidget: |
374 if self.mainWidget: |
373 self.currentFile = fn |
375 self.currentFile = fn |
374 self.__updateChildren(self.styleCombo.currentText()) |
376 self.__updateChildren(self.styleCombo.currentText()) |