def __init__(self, parent=None, *args, **kwargs):
        super(LoadMarkerLayout, self).__init__(*args, **kwargs)
        self.setupUi(self)

        # 'File Info' should be read-only.
        self.fileInfo_plainTextEdit.setReadOnly(True)

        # Camera combo box.
        self.camera_model = uimodels.StringDataListModel()
        self.camera_comboBox.setModel(self.camera_model)

        # Camera update.
        self.cameraUpdate_pushButton.clicked.connect(self.cameraUpdateClicked)

        # Set default image resolution values
        w, h = lib.get_default_image_resolution()
        self.imageResWidth_spinBox.setValue(w)
        self.imageResWidth_spinBox.setEnabled(False)
        self.imageResWidth_spinBox.setMaximum(99999)
        self.imageResHeight_spinBox.setValue(h)
        self.imageResHeight_spinBox.setEnabled(False)
        self.imageResHeight_spinBox.setMaximum(99999)

        # File path browse.
        self.filepath_pushButton.clicked.connect(self.filePathBrowseClicked)

        # Get the file path from the clipboard.
        try:
            clippy = QtGui.QClipboard()
            text = str(clippy.text()).strip()
            if lib.is_valid_file_path(text):
                self.setFilePath(text)
        except Exception as e:
            msg = 'Could not get file path from clipboard.'
            LOG.warning(msg)
            LOG.info(str(e))

        # Update the 'Image Resolution' enable state when the file
        # patch changes.
        self.filepath_lineEdit.editingFinished.connect(
            self.updateImageResEnabledState)

        # Update the 'File Info' when the file patch changes
        self.filepath_lineEdit.editingFinished.connect(self.updateFileInfoText)

        # Populate the UI with data
        self.populateUi()
 def updateFileInfoText(self):
     file_path = self.getFilePath()
     info_widget = self.fileInfo_plainTextEdit
     valid = lib.is_valid_file_path(file_path)
     if valid is False:
         text = 'File path is not valid:\n'
         text += repr(file_path)
         info_widget.setPlainText(text)
         return
     text = 'Format: {fmt_name}\n'
     text += 'Frame Range: {start_frame}-{end_frame}\n'
     text += 'Number of Points: {num_points}\n'
     text += 'Point Names: {point_names}\n'
     info = lib.get_file_info(file_path)
     text = text.format(**info)
     info_widget.setPlainText(text)
     return