/*****************************************************************************
* pda_callbacks.c : Callbacks for the pda Linux Gtk+ plugin.
*****************************************************************************
- * Copyright (C) 2000, 2001 VideoLAN (Centrale Réseaux) and its contributors
+ * Copyright (C) 2000, 2001 the VideoLAN team
* $Id$
*
- * Authors: Jean-Paul Saman <jpsaman@wxs.nl>
+ * Authors: Jean-Paul Saman <jpsaman _at_ videolan _dot_ org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
#include <sys/types.h> /* off_t */
-#include <stdlib.h>
#include <vlc/vlc.h>
-#include <vlc/intf.h>
-#include <vlc/vout.h>
+#include <vlc_interface.h>
+#include <vlc_playlist.h>
+#include <vlc_vout.h>
-#include <stdio.h>
-#include <string.h>
#include <dirent.h>
#include <sys/stat.h>
#include <unistd.h>
GtkTreeIter p_play_iter;
p_play_model = gtk_tree_view_get_model(p_tvplaylist);
-
+
if (p_play_model)
{
int i;
}
/* kludge */
for (i=0; i<n; i++)
- {
+ {
if ((pp_namelist[i]->d_name[0] != '.') &&
(lstat(pp_namelist[i]->d_name, &st)==0))
{
intf_thread_t *p_intf = GtkGetIntf( widget );
vlc_mutex_lock( &p_intf->change_lock );
- p_intf->p_vlc->b_die = VLC_TRUE;
+ vlc_object_kill( p_intf->p_libvlc );
vlc_mutex_unlock( &p_intf->change_lock );
msg_Dbg( p_intf, "about to exit vlc ... signaled" );
return TRUE;
}
-
void onRewind(GtkButton *button, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( button );
}
}
-
void onPause(GtkButton *button, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( button );
}
}
-
void onStop(GtkButton *button, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( GTK_WIDGET( button ) );
}
}
-
void onForward(GtkButton *button, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( button );
}
}
-
gboolean SliderRelease(GtkWidget *widget, GdkEventButton *event, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( widget );
return TRUE;
}
-
gboolean SliderPress(GtkWidget *widget, GdkEventButton *event, gpointer user_data)
{
intf_thread_t *p_intf = GtkGetIntf( widget );
p_intf->p_sys->b_slider_free = 0;
vlc_mutex_unlock( &p_intf->change_lock );
- return TRUE;
+ return FALSE;
}
void SliderMove(GtkRange *range, GtkScrollType scroll, gpointer user_data)
{
GtkTreeSelection *p_selection = gtk_tree_view_get_selection(p_treeview);
- gtk_tree_selection_selected_foreach(p_selection, (GtkTreeSelectionForeachFunc) &addSelectedToPlaylist, (gpointer) p_treeview);
+ gtk_tree_selection_selected_foreach(p_selection, (GtkTreeSelectionForeachFunc) &addSelectedToPlaylist, (gpointer) p_treeview);
}
}
GtkCheckButton *p_check_v4l_transcode = NULL;
gboolean b_v4l_transcode;
-
+
char **ppsz_options = NULL; /* list of options */
int i_options=0;
char v4l_mrl[6];
gint item;
gtk_tree_model_get(p_model, &iter, 2, &item, -1);
- playlist_LockDelete(p_playlist, item);
+ msg_Err( p_playlist, "PDA delete broken");
}
}
}
-#if 0
+#if 0
g_list_foreach (p_rows, (GFunc*)gtk_tree_path_free, NULL);
#endif /* Testing the next line */
g_list_foreach (p_rows, deleteItemFromPlaylist, NULL);
for(item = p_playlist->i_size - 1; item >= 0 ;item-- )
{
- playlist_LockDelete( p_playlist, item);
+ msg_Err( p_playlist "fix pda delete");
}
vlc_object_release( p_playlist );
p_entryVideoBitrate = (GtkSpinButton*) lookup_widget( GTK_WIDGET(button), "entryVideoBitrate" );
p_entryVideoBitrateTolerance = (GtkSpinButton*) lookup_widget( GTK_WIDGET(button), "entryVideoBitrateTolerance" );
p_entryVideoKeyFrameInterval = (GtkSpinButton*) lookup_widget( GTK_WIDGET(button), "entryVideoKeyFrameInterval" );
-
+
p_video_codec = gtk_entry_get_text(GTK_ENTRY(p_entryVideoCodec));
i_video_bitrate = gtk_spin_button_get_value_as_int(p_entryVideoBitrate);
i_video_bitrate_tolerance = gtk_spin_button_get_value_as_int(p_entryVideoBitrateTolerance);
i_video_keyframe_interval = gtk_spin_button_get_value_as_int(p_entryVideoKeyFrameInterval);
-
+
i_pos += snprintf( &ppsz_options[i_options][i_pos], VLC_MAX_MRL - i_pos, "vcodec=%s,", (char*)p_video_codec );
if (i_pos>=VLC_MAX_MRL) ppsz_options[i_options][VLC_MAX_MRL-1] = '\0';
i_pos += snprintf( &ppsz_options[i_options][i_pos], VLC_MAX_MRL - i_pos, "vb=%d,", (int)i_video_bitrate );
if (i_pos>=VLC_MAX_MRL) ppsz_options[i_options][VLC_MAX_MRL-1] = '\0';
i_pos += snprintf( &ppsz_options[i_options][i_pos], VLC_MAX_MRL - i_pos, "mux=%s,", (char*)p_std_muxer);
if (i_pos>=VLC_MAX_MRL) ppsz_options[i_options][VLC_MAX_MRL-1] = '\0';
- i_pos += snprintf( &ppsz_options[i_options][i_pos], VLC_MAX_MRL - i_pos, "url=%s", (char*)p_std_url);
+ i_pos += snprintf( &ppsz_options[i_options][i_pos], VLC_MAX_MRL - i_pos, "dst=%s", (char*)p_std_url);
if (i_pos>=VLC_MAX_MRL) ppsz_options[i_options][VLC_MAX_MRL-1] = '\0';
if (strncasecmp( (const char*)p_std_access, "udp", 3)==0)
GtkCheckButton *p_checkSAP = NULL;
GtkCheckButton *p_checkSLP = NULL;
GtkEntry *p_entryStdAccess = NULL;
- const gchar *p_std_access = NULL;
+ const gchar *p_std_access = NULL;
gboolean b_announce = FALSE;
p_entryStdAccess = (GtkEntry*) lookup_widget( GTK_WIDGET(editable), "entryStdAccess" );