bugfix: version check
This commit is contained in:
parent
0d3db19c85
commit
9993014904
|
@ -17,6 +17,8 @@ Initializing settings:
|
||||||
- start out editing source, move window, press ctrl+e twice; window is editing source in same position+dimensions
|
- start out editing source, move window, press ctrl+e twice; window is editing source in same position+dimensions
|
||||||
- no log file; switching to source works
|
- no log file; switching to source works
|
||||||
|
|
||||||
|
- run with an unsupported version. Error message pops up and waits for a key. The app attempts to continue, and doesn't receive the key.
|
||||||
|
|
||||||
Code loading:
|
Code loading:
|
||||||
* run love with directory; text editor runs
|
* run love with directory; text editor runs
|
||||||
* run love with zip file; text editor runs
|
* run love with zip file; text editor runs
|
||||||
|
|
1
app.lua
1
app.lua
|
@ -107,6 +107,7 @@ function App.run_tests_and_initialize()
|
||||||
App.disable_tests()
|
App.disable_tests()
|
||||||
App.initialize_globals()
|
App.initialize_globals()
|
||||||
App.initialize(love.arg.parseGameArguments(arg), arg)
|
App.initialize(love.arg.parseGameArguments(arg), arg)
|
||||||
|
App.version_check()
|
||||||
end
|
end
|
||||||
|
|
||||||
function App.run_tests()
|
function App.run_tests()
|
||||||
|
|
5
main.lua
5
main.lua
|
@ -254,13 +254,14 @@ function App.textinput(t)
|
||||||
end
|
end
|
||||||
|
|
||||||
function App.keyreleased(key, scancode)
|
function App.keyreleased(key, scancode)
|
||||||
if Current_app == 'error' then return end
|
|
||||||
-- ignore events for some time after window in focus (mostly alt-tab)
|
-- ignore events for some time after window in focus (mostly alt-tab)
|
||||||
if Current_time < Last_focus_time + 0.01 then
|
if Current_time < Last_focus_time + 0.01 then
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
--
|
--
|
||||||
if Current_app == 'run' then
|
if Current_app == 'error' then
|
||||||
|
Current_app = 'run'
|
||||||
|
elseif Current_app == 'run' then
|
||||||
if run.key_release then run.key_release(key, scancode) end
|
if run.key_release then run.key_release(key, scancode) end
|
||||||
elseif Current_app == 'source' then
|
elseif Current_app == 'source' then
|
||||||
if source.key_release then source.key_release(key, scancode) end
|
if source.key_release then source.key_release(key, scancode) end
|
||||||
|
|
Loading…
Reference in New Issue