indicate local modifications in load/save dialog

akkartik
Mar 17, 2024, 7:37 PM
JOY24JW6ELCMS44MMPC2YBO6DX5KJL6DPGNHQOOSGQLYZ5OLGW5AC

Dependencies

  • [2] Q3EQI5LI some keyboard shortcuts on non-mobile devices
  • [3] 2IJLEJGT indicate local modifications in editor title bar
  • [4] SIJ5I4NZ extract a helper for buttons
  • [5] FIUQJVL2 first draft of load/save buttons
  • [6] PO77NPCO indicate unsaved changes
  • [7] XJBUCJAG bugfix: skipping files near right margin
  • [8] 6ARK6HWF bugfix: avoid overflowing 'delete' button in some situations
  • [9] W4EQ6IW4 simplify state management for menus
  • [10] W3RRTO4P extract a second helper for buttons
  • [11] AZMYKWMH resolve conflicts
  • [12] 7QVNDHPE filter file list based on input
  • [13] LGIEVJE6 activate buttons for some time
  • [*] R5QXEHUI somebody stop me
  • [*] 5RUFNRJO start of the visual skeleton

Change contents

  • file addition: 0181-local_modifications_color (----------)
    [15.2]
    local_modifications_color = function(filename)
    return has_local_modifications(filename) and Local_modifications_color
    end
  • file addition: 0180-Local_modifications_color (----------)
    [15.2]
    Local_modifications_color = {r=0.8, g=0, b=0}
  • replacement in 0124-styled_button at line 1
    [4.1][2.994:1055]()
    styled_button = function(name, x, y, onpress1, tooltip_text)
    [4.1]
    [4.583]
    styled_button = function(name, x, y, onpress1, tooltip_text, fg)
  • replacement in 0124-styled_button at line 8
    [4.363][4.363:391]()
    App.color(Normal_color)
    [4.363]
    [4.391]
    App.color(fg or Normal_color)
  • replacement in 0119-draw_file_dialog at line 46
    [4.347][4.347:420]()
    File_dialog_callback(filename)
    reset_file_dialog_state()
    end)
    [4.347]
    [4.420]
    File_dialog_callback(filename)
    reset_file_dialog_state()
    end,
    --[[tooltip text]] nil,
    local_modifications_color(filename))
  • replacement in 0119-draw_file_dialog at line 54
    [4.2377][4.671:675]()
    end
    [4.2377]
    end
  • replacement in 0118-overflowable_button at line 3
    [4.515][2.1132:1216]()
    overflowable_button = function(name, x, y, r, onpress1, final_button, tooltip_text)
    [4.515]
    [4.677]
    overflowable_button = function(name, x, y, r, onpress1, final_button, tooltip_text, fg)
  • replacement in 0118-overflowable_button at line 14
    [4.301][2.1217:1267]()
    styled_button(name, x,y, onpress1, tooltip_text)
    [4.301]
    [4.568]
    styled_button(name, x,y, onpress1, tooltip_text, fg)
  • replacement in 0020-draw_editor_border at line 22
    [3.382][3.382:411]()
    App.color{r=0.8, g=0,b=0}
    [3.382]
    [3.411]
    App.color(Local_modifications_color)