standardize between run and source some more
We shouldn't be thinking about saving settings when we're initializing window geometry.
This commit is contained in:
parent
7f4c5f847b
commit
bca7f82598
4
run.lua
4
run.lua
|
@ -150,9 +150,7 @@ function run.quit()
|
|||
end
|
||||
|
||||
function run.settings()
|
||||
if Settings == nil then
|
||||
Settings = {}
|
||||
end
|
||||
if Settings == nil then Settings = {} end
|
||||
Settings.x, Settings.y, Settings.displayindex = App.screen.position()
|
||||
return {
|
||||
x=Settings.x, y=Settings.y, displayindex=Settings.displayindex,
|
||||
|
|
|
@ -179,10 +179,6 @@ function source.initialize_window_geometry(em_width)
|
|||
App.screen.width, App.screen.height, App.screen.flags = App.screen.size()
|
||||
App.screen.flags.resizable = true
|
||||
App.screen.resize(App.screen.width, App.screen.height, App.screen.flags)
|
||||
print('initializing source position')
|
||||
if Settings == nil then Settings = {} end
|
||||
if Settings.source == nil then Settings.source = {} end
|
||||
Settings.source.x, Settings.source.y, Settings.source.displayindex = App.screen.position()
|
||||
end
|
||||
|
||||
function source.resize(w, h)
|
||||
|
@ -273,6 +269,8 @@ function source.quit()
|
|||
end
|
||||
|
||||
function source.settings()
|
||||
if Settings == nil then Settings = {} end
|
||||
if Settings.source == nil then Settings.source = {} end
|
||||
Settings.source.x, Settings.source.y, Settings.source.displayindex = App.screen.position()
|
||||
File_navigation.cursors[Editor_state.filename] = {cursor1=Editor_state.cursor1, screen_top1=Editor_state.screen_top1}
|
||||
return {
|
||||
|
|
Loading…
Reference in New Issue