INNER CODE UNIT · Python
pick_output_root
wzyn20051216/solidworks-automation-skill · apps/desktop/cad_workbench/app.py:454
def pick_output_root(self) -> None:
folder = QFileDialog.getExistingDirectory(self, "选择输出根目录", self.output_root.text())
if folder:
self.output_root.setText(folder)
def pick_project_file(self) -> None:
start = self.output_root.text() or str(default_output_root())
file_path, _ = QFileDialog.getOpenFileName(self, "打开项目", start, "Project JSON (project.json)")
if file_path:
self.load_project(Path(file_path).parent)
def append_log(self, message: str) -> None:
self.log_box.append(message)
self.log_box.verticalScrollBar().setValue(self.log_box.verticalScrollBar().maximum())
QApplication.processEvents()
def _set_table_row(self, table: QTableWidget, values: list[Any]) -> None:
row = table.rowCount()