Skip to content

Commit

Permalink
Changing project is working
Browse files Browse the repository at this point in the history
  • Loading branch information
Uwe Fechner committed Apr 30, 2024
1 parent 6368f5b commit 06006cb
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions examples/autopilot.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ using Timers; tic()
using KiteControllers, KiteViewers, KiteModels, StatsBase, ControlPlots, NativeFileDialog, LaTeXStrings
using Printf, LinearAlgebra
import KiteViewers.GLMakie
import KiteViewers.GLMakie.GLFW
import KiteControllers.YAML
if false; include("../src/flightpathcontroller.jl"); end
if false; include("../src/flightpathcalculator2.jl"); end
Expand Down Expand Up @@ -434,16 +435,11 @@ on(app.viewer.menu_project.i_selected) do c
filename = fetch(Threads.@spawn pick_file("data"; filterlist="yml"))
if filename != ""
PROJECT = basename(filename)
println(PROJECT)
# stop_()
close(app.viewer.screen)
GLFW.SetWindowTitle(app.viewer.screen.glscreen, PROJECT)
sleep(0.1)
GLMakie.activate!(title = PROJECT)
app.set = deepcopy(load_settings(PROJECT))
app.max_time = app.set.sim_time
app.next_max_time = app.max_time
init(app; init_viewer=true)
play(true)
end
end
end
Expand Down

0 comments on commit 06006cb

Please sign in to comment.