]> git.sesse.net Git - vlc/blobdiff - modules/gui/beos/InterfaceWindow.h
Removes trailing spaces. Removes tabs.
[vlc] / modules / gui / beos / InterfaceWindow.h
index 678119e729b31b256ccd5a92d99d3b881b51d1c9..ce4219e995ff30797284a960b3887b0d8193fdae 100644 (file)
@@ -1,8 +1,8 @@
 /*****************************************************************************
  * InterfaceWindow.h: BeOS interface window class prototype
  *****************************************************************************
- * Copyright (C) 1999, 2000, 2001 VideoLAN
- * $Id: InterfaceWindow.h,v 1.6 2002/11/27 05:36:41 titer Exp $
+ * Copyright (C) 1999, 2000, 2001 the VideoLAN team
+ * $Id$
  *
  * Authors: Jean-Marc Dressler <polux@via.ecp.fr>
  *          Tony Castley <tcastley@mail.powerup.com.au>
@@ -13,7 +13,7 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
@@ -21,7 +21,7 @@
  *
  * 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.
  *****************************************************************************/
 
 #ifndef BEOS_INTERFACE_WINDOW_H
 
 class BMenuBar;
 class MediaControlView;
+#if 0
 class PlayListWindow;
+#endif
 class BFilePanel;
 class PreferencesWindow;
+class MessagesWindow;
 
 class CDMenu : public BMenu
 {
  public:
-                                                       CDMenu( const char* name );
-       virtual                                 ~CDMenu();
+                            CDMenu( const char* name );
+    virtual                 ~CDMenu();
 
-       virtual void                    AttachedToWindow();
+    virtual void            AttachedToWindow();
 
  private:
-       int                                             GetCD( const char* directory );
+    int                     GetCD( const char* directory );
 };
 
 class LanguageMenu : public BMenu
 {
  public:
-                                                       LanguageMenu( const char* name,
-                                                                                 int menu_kind,
-                                                                                 intf_thread_t* p_interface );
-       virtual                                 ~LanguageMenu();
+                            LanguageMenu( intf_thread_t * p_intf,
+                                          const char * psz_name,
+                                          char * psz_variable );
+    virtual                 ~LanguageMenu();
 
-       virtual void                    AttachedToWindow();
+    virtual void            AttachedToWindow();
 
  private:
-                       void                    _GetChannels();
-
-       intf_thread_t*                  p_intf;
-       int                                             kind;
+    intf_thread_t         * p_intf;
+    char                  * psz_variable;
 };
 
 class TitleMenu : public BMenu
 {
  public:
-                                                       TitleMenu( const char* name, intf_thread_t  *p_interface );
-       virtual                                 ~TitleMenu();
+                            TitleMenu( const char* name, intf_thread_t  *p_interface );
+    virtual                 ~TitleMenu();
+
+    virtual void            AttachedToWindow();
 
-       virtual void                    AttachedToWindow();
-       
-       intf_thread_t  *p_intf;
+    intf_thread_t  *p_intf;
 };
 
 class ChapterMenu : public BMenu
 {
  public:
-                                                       ChapterMenu( const char* name, intf_thread_t  *p_interface );
-       virtual                                 ~ChapterMenu();
+                            ChapterMenu( const char* name, intf_thread_t  *p_interface );
+    virtual                 ~ChapterMenu();
 
-       virtual void                    AttachedToWindow();
+    virtual void            AttachedToWindow();
 
-       intf_thread_t  *p_intf;
+    intf_thread_t  *p_intf;
 };
 
 
 class InterfaceWindow : public BWindow
 {
  public:
-                                                       InterfaceWindow( BRect frame,
-                                                                                        const char* name,
-                                                                                        intf_thread_t* p_interface );
-       virtual                                 ~InterfaceWindow();
-
-                                                       // BWindow
-       virtual void                    FrameResized( float width, float height );
-       virtual void                    MessageReceived( BMessage* message );
-       virtual bool                    QuitRequested();
-
-                                                       // InterfaceWindow
-                       void                    updateInterface();
-                       bool                    IsStopped() const;
-           
-       MediaControlView*               p_mediaControl;
-
- private:      
-                       void                    _UpdatePlaylist();
-                       void                    _SetMenusEnabled( bool hasFile,
-                                                                                         bool hasChapters = false,
-                                                                                         bool hasTitles = false );
-                       void                    _UpdateSpeedMenu( int rate );
-                       void                    _InputStreamChanged();
-                       status_t                _LoadSettings( BMessage* message,
-                                                                                  const char* fileName,
-                                                                                  const char* subFolder = NULL );
-                       status_t                _SaveSettings( BMessage* message,
-                                                                                  const char* fileName,
-                                                                                  const char* subFolder = NULL );
-                       void                    _RestoreSettings();
-                       void                    _StoreSettings();
-
-       intf_thread_t*                  p_intf;
-       es_descriptor_t*                p_spu_es;
-
-       bool                                    fPlaylistIsEmpty;
-       BFilePanel*                             fFilePanel;
-       PlayListWindow*                 fPlaylistWindow;
-       PreferencesWindow*              fPreferencesWindow;
-       BMenuBar*                               fMenuBar;
-       BMenuItem*                              fNextTitleMI;
-       BMenuItem*                              fPrevTitleMI;
-       BMenuItem*                              fNextChapterMI;
-       BMenuItem*                              fPrevChapterMI;
-       BMenuItem*                              fOnTopMI;
-       BMenuItem*                              fSlowerMI;
-       BMenuItem*                              fNormalMI;
-       BMenuItem*                              fFasterMI;
-       BMenuItem*                              fPreferencesMI;
-       BMenu*                                  fAudioMenu;
-       BMenu*                                  fNavigationMenu;
-       BMenu*                                  fTitleMenu;
-       BMenu*                                  fChapterMenu;
-       BMenu*                                  fLanguageMenu;
-       BMenu*                                  fSubtitlesMenu;
-       BMenu*                                  fSpeedMenu;
-       BMenu*                                  fSettingsMenu;
-       bigtime_t                               fLastUpdateTime;
-       BMessage*                               fSettings;      // we keep the message arround
-                                                                               // for forward compatibility
-       
-       VlcWrapper * p_wrapper;
+                            InterfaceWindow( intf_thread_t * p_intf,
+                                             BRect frame,
+                                             const char * name );
+    virtual                 ~InterfaceWindow();
+
+                            // BWindow
+    virtual void            FrameResized( float width, float height );
+    virtual void            MessageReceived( BMessage* message );
+    virtual bool            QuitRequested();
+
+                            // InterfaceWindow
+            void            UpdateInterface();
+            void            UpdatePlaylist();
+
+            bool            IsStopped() const;
+    MediaControlView*        p_mediaControl;
+    MessagesWindow*         fMessagesWindow;
+
+ private:
+            void            _SetMenusEnabled( bool hasFile,
+                                              bool hasChapters = false,
+                                              bool hasTitles = false );
+            void            _UpdateSpeedMenu( int rate );
+            void            _ShowFilePanel( uint32 command,
+                                            const char* windowTitle );
+            void            _RestoreSettings();
+            void            _StoreSettings();
+
+    intf_thread_t         * p_intf;
+    input_thread_t        * p_input;
+    playlist_t            * p_playlist;
+    es_descriptor_t       * p_spu_es;
+    bool                    b_playlist_update;
+
+    BFilePanel*             fFilePanel;
+#if 0
+    PlayListWindow*         fPlaylistWindow;
+#endif
+    PreferencesWindow*      fPreferencesWindow;
+    BMenuBar*               fMenuBar;
+    BMenuItem*              fGotoMenuMI;
+    BMenuItem*              fNextTitleMI;
+    BMenuItem*              fPrevTitleMI;
+    BMenuItem*              fNextChapterMI;
+    BMenuItem*              fPrevChapterMI;
+    BMenuItem*              fOnTopMI;
+    BMenuItem*              fHeighthMI;
+    BMenuItem*              fQuarterMI;
+    BMenuItem*              fHalfMI;
+    BMenuItem*              fNormalMI;
+    BMenuItem*              fTwiceMI;
+    BMenuItem*              fFourMI;
+    BMenuItem*              fHeightMI;
+    BMenu*                  fAudioMenu;
+    BMenu*                  fNavigationMenu;
+    BMenu*                  fTitleMenu;
+    BMenu*                  fChapterMenu;
+    BMenu*                  fLanguageMenu;
+    BMenu*                  fSubtitlesMenu;
+    BMenu*                  fSpeedMenu;
+    BMenu*                  fShowMenu;
+    bigtime_t               fLastUpdateTime;
+    BMessage*               fSettings;  // we keep the message arround
+                                        // for forward compatibility
 };
 
-#endif // BEOS_INTERFACE_WINDOW_H
+
+// some global support functions
+status_t load_settings( BMessage* message,
+                        const char* fileName,
+                        const char* folder = NULL );
+
+status_t save_settings( BMessage* message,
+                        const char* fileName,
+                        const char* folder = NULL );
+
+
+#endif    // BEOS_INTERFACE_WINDOW_H