source: remember cursor position of multiple files

[?]
Sep 19, 2022, 7:10 AM
L2FWWEQLZPZLGTI34PWW2V6BU5PRDHFTZPTJJQYGG4R6WOFJ273QC

Dependencies

  • [2] RQUVBX62 filter candidates in file navigator
  • [3] C7OO4H3S source: support only relative paths within the app
  • [4] MKPXANB5 bugfix: mouse clicks on file navigator above log browser side
  • [5] KKMFQDR4 editing source code from within the app
  • [6] JMUD7T3O get rid of ugly side-effects in tests
  • [7] OI4FPFIN support drawings in the source editor
  • [8] NFI42KGX more correct absolute path detection
  • [9] X3CQLBTR set window title within each app
  • [10] ZJOSQFN6 bugfix: path munging on Windows
  • [11] BYKXF3YY bugfix: draw menu after everything else
  • [12] B4JEWKWI hide editor cursor while in file navigator

Change contents

  • edit in source.lua at line 48
    [2.53]
    [4.166514]
    cursors = {}, -- filename to cursor1, screen_top1
  • edit in source.lua at line 218
    [4.172597]
    [4.172597]
    -- save cursor position
    File_navigation.cursors[Editor_state.filename] = {cursor1=Editor_state.cursor1, screen_top1=Editor_state.screen_top1}
  • replacement in source.lua at line 224
    [4.172733][4.172733:172819]()
    Editor_state.screen_top1 = {line=1, pos=1}
    Editor_state.cursor1 = {line=1, pos=1}
    [4.172733]
    [4.172819]
    if File_navigation.cursors[filename] then
    Editor_state.screen_top1 = File_navigation.cursors[filename].screen_top1
    Editor_state.cursor1 = File_navigation.cursors[filename].cursor1
    else
    Editor_state.screen_top1 = {line=1, pos=1}
    Editor_state.cursor1 = {line=1, pos=1}
    end
  • replacement in source.lua at line 272
    [4.174206][3.12:43]()
    print(Editor_state.filename)
    [4.174206]
    [4.174206]
    File_navigation.cursors[Editor_state.filename] = {cursor1=Editor_state.cursor1, screen_top1=Editor_state.screen_top1}
  • replacement in source.lua at line 278
    [3.80][4.174425:174495](),[4.174425][4.174425:174495]()
    screen_top=Editor_state.screen_top1, cursor=Editor_state.cursor1,
    [3.80]
    [4.174495]
    cursors=File_navigation.cursors,