Codex application override added.
This commit is contained in:
1 parent
b887f6ea95
commit
7c53cb39d4
23 files changed
+1771
-155
No files matched your search
@@ -51,6 +51,8 @@ type Reader struct {
|
||||
lastCompletedWord string
|
||||
inputAt time.Time
|
||||
applicationInputAt time.Time
|
||||
applicationActivity bool
|
||||
applicationActivityAt time.Time
|
||||
attributeConfigured, attributeResumeMode string
|
||||
attributeMode, attributeFormat string
|
||||
lastAttribute screen.Attribute
|
||||
@@ -93,6 +95,7 @@ func (r *Reader) Update(next screen.Snapshot) []presentation.Message {
|
||||
func (r *Reader) Update_application(next screen.Snapshot, frame applicationoverrides.Frame) (output []presentation.Message) {
|
||||
r.completedWords = nil
|
||||
previous := r.screen
|
||||
r.applicationActivity = next.Active && frame.Recognized && frame.OwnsPresentation && frame.Activity && r.progressEnabled
|
||||
// Python runs cursor-change commands only after recent direct application
|
||||
// input (300 ms). Reader commands and passive output must preserve review.
|
||||
if !r.keepReviewOnCursorChange && r.review.Active() && !r.applicationInputAt.IsZero() && time.Since(r.applicationInputAt) < 300*time.Millisecond &&
|
||||
@@ -203,7 +206,16 @@ func (r *Reader) Update_application(next screen.Snapshot, frame applicationoverr
|
||||
return nil
|
||||
}
|
||||
if frame.OwnsPresentation {
|
||||
return r.deletion_echo(deleted, next)
|
||||
if len(deleted) > 0 {
|
||||
return r.deletion_echo(deleted, next)
|
||||
}
|
||||
if frame.InputCursor && frame.Input != nil && r.cursorEcho && !r.review.Active() &&
|
||||
!r.applicationInputAt.IsZero() && time.Since(r.applicationInputAt) < 300*time.Millisecond &&
|
||||
frame.Input.Contains(previous.X, previous.Y, next.Cols) && frame.Input.Contains(next.X, next.Y, next.Cols) &&
|
||||
regions.allows(next.X, next.Y, next.Cols, true, true) {
|
||||
return input_cursor_feedback(typingPrevious, typingNext)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
readingPrevious := regions.filtered_snapshot(previous, true, true)
|
||||
readingNext := r.Automatic_snapshot()
|
||||
|
||||
Reference in new issue
Block a user