[vlc-commits] commit: ncurses: remove variable from interface context ( Rafaël Carré )
git at videolan.org
git at videolan.org
Tue Oct 26 15:49:05 CEST 2010
vlc | branch: master | Rafaël Carré <rafael.carre at gmail.com> | Tue Oct 26 15:32:20 2010 +0200| [e311921bfaf6f8324089d9c3efb85abc896f32e2] | committer: Rafaël Carré
ncurses: remove variable from interface context
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e311921bfaf6f8324089d9c3efb85abc896f32e2
---
modules/gui/ncurses.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/modules/gui/ncurses.c b/modules/gui/ncurses.c
index c95a133..2bd344d 100644
--- a/modules/gui/ncurses.c
+++ b/modules/gui/ncurses.c
@@ -193,8 +193,6 @@ struct intf_sys_t
playlist_item_t *p_node; /* current node */
- int b_box_cleared;
-
// msg_subscription_t* p_sub; /* message bank subscription */
char psz_search_chain[20];
@@ -2030,6 +2028,7 @@ static void Run(intf_thread_t *p_intf)
{
intf_sys_t *p_sys = p_intf->p_sys;
playlist_t *p_playlist = pl_Get(p_intf);
+ bool force_redraw = false;
time_t t_last_refresh;
int canc = vlc_savecancel();
@@ -2046,13 +2045,15 @@ static void Run(intf_thread_t *p_intf)
/* Update the input */
if (!p_sys->p_input)
+ {
p_sys->p_input = playlist_CurrentInput(p_playlist);
+ force_redraw = true;
+ }
else if (p_sys->p_input->b_dead)
{
vlc_object_release(p_sys->p_input);
p_sys->p_input = NULL;
p_sys->f_slider = p_sys->f_slider_old = 0.0;
- p_sys->b_box_cleared = false;
}
PL_LOCK;
@@ -2064,12 +2065,11 @@ static void Run(intf_thread_t *p_intf)
while (HandleKey(p_intf))
Redraw(p_intf, &t_last_refresh);
- /* Hack */
- if (p_sys->f_slider > 0.0001 && !p_sys->b_box_cleared)
+ if (force_redraw)
{
clear();
Redraw(p_intf, &t_last_refresh);
- p_sys->b_box_cleared = true;
+ force_redraw = false;
}
if ((time(0) - t_last_refresh) >= 1)
More information about the vlc-commits
mailing list