Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
magic-lantern
magic-lantern
Commits
02e2a2e1c708
Commit
725e406b
authored
Apr 18, 2016
by
alex@thinkpad
Browse files
mlv_play: refactored to use enter_play_mode/exit_play_qr_mode
--HG-- branch : play_mode
parent
dc71c3d7030b
Changes
1
Hide whitespace changes
Inline
Side-by-side
modules/mlv_play/mlv_play.c
View file @
02e2a2e1
...
...
@@ -35,6 +35,7 @@
#include <zebra.h>
#include <util.h>
#include <timer.h>
#include <shoot.h>
#include <string.h>
...
...
@@ -2091,30 +2092,6 @@ static void mlv_play(char *filename, FILE **chunk_files, uint32_t chunk_count)
}
}
static
void
mlv_play_set_mode
(
int32_t
mode
)
{
if
(
get_gui_mode
()
==
mode
)
{
return
;
}
uint32_t
loops
=
0
;
SetGUIRequestMode
(
mode
);
while
(
get_gui_mode
()
!=
mode
||
!
display_is_on
())
{
msleep
(
100
);
loops
++
;
if
(
loops
>
50
)
{
break
;
}
}
msleep
(
500
);
}
static
void
mlv_playlist_build_path
(
char
*
directory
)
{
struct
fio_file
file
;
...
...
@@ -2308,14 +2285,14 @@ static void mlv_play_leave_playback()
}
vram_clear_lv
();
mlv
_play_
set
_mode
(
0
);
exit
_play_
qr
_mode
();
}
static
void
mlv_play_enter_playback
()
{
/* prepare display */
NotifyBoxHide
();
mlv
_play_
set_
mode
(
1
);
enter
_play_mode
();
/* render task is slave and controlled via these variables */
mlv_play_render_abort
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment