1 /*****************************************************************************
2 * wxwindows.h: private wxWindows interface description
3 *****************************************************************************
4 * Copyright (C) 1999-2004 VideoLAN
7 * Authors: Gildas Bazin <gbazin@videolan.org>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
22 *****************************************************************************/
24 #ifdef WIN32 /* mingw32 hack */
29 /* Let vlc take care of the i18n stuff */
30 #define WXINTL_NO_GETTEXT_MACRO
32 #include <wx/wxprec.h>
35 #include <wx/listctrl.h>
36 #include <wx/textctrl.h>
37 #include <wx/notebook.h>
38 #include <wx/spinctrl.h>
40 #include <wx/treectrl.h>
43 #include <wx/checkbox.h>
44 #include <wx/wizard.h>
48 /* Hmmm, work-around for newest wxWin */
49 #ifdef wxStaticCastEvent
50 # undef wxStaticCastEvent
51 # define wxStaticCastEvent(type, val) ((type)(val))
54 DECLARE_LOCAL_EVENT_TYPE( wxEVT_DIALOG, 0 );
55 DECLARE_LOCAL_EVENT_TYPE( wxEVT_INTF, 1 );
57 #define SLIDER_MAX_POS 10000
59 /* wxU is used to convert ansi/utf8 strings to unicode strings (wchar_t) */
60 #if defined( ENABLE_NLS ) && defined( ENABLE_UTF8 )
62 # define wxU(utf8) wxString(utf8, wxConvUTF8)
64 # define wxU(utf8) wxString(wxConvUTF8.cMB2WC(utf8), *wxConvCurrent)
68 #else // ENABLE_NLS && ENABLE_UTF8
70 # define wxU(ansi) wxString(ansi, wxConvLocal)
72 # define wxU(ansi) ansi
78 /* wxL2U (locale to unicode) is used to convert ansi strings to unicode
79 * strings (wchar_t) */
81 # define wxL2U(ansi) wxString(ansi, *wxConvCurrent)
83 # define wxL2U(ansi) ansi
96 class DialogsProvider;
101 /*****************************************************************************
102 * intf_sys_t: description and status of wxwindows interface
103 *****************************************************************************/
106 /* the wx parent window */
107 wxWindow *p_wxwindow;
110 /* special actions */
111 vlc_bool_t b_playing;
112 vlc_bool_t b_intf_show; /* interface to be shown */
114 /* The input thread */
115 input_thread_t * p_input;
118 int i_slider_pos; /* slider position */
119 int i_slider_oldpos; /* previous position */
120 vlc_bool_t b_slider_free; /* slider status */
122 /* The messages window */
123 msg_subscription_t* p_sub; /* message bank subscription */
125 /* Playlist management */
126 int i_playing; /* playlist selected item */
128 /* Send an event to show a dialog */
129 void (*pf_show_dialog) ( intf_thread_t *p_intf, int i_dialog, int i_arg,
130 intf_dialog_args_t *p_arg );
133 wxMenu *p_popup_menu;
136 int i_first_hotkey_event;
140 VideoWindow *p_video_window;
141 wxBoxSizer *p_video_sizer;
144 aout_instance_t *p_aout;
147 /*****************************************************************************
149 *****************************************************************************/
150 wxArrayString SeparateEntries( wxString );
151 wxWindow *CreateVideoWindow( intf_thread_t *p_intf, wxWindow *p_parent );
152 wxWindow *BookmarksDialog( intf_thread_t *p_intf, wxWindow *p_parent );
153 wxWindow *CreateDialogsProvider( intf_thread_t *p_intf, wxWindow *p_parent );
160 class SubsFileDialog;
166 class ItemInfoDialog;
168 class ExportPlaylist;
170 /*****************************************************************************
171 * Classes declarations.
172 *****************************************************************************/
174 class Timer: public wxTimer
178 Timer( intf_thread_t *p_intf, Interface *p_main_interface );
181 virtual void Notify();
184 intf_thread_t *p_intf;
185 Interface *p_main_interface;
187 int i_old_playing_status;
189 vlc_bool_t b_old_seekable;
190 vlc_bool_t b_disc_shown;
195 class ExtraPanel: public wxPanel
199 ExtraPanel( intf_thread_t *p_intf, wxWindow *p_parent );
200 virtual ~ExtraPanel();
202 wxStaticBox *adjust_box;
203 wxButton *restoredefaults_button;
204 wxSlider *brightness_slider;
205 wxSlider *contrast_slider;
206 wxSlider *saturation_slider;
207 wxSlider *hue_slider;
208 wxSlider *gamma_slider;
210 wxStaticBox *other_box;
211 wxComboBox *ratio_combo;
219 wxPanel *VideoPanel( wxWindow * );
220 wxPanel *EqzPanel( wxWindow * );
221 wxPanel *AudioPanel( wxWindow * );
223 wxNotebook *notebook;
225 wxCheckBox *eq_chkbox;
227 wxCheckBox *eq_2p_chkbox;
229 wxSlider *smooth_slider;
231 wxSlider *preamp_slider;
232 wxStaticText * preamp_text;
237 wxSlider *band_sliders[10];
238 wxStaticText *band_texts[10];
244 /* Event handlers (these functions should _not_ be virtual) */
246 void OnEnableAdjust( wxCommandEvent& );
247 void OnEnableEqualizer( wxCommandEvent& );
248 void OnRestoreDefaults( wxCommandEvent& );
249 void OnChangeEqualizer( wxScrollEvent& );
250 void OnAdjustUpdate( wxScrollEvent& );
251 void OnRatio( wxCommandEvent& );
252 void OnFiltersInfo( wxCommandEvent& );
253 void OnSelectFilter( wxCommandEvent& );
255 void OnEqSmooth( wxScrollEvent& );
256 void OnPreamp( wxScrollEvent& );
257 void OnEq2Pass( wxCommandEvent& );
258 void OnEqRestore( wxCommandEvent& );
260 void OnHeadphone( wxCommandEvent& );
261 void OnNormvol( wxCommandEvent& );
262 void OnNormvolSlider( wxScrollEvent& );
264 void OnIdle( wxIdleEvent& );
266 DECLARE_EVENT_TABLE();
268 intf_thread_t *p_intf;
269 vlc_bool_t b_my_update;
273 /* Extended Window */
274 class ExtraWindow: public wxFrame
278 ExtraWindow( intf_thread_t *p_intf, wxWindow *p_parent, wxPanel *panel );
279 virtual ~ExtraWindow();
285 DECLARE_EVENT_TABLE();
287 intf_thread_t *p_intf;
292 class Interface: public wxFrame
296 Interface( intf_thread_t *p_intf );
297 virtual ~Interface();
299 void TogglePlayButton( int i_playing_status );
302 wxBoxSizer *frame_sizer;
303 wxStatusBar *statusbar;
306 wxWindow *slider_frame;
307 wxBoxSizer *slider_sizer;
308 wxPanel *extra_frame;
311 wxBoxSizer *disc_sizer;
312 wxBitmapButton *disc_menu_button;
313 wxBitmapButton *disc_prev_button;
314 wxBitmapButton *disc_next_button;
316 wxFrame *extra_window;
326 void CreateOurMenuBar();
327 void CreateOurToolBar();
328 void CreateOurExtendedPanel();
329 void CreateOurSlider();
330 void Open( int i_access_method );
332 /* Event handlers (these functions should _not_ be virtual) */
333 void OnExit( wxCommandEvent& event );
334 void OnAbout( wxCommandEvent& event );
336 void OnOpenFileSimple( wxCommandEvent& event );
337 void OnOpenDir( wxCommandEvent& event );
338 void OnOpenFile( wxCommandEvent& event );
339 void OnOpenDisc( wxCommandEvent& event );
340 void OnOpenNet( wxCommandEvent& event );
341 void OnOpenSat( wxCommandEvent& event );
343 void OnExtended( wxCommandEvent& event );
344 //void OnUndock( wxCommandEvent& event );
346 void OnBookmarks( wxCommandEvent& event );
347 void OnShowDialog( wxCommandEvent& event );
348 void OnPlayStream( wxCommandEvent& event );
349 void OnStopStream( wxCommandEvent& event );
350 void OnSliderUpdate( wxScrollEvent& event );
351 void OnPrevStream( wxCommandEvent& event );
352 void OnNextStream( wxCommandEvent& event );
353 void OnSlowStream( wxCommandEvent& event );
354 void OnFastStream( wxCommandEvent& event );
356 void OnDiscMenu( wxCommandEvent& event );
357 void OnDiscPrev( wxCommandEvent& event );
358 void OnDiscNext( wxCommandEvent& event );
360 void OnMenuOpen( wxMenuEvent& event );
362 #if defined( __WXMSW__ ) || defined( __WXMAC__ )
363 void OnContextMenu2(wxContextMenuEvent& event);
365 void OnContextMenu(wxMouseEvent& event);
367 void OnControlEvent( wxCommandEvent& event );
369 DECLARE_EVENT_TABLE();
372 intf_thread_t *p_intf;
375 int i_old_playing_status;
377 /* For auto-generated menus */
378 wxMenu *p_settings_menu;
379 wxMenu *p_audio_menu;
380 wxMenu *p_video_menu;
381 wxMenu *p_navig_menu;
385 WX_DEFINE_ARRAY(AutoBuiltPanel *, ArrayOfAutoBuiltPanel);
386 class OpenDialog: public wxDialog
390 OpenDialog( intf_thread_t *p_intf, wxWindow *p_parent,
391 int i_access_method, int i_arg = 0 );
393 /* Extended Contructor */
394 OpenDialog( intf_thread_t *p_intf, wxWindow *p_parent,
395 int i_access_method, int i_arg = 0 , int _i_method = 0 );
396 virtual ~OpenDialog();
399 int Show( int i_access_method, int i_arg = 0 );
402 void UpdateMRL( int i_access_method );
407 wxPanel *FilePanel( wxWindow* parent );
408 wxPanel *DiscPanel( wxWindow* parent );
409 wxPanel *NetPanel( wxWindow* parent );
411 ArrayOfAutoBuiltPanel input_tab_array;
413 /* Event handlers (these functions should _not_ be virtual) */
414 void OnOk( wxCommandEvent& event );
415 void OnCancel( wxCommandEvent& event );
417 void OnPageChange( wxNotebookEvent& event );
418 void OnMRLChange( wxCommandEvent& event );
420 /* Event handlers for the file page */
421 void OnFilePanelChange( wxCommandEvent& event );
422 void OnFileBrowse( wxCommandEvent& event );
424 /* Event handlers for the disc page */
425 void OnDiscPanelChange( wxCommandEvent& event );
426 void OnDiscTypeChange( wxCommandEvent& event );
427 void OnDiscDeviceChange( wxCommandEvent& event );
429 /* Event handlers for the net page */
430 void OnNetPanelChange( wxCommandEvent& event );
431 void OnNetTypeChange( wxCommandEvent& event );
433 /* Event handlers for the stream output */
434 void OnSubsFileEnable( wxCommandEvent& event );
435 void OnSubsFileSettings( wxCommandEvent& WXUNUSED(event) );
437 /* Event handlers for the stream output */
438 void OnSoutEnable( wxCommandEvent& event );
439 void OnSoutSettings( wxCommandEvent& WXUNUSED(event) );
441 /* Event handlers for the caching option */
442 void OnCachingEnable( wxCommandEvent& event );
443 void OnCachingChange( wxCommandEvent& event );
445 DECLARE_EVENT_TABLE();
447 intf_thread_t *p_intf;
449 int i_current_access_method;
450 int i_disc_type_selection;
452 int i_method; /* Normal or for the stream dialog ? */
455 wxComboBox *mrl_combo;
456 wxNotebook *notebook;
458 /* Controls for the file panel */
459 wxComboBox *file_combo;
460 wxFileDialog *file_dialog;
462 /* Controls for the disc panel */
463 wxRadioBox *disc_type;
464 wxTextCtrl *disc_device;
465 wxSpinCtrl *disc_title; int i_disc_title;
466 wxSpinCtrl *disc_chapter; int i_disc_chapter;
467 wxSpinCtrl *disc_sub; int i_disc_sub;
469 /* The media equivalent name for a DVD names. For example,
470 * "Title", is "Track" for a CD-DA */
471 wxStaticText *disc_title_label;
472 wxStaticText *disc_chapter_label;
473 wxStaticText *disc_sub_label;
475 /* Indicates if the disc device control was modified */
476 bool b_disc_device_changed;
478 /* Controls for the net panel */
479 wxRadioBox *net_type;
481 wxPanel *net_subpanels[4];
482 wxRadioButton *net_radios[4];
483 wxSpinCtrl *net_ports[4];
485 wxTextCtrl *net_addrs[4];
486 wxCheckBox *net_ipv6;
488 /* Controls for the subtitles file */
489 wxButton *subsfile_button;
490 wxCheckBox *subsfile_checkbox;
491 SubsFileDialog *subsfile_dialog;
492 wxArrayString subsfile_mrl;
494 /* Controls for the stream output */
495 wxButton *sout_button;
496 wxCheckBox *sout_checkbox;
497 SoutDialog *sout_dialog;
498 wxArrayString sout_mrl;
500 /* Controls for the caching options */
501 wxCheckBox *caching_checkbox;
502 wxSpinCtrl *caching_value;
512 /* Auto-built panels */
515 #define MAX_ACCESS CAPTURE_ACCESS
517 /* Stream output Dialog */
530 TS_ENCAPSULATION = 0,
549 class SoutDialog: public wxDialog
553 SoutDialog( intf_thread_t *p_intf, wxWindow *p_parent );
554 virtual ~SoutDialog();
556 wxArrayString GetOptions();
560 wxPanel *AccessPanel( wxWindow* parent );
561 wxPanel *MiscPanel( wxWindow* parent );
562 wxPanel *EncapsulationPanel( wxWindow* parent );
563 wxPanel *TranscodingPanel( wxWindow* parent );
566 /* Event handlers (these functions should _not_ be virtual) */
567 void OnOk( wxCommandEvent& event );
568 void OnCancel( wxCommandEvent& event );
569 void OnMRLChange( wxCommandEvent& event );
570 void OnAccessTypeChange( wxCommandEvent& event );
572 /* Event handlers for the file access output */
573 void OnFileChange( wxCommandEvent& event );
574 void OnFileBrowse( wxCommandEvent& event );
575 void OnFileDump( wxCommandEvent& event );
577 /* Event handlers for the net access output */
578 void OnNetChange( wxCommandEvent& event );
580 /* Event specific to the announce address */
581 void OnAnnounceGroupChange( wxCommandEvent& event );
582 void OnAnnounceAddrChange( wxCommandEvent& event );
584 /* Event handlers for the encapsulation panel */
585 void OnEncapsulationChange( wxCommandEvent& event );
587 /* Event handlers for the transcoding panel */
588 void OnTranscodingEnable( wxCommandEvent& event );
589 void OnTranscodingChange( wxCommandEvent& event );
591 /* Event handlers for the misc panel */
592 void OnSAPMiscChange( wxCommandEvent& event );
593 void OnSLPMiscChange( wxCommandEvent& event );
595 DECLARE_EVENT_TABLE();
597 intf_thread_t *p_intf;
600 wxComboBox *mrl_combo;
602 /* Controls for the access outputs */
603 wxPanel *access_panel;
604 wxPanel *access_subpanels[ACCESS_OUT_NUM];
605 wxCheckBox *access_checkboxes[ACCESS_OUT_NUM];
609 wxComboBox *file_combo;
610 wxCheckBox *dump_checkbox;
611 wxSpinCtrl *net_ports[ACCESS_OUT_NUM];
612 wxTextCtrl *net_addrs[ACCESS_OUT_NUM];
614 /* Controls for the SAP announces */
616 wxPanel *misc_subpanels[MISC_SOUT_NUM];
617 wxCheckBox *sap_checkbox;
618 wxCheckBox *slp_checkbox;
619 wxTextCtrl *announce_group;
620 wxTextCtrl *announce_addr;
622 /* Controls for the encapsulation */
623 wxPanel *encapsulation_panel;
624 wxRadioButton *encapsulation_radios[ENCAPS_NUM];
625 int i_encapsulation_type;
627 /* Controls for transcoding */
628 wxPanel *transcoding_panel;
629 wxCheckBox *video_transc_checkbox;
630 wxComboBox *video_codec_combo;
631 wxComboBox *audio_codec_combo;
632 wxCheckBox *audio_transc_checkbox;
633 wxComboBox *video_bitrate_combo;
634 wxComboBox *audio_bitrate_combo;
635 wxComboBox *audio_channels_combo;
636 wxComboBox *video_scale_combo;
639 wxCheckBox *sout_all_checkbox;
642 /* Subtitles File Dialog */
643 class SubsFileDialog: public wxDialog
647 SubsFileDialog( intf_thread_t *p_intf, wxWindow *p_parent );
648 virtual ~SubsFileDialog();
650 wxComboBox *file_combo;
651 wxComboBox *encoding_combo;
652 wxComboBox *size_combo;
653 wxComboBox *align_combo;
654 wxSpinCtrl *fps_spinctrl;
655 wxSpinCtrl *delay_spinctrl;
658 /* Event handlers (these functions should _not_ be virtual) */
659 void OnOk( wxCommandEvent& event );
660 void OnCancel( wxCommandEvent& event );
661 void OnFileBrowse( wxCommandEvent& event );
663 DECLARE_EVENT_TABLE();
665 intf_thread_t *p_intf;
670 class StreamDialog: public wxFrame
674 StreamDialog( intf_thread_t *p_intf, wxWindow *p_parent );
675 virtual ~StreamDialog();
678 void OnClose( wxCommandEvent& event );
679 void OnOpen( wxCommandEvent& event );
680 void OnSout( wxCommandEvent& event );
681 void OnStart( wxCommandEvent& event );
683 DECLARE_EVENT_TABLE();
685 intf_thread_t *p_intf;
687 wxStaticText *step2_label;
688 wxStaticText *step3_label;
689 wxButton *sout_button;
690 wxButton *start_button;
692 wxArrayString sout_mrl;
693 OpenDialog *p_open_dialog;
694 SoutDialog *p_sout_dialog;
698 class WizardDialog : public wxWizard
702 WizardDialog( intf_thread_t *p_intf, wxWindow *p_parent,char *, int, int );
703 virtual ~WizardDialog();
704 void SetTranscode( char *vcodec, int vb, char *acodec,int ab);
705 void SetMrl( const char *mrl );
706 void SetTTL( int i_ttl );
707 void SetPartial( int, int );
708 void SetStream( char *method, char *address );
709 void SetTranscodeOut( const char *address );
710 void SetAction( int i_action );
712 void SetSAP( bool b_enabled, const char *psz_name );
713 void SetMux( char *mux );
720 int i_from, i_to, i_ttl;
721 char *vcodec , *acodec , *address , *mrl , *mux ;
724 DECLARE_EVENT_TABLE();
726 intf_thread_t *p_intf;
730 /* Preferences Dialog */
731 class PrefsDialog: public wxFrame
735 PrefsDialog( intf_thread_t *p_intf, wxWindow *p_parent );
736 virtual ~PrefsDialog();
739 wxPanel *PrefsPanel( wxWindow* parent );
741 /* Event handlers (these functions should _not_ be virtual) */
742 void OnOk( wxCommandEvent& event );
743 void OnCancel( wxCommandEvent& event );
744 void OnSave( wxCommandEvent& event );
745 void OnResetAll( wxCommandEvent& event );
746 void OnAdvanced( wxCommandEvent& event );
748 DECLARE_EVENT_TABLE();
750 intf_thread_t *p_intf;
752 PrefsTreeCtrl *prefs_tree;
756 class Messages: public wxFrame
760 Messages( intf_thread_t *p_intf, wxWindow *p_parent );
762 bool Show( bool show = TRUE );
766 /* Event handlers (these functions should _not_ be virtual) */
767 void OnClose( wxCommandEvent& event );
768 void OnClear( wxCommandEvent& event );
769 void OnSaveLog( wxCommandEvent& event );
771 DECLARE_EVENT_TABLE();
773 intf_thread_t *p_intf;
774 wxTextCtrl *textctrl;
775 wxTextAttr *info_attr;
776 wxTextAttr *err_attr;
777 wxTextAttr *warn_attr;
778 wxTextAttr *dbg_attr;
780 wxFileDialog *save_log_dialog;
782 vlc_bool_t b_verbose;
786 class Playlist: public wxFrame
790 Playlist( intf_thread_t *p_intf, wxWindow *p_parent );
793 void UpdatePlaylist();
794 void ShowPlaylist( bool show );
795 void UpdateItem( int );
796 void AppendItem( wxCommandEvent& );
801 void RemoveItem( int );
802 void DeleteItem( int item );
803 void DeleteNode( playlist_item_t *node );
805 /* Event handlers (these functions should _not_ be virtual) */
808 void OnAddFile( wxCommandEvent& event );
809 void OnAddDir( wxCommandEvent& event );
810 void OnAddMRL( wxCommandEvent& event );
811 void OnClose( wxCommandEvent& event );
813 void OnEnableSelection( wxCommandEvent& event );
814 void OnDisableSelection( wxCommandEvent& event );
815 void OnInvertSelection( wxCommandEvent& event );
816 void OnDeleteSelection( wxCommandEvent& event );
817 void OnSelectAll( wxCommandEvent& event );
819 void OnOpen( wxCommandEvent& event );
820 void OnSave( wxCommandEvent& event );
823 void OnSearch( wxCommandEvent& event );
824 void OnSearchTextChange( wxCommandEvent& event );
825 wxTextCtrl *search_text;
826 wxButton *search_button;
827 wxTreeItemId search_current;
829 void OnEnDis( wxCommandEvent& event );
833 void OnSort( wxCommandEvent& event );
836 int i_duration_sorted;
839 void OnMenuEvent( wxCommandEvent& event );
840 void OnMenuOpen( wxMenuEvent& event );
846 void OnUp( wxCommandEvent& event);
847 void OnDown( wxCommandEvent& event);
849 void OnRandom( wxCommandEvent& event );
850 void OnRepeat( wxCommandEvent& event );
851 void OnLoop ( wxCommandEvent& event );
853 void OnActivateItem( wxTreeEvent& event );
854 void OnKeyDown( wxTreeEvent& event );
855 void OnNewGroup( wxCommandEvent& event );
860 wxTreeItemId i_popup_item;
861 playlist_item_t *p_popup_item;
862 playlist_item_t *p_popup_parent;
863 void OnPopup( wxContextMenuEvent& event );
864 void OnPopupPlay( wxMenuEvent& event );
865 void OnPopupPreparse( wxMenuEvent& event );
866 void OnPopupSort( wxMenuEvent& event );
867 void OnPopupDel( wxMenuEvent& event );
868 void OnPopupEna( wxMenuEvent& event );
869 void OnPopupInfo( wxMenuEvent& event );
870 void Rebuild( vlc_bool_t );
872 void Preparse( playlist_t *p_playlist );
875 void UpdateNode( playlist_t *, playlist_item_t*, wxTreeItemId );
876 void UpdateNodeChildren( playlist_t *, playlist_item_t*, wxTreeItemId );
877 void CreateNode( playlist_t *, playlist_item_t*, wxTreeItemId );
878 void UpdateTreeItem( playlist_t *, wxTreeItemId );
880 /* Search (internal) */
881 int CountItems( wxTreeItemId);
882 wxTreeItemId FindItem( wxTreeItemId, playlist_item_t * );
883 wxTreeItemId FindItem( wxTreeItemId, int );
884 wxTreeItemId FindItemByName( wxTreeItemId, wxString,
885 wxTreeItemId, vlc_bool_t *);
887 wxTreeItemId saved_tree_item;
888 playlist_item_t *p_saved_item;
892 void OnPlaylistEvent( wxCommandEvent& event );
894 DECLARE_EVENT_TABLE();
898 wxStatusBar *statusbar;
899 ItemInfoDialog *iteminfo_dialog;
901 int i_update_counter;
903 intf_thread_t *p_intf;
904 wxTreeCtrl *treectrl;
906 vlc_bool_t b_changed_view;
912 /* ItemInfo Dialog */
913 class ItemInfoDialog: public wxDialog
917 ItemInfoDialog( intf_thread_t *p_intf, playlist_item_t *_p_item,
918 wxWindow *p_parent );
919 virtual ~ItemInfoDialog();
921 wxArrayString GetOptions();
924 wxPanel *InfoPanel( wxWindow* parent );
925 wxPanel *GroupPanel( wxWindow* parent );
927 /* Event handlers (these functions should _not_ be virtual) */
928 void OnOk( wxCommandEvent& event );
929 void OnCancel( wxCommandEvent& event );
933 DECLARE_EVENT_TABLE();
935 intf_thread_t *p_intf;
936 playlist_item_t *p_item;
939 /* Controls for the iteminfo dialog box */
940 wxPanel *info_subpanel;
943 wxPanel *group_subpanel;
944 wxPanel *group_panel;
946 wxTextCtrl *uri_text;
947 wxTextCtrl *name_text;
949 wxTreeCtrl *info_tree;
950 wxTreeItemId info_root;
956 class FileInfo: public wxFrame
960 FileInfo( intf_thread_t *p_intf, wxWindow *p_parent );
962 void UpdateFileInfo();
964 vlc_bool_t b_need_update;
967 void OnClose( wxCommandEvent& event );
969 DECLARE_EVENT_TABLE();
971 intf_thread_t *p_intf;
972 wxTreeCtrl *fileinfo_tree;
973 wxTreeItemId fileinfo_root;
974 wxString fileinfo_root_label;
979 #if wxUSE_DRAG_AND_DROP
980 /* Drag and Drop class */
981 class DragAndDrop: public wxFileDropTarget
984 DragAndDrop( intf_thread_t *_p_intf, vlc_bool_t b_enqueue = VLC_FALSE );
986 virtual bool OnDropFiles( wxCoord x, wxCoord y,
987 const wxArrayString& filenames );
990 intf_thread_t *p_intf;
991 vlc_bool_t b_enqueue;
994 } // end of wxvlc namespace
997 void PopupMenu( intf_thread_t *, wxWindow *, const wxPoint& );
998 wxMenu *SettingsMenu( intf_thread_t *, wxWindow *, wxMenu * = NULL );
999 wxMenu *AudioMenu( intf_thread_t *, wxWindow *, wxMenu * = NULL );
1000 wxMenu *VideoMenu( intf_thread_t *, wxWindow *, wxMenu * = NULL );
1001 wxMenu *NavigMenu( intf_thread_t *, wxWindow *, wxMenu * = NULL );
1005 class MenuEvtHandler : public wxEvtHandler
1008 MenuEvtHandler( intf_thread_t *p_intf, Interface *p_main_interface );
1009 virtual ~MenuEvtHandler();
1011 void OnMenuEvent( wxCommandEvent& event );
1012 void OnShowDialog( wxCommandEvent& event );
1016 DECLARE_EVENT_TABLE()
1018 intf_thread_t *p_intf;
1019 Interface *p_main_interface;
1022 } // end of wxvlc namespace
1023 using namespace wxvlc;