feat: virtual scrolling with chunked buffer for large files
- Add ChunkedBuffer for 64KB chunked file access with dirty-chunk eviction protection - Add LineIndex for precise byte-offset-to-line-number mapping - Refactor IO task system with context cancellation, typed priorities, and new task types (ReadChunk, BuildLineIndex, StatFile) - Add ReadFileAt to FileSystem interface (mock + real implementations) - Integrate virtual scrolling into editor layout - Add comprehensive tests for chunked buffer eviction, dirty-chunk safety, and full edit lifecycle
This commit is contained in:
@@ -154,7 +154,7 @@ func (bm *BrowserManager) handleLoadPagesSuccess(result pool.Result) {
|
||||
}
|
||||
|
||||
func (bm *BrowserManager) handleError(result pool.Result) {
|
||||
fmt.Printf("handleError: TaskType=%s, Error=%v\n", result.TaskType, result.Error)
|
||||
fmt.Printf("handleError: TaskType=%d, Error=%v\n", result.TaskType, result.Error)
|
||||
bm.state.Loading = false
|
||||
// For now, just reset the state or log the error.
|
||||
// In production, we'd show a toast or error message.
|
||||
|
||||
Reference in New Issue
Block a user