00001 /* 00002 This file is part of the Opie Project 00003 00004 Copyright (c) 2002 Max Reiss <harlekin@handhelds.org> 00005 Copyright (c) 2002 L. Potter <ljp@llornkcor.com> 00006 Copyright (c) 2002 Holger Freyther <zecke@handhelds.org> 00007 =. 00008 .=l. 00009 .>+-= 00010 _;:, .> :=|. This program is free software; you can 00011 .> <`_, > . <= redistribute it and/or modify it under 00012 :`=1 )Y*s>-.-- : the terms of the GNU General Public 00013 .="- .-=="i, .._ License as published by the Free Software 00014 - . .-<_> .<> Foundation; either version 2 of the License, 00015 ._= =} : or (at your option) any later version. 00016 .%`+i> _;_. 00017 .i_,=:_. -<s. This program is distributed in the hope that 00018 + . -:. = it will be useful, but WITHOUT ANY WARRANTY; 00019 : .. .:, . . . without even the implied warranty of 00020 =_ + =;=|` MERCHANTABILITY or FITNESS FOR A 00021 _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU 00022 ..}^=.= = ; Library General Public License for more 00023 ++= -. .` .: details. 00024 : = ...= . :.=- 00025 -. .:....=;==+<; You should have received a copy of the GNU 00026 -_. . . )=. = Library General Public License along with 00027 -- :-=` this library; see the file COPYING.LIB. 00028 If not, write to the Free Software Foundation, 00029 Inc., 59 Temple Place - Suite 330, 00030 Boston, MA 02111-1307, USA. 00031 00032 */ 00033 00034 #ifndef VIDEO_WIDGET_H 00035 #define VIDEO_WIDGET_H 00036 00037 #include "xinevideowidget.h" 00038 #include "mediawidget.h" 00039 00040 class QPixmap; 00041 class QSlider; 00042 00043 class VideoWidget : public MediaWidget { 00044 Q_OBJECT 00045 public: 00046 VideoWidget( PlayListWidget &playList, MediaPlayerState &mediaPlayerState, QWidget* parent=0, const char* name=0 ); 00047 ~VideoWidget(); 00048 00049 static MediaWidget::GUIInfo guiInfo(); 00050 00051 XineVideoWidget* vidWidget(); 00052 public slots: 00053 void updateSlider( long, long ); 00054 void sliderPressed( ); 00055 void sliderReleased( ); 00056 void setFullscreen( bool b ); 00057 virtual void makeVisible(); 00058 void backToNormal(); 00059 void setPosition( long ); 00060 00061 public: 00062 virtual void setPlaying( bool b); 00063 virtual void setLength( long ); 00064 virtual void setDisplayType( MediaPlayerState::DisplayType displayType ); 00065 00066 virtual void loadSkin(); 00067 00068 signals: 00069 void moreClicked(); 00070 void lessClicked(); 00071 void sliderMoved( long ); 00072 void videoResized ( const QSize &s ); 00073 00074 protected: 00075 00076 void resizeEvent( QResizeEvent * ); 00077 void mouseReleaseEvent( QMouseEvent *event ); 00078 void keyReleaseEvent( QKeyEvent *e); 00079 00080 private: 00081 // Ticker songInfo; 00082 00083 QSlider *slider; 00084 QImage *currentFrame; 00085 int scaledWidth; 00086 int scaledHeight; 00087 XineVideoWidget* videoFrame; 00088 00089 bool videoSliderBeingMoved; 00090 }; 00091 00092 #endif // VIDEO_WIDGET_H 00093 00094 00095
1.4.2