| 909 | } |
| 910 | |
| 911 | void ChatRootView::handOffSession() |
| 912 | { |
| 913 | if (m_chatModel->rowCount() > 0) { |
| 914 | if (m_recentFilePath.isEmpty()) { |
| 915 | QString filePath = getAutosaveFilePath(); |
| 916 | if (auto registry = sessionFileRegistry()) |
| 917 | filePath = registry->uniqueFreePath(filePath); |
| 918 | if (!filePath.isEmpty()) |
| 919 | setRecentFilePath(filePath); |
| 920 | } |
| 921 | if (!m_recentFilePath.isEmpty()) |
| 922 | m_historyStore->save(m_recentFilePath); |
| 923 | } |
| 924 | |
| 925 | if (auto registry = sessionFileRegistry(); registry && !m_recentFilePath.isEmpty()) |
| 926 | registry->setPendingChatFile(m_recentFilePath); |
| 927 | |
| 928 | setRecentFilePath(QString{}); |
| 929 | } |
| 930 | |
| 931 | void ChatRootView::consumePendingChatFile() |
| 932 | { |
nothing calls this directly
no test coverage detected