]>
Commit | Line | Data |
---|---|---|
6dc040ed IB |
1 | import threading |
2 | ||
3 | def run(action, music=None, **kwargs): | |
4 | for music in action.music_list(music): | |
5 | if not music.is_loaded(allow_substates=True): | |
6 | threading.Thread(name="MSMusicLoad", target=music.load).start() | |
7 | ||
8 | def description(action, music=None, **kwargs): | |
9 | if music is not None: | |
10 | return "load music « {} » to memory".format(music.name) | |
11 | else: | |
12 | return "load all music to memory" |