1 /* 2 * Copyright 2003-2010 Haiku Inc. All rights reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Jérôme Duval 7 * Oliver Ruiz Dorantes 8 * Atsushi Takamatsu 9 */ 10 #ifndef __HWINDOW_H__ 11 #define __HWINDOW_H__ 12 13 14 #include <Window.h> 15 #include <FilePanel.h> 16 #include <FileGameSound.h> 17 18 19 class HEventList; 20 class HTypeList; 21 22 23 enum{ 24 M_PLAY_MESSAGE = 'MPLM', 25 M_STOP_MESSAGE = 'MSTO', 26 M_REMOVE_MESSAGE = 'MREM', 27 M_ITEM_MESSAGE = 'MITE', 28 M_OTHER_MESSAGE = 'MOTH', 29 M_NONE_MESSAGE = 'MNON', 30 M_ADD_EVENT = 'MADE', 31 M_REMOVE_EVENT = 'MREE', 32 M_OPEN_WITH = 'MOPW' 33 }; 34 35 36 class HWindow : public BWindow { 37 public: 38 HWindow(BRect rect, const char* name); 39 virtual ~HWindow(); 40 41 virtual void DispatchMessage(BMessage* message, 42 BHandler* handler); 43 virtual void MessageReceived(BMessage* message); 44 virtual bool QuitRequested(); 45 46 private: 47 void _InitGUI(); 48 void _Pulse(); 49 void _SetupMenuField(); 50 void _UpdateZoomLimits(); 51 52 private: 53 HEventList* fEventList; 54 BFilePanel* fFilePanel; 55 BButton* fPlayButton; 56 BFileGameSound* fPlayer; 57 BRect fFrame; 58 }; 59 60 61 #endif // __HWINDOW_H__ 62