void (@NotNull ActionEvent e) { runWriteActionAndRestartRefactoring( () -> { if (exprTypeCheckbox.isSelected()) { String renderedType = IdeDescriptorRenderers.SOURCE_CODE_SHORT_NAMES_NO_ANNOTATIONS.renderType(myExprType); myDeclaration.setTypeReference(new KtPsiFactory(myProject).createType(renderedType)); } else { myDeclaration.setTypeReference(null); } } ); }