[Jahshaka-cvs] SF.net SVN: editopia:[238] cinesuite/cineplay-cinecode/trunk/src
Status: Beta
Brought to you by:
jahshaka
From: <tim...@us...> - 2008-11-07 13:49:23
|
Revision: 238 http://editopia.svn.sourceforge.net/editopia/?rev=238&view=rev Author: timdewhirst Date: 2008-11-07 13:49:07 +0000 (Fri, 07 Nov 2008) Log Message: ----------- cinesuite * uniform file naming Modified Paths: -------------- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.cpp cinesuite/cineplay-cinecode/trunk/src/CineCode.cpp cinesuite/cineplay-cinecode/trunk/src/CinePlay.cpp cinesuite/cineplay-cinecode/trunk/src/Command.cpp cinesuite/cineplay-cinecode/trunk/src/Common.cpp cinesuite/cineplay-cinecode/trunk/src/Download.cpp cinesuite/cineplay-cinecode/trunk/src/EncodeJob.cpp cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.cpp cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.cpp cinesuite/cineplay-cinecode/trunk/src/FilterGraph.cpp cinesuite/cineplay-cinecode/trunk/src/GridLayoutCallback.cpp cinesuite/cineplay-cinecode/trunk/src/Info.cpp cinesuite/cineplay-cinecode/trunk/src/OpenGLStore.cpp cinesuite/cineplay-cinecode/trunk/src/PlayList.cpp cinesuite/cineplay-cinecode/trunk/src/Player.cpp cinesuite/cineplay-cinecode/trunk/src/PlayerDelegate.cpp cinesuite/cineplay-cinecode/trunk/src/PlayerMultiplexer.cpp cinesuite/cineplay-cinecode/trunk/src/PlayerMultiplexer.hpp cinesuite/cineplay-cinecode/trunk/src/Release.cpp cinesuite/cineplay-cinecode/trunk/src/ReleaseDlg.cpp cinesuite/cineplay-cinecode/trunk/src/RemoveFavouriteDlg.cpp cinesuite/cineplay-cinecode/trunk/src/ScrollViewResizer.cpp cinesuite/cineplay-cinecode/trunk/src/SkinDlg.cpp cinesuite/cineplay-cinecode/trunk/src/Tray.cpp cinesuite/cineplay-cinecode/trunk/src/Utils.cpp cinesuite/cineplay-cinecode/trunk/src/about.cpp cinesuite/cineplay-cinecode/trunk/src/cinecode.pro cinesuite/cineplay-cinecode/trunk/src/cineplay.pro cinesuite/cineplay-cinecode/trunk/src/common.pri cinesuite/cineplay-cinecode/trunk/src/log.cpp cinesuite/cineplay-cinecode/trunk/src/pinfo.cpp Added Paths: ----------- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.hpp cinesuite/cineplay-cinecode/trunk/src/CineCode.hpp cinesuite/cineplay-cinecode/trunk/src/CinePlay.hpp cinesuite/cineplay-cinecode/trunk/src/Command.hpp cinesuite/cineplay-cinecode/trunk/src/Common.hpp cinesuite/cineplay-cinecode/trunk/src/Download.hpp cinesuite/cineplay-cinecode/trunk/src/EncodeJob.hpp cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.hpp cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.hpp cinesuite/cineplay-cinecode/trunk/src/FilterGraph.hpp cinesuite/cineplay-cinecode/trunk/src/GridLayoutCallback.hpp cinesuite/cineplay-cinecode/trunk/src/Info.hpp cinesuite/cineplay-cinecode/trunk/src/Jah.hpp cinesuite/cineplay-cinecode/trunk/src/LogMessageHandler.hpp cinesuite/cineplay-cinecode/trunk/src/OpenGLStore.hpp cinesuite/cineplay-cinecode/trunk/src/PlayList.hpp cinesuite/cineplay-cinecode/trunk/src/Player.hpp cinesuite/cineplay-cinecode/trunk/src/PlayerDelegate.hpp cinesuite/cineplay-cinecode/trunk/src/Release.hpp cinesuite/cineplay-cinecode/trunk/src/ReleaseDlg.hpp cinesuite/cineplay-cinecode/trunk/src/RemoveFavouriteDlg.hpp cinesuite/cineplay-cinecode/trunk/src/ScrollViewResizer.hpp cinesuite/cineplay-cinecode/trunk/src/SetupDefs.hpp cinesuite/cineplay-cinecode/trunk/src/SkinDlg.hpp cinesuite/cineplay-cinecode/trunk/src/Tray.hpp cinesuite/cineplay-cinecode/trunk/src/Utils.hpp cinesuite/cineplay-cinecode/trunk/src/Version.hpp cinesuite/cineplay-cinecode/trunk/src/about.hpp cinesuite/cineplay-cinecode/trunk/src/log.hpp cinesuite/cineplay-cinecode/trunk/src/pinfo.hpp Removed Paths: ------------- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.h cinesuite/cineplay-cinecode/trunk/src/CineCode.h cinesuite/cineplay-cinecode/trunk/src/CinePlay.h cinesuite/cineplay-cinecode/trunk/src/Command.h cinesuite/cineplay-cinecode/trunk/src/Common.h cinesuite/cineplay-cinecode/trunk/src/Download.h cinesuite/cineplay-cinecode/trunk/src/EncodeJob.h cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.h cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.h cinesuite/cineplay-cinecode/trunk/src/FilterGraph.h cinesuite/cineplay-cinecode/trunk/src/GridLayoutCallback.h cinesuite/cineplay-cinecode/trunk/src/Info.h cinesuite/cineplay-cinecode/trunk/src/Jah.h cinesuite/cineplay-cinecode/trunk/src/LogMessageHandler.h cinesuite/cineplay-cinecode/trunk/src/OpenGLStore.h cinesuite/cineplay-cinecode/trunk/src/PlayList.h cinesuite/cineplay-cinecode/trunk/src/Player.h cinesuite/cineplay-cinecode/trunk/src/PlayerDelegate.h cinesuite/cineplay-cinecode/trunk/src/Release.h cinesuite/cineplay-cinecode/trunk/src/ReleaseDlg.h cinesuite/cineplay-cinecode/trunk/src/RemoveFavouriteDlg.h cinesuite/cineplay-cinecode/trunk/src/ScrollViewResizer.h cinesuite/cineplay-cinecode/trunk/src/SetupDefs.h cinesuite/cineplay-cinecode/trunk/src/SkinDlg.h cinesuite/cineplay-cinecode/trunk/src/Tray.h cinesuite/cineplay-cinecode/trunk/src/Utils.h cinesuite/cineplay-cinecode/trunk/src/Version.h cinesuite/cineplay-cinecode/trunk/src/about.h cinesuite/cineplay-cinecode/trunk/src/log.h cinesuite/cineplay-cinecode/trunk/src/pinfo.h Modified: cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -18,7 +18,7 @@ // Copyright (C) 2008 Audiotube Ltd. // For more information, see http://www.audiotube.com -#include "AddFavouriteDlg.h" +#include "AddFavouriteDlg.hpp" // qt #include "QFileInfo" Deleted: cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,52 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - -#pragma once - -// local -#include "SkinDlg.h" -#include "PlayList.h" - -// generated -#include "ui_addfav.h" - -// qt -#include <QImage> -#include <QString> - -class AddFavouriteDlg : public SkinDialog -{ -protected: - Ui::add_favourite ui; - cineplay::CFavourites* m_favList; - QString m_fname; - QImage m_thumbnail; - int m_currentFrame; - -public: - - AddFavouriteDlg( QWidget *parent, - cineplay::CFavourites *favs, - const QString &fname, - int currentFrame, - QImage thumbnail ); - - void accept(); -}; Copied: cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/AddFavouriteDlg.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,52 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + +#pragma once + +// local +#include "SkinDlg.hpp" +#include "PlayList.hpp" + +// generated +#include "ui_addfav.h" + +// qt +#include <QImage> +#include <QString> + +class AddFavouriteDlg : public SkinDialog +{ +protected: + Ui::add_favourite ui; + cineplay::CFavourites* m_favList; + QString m_fname; + QImage m_thumbnail; + int m_currentFrame; + +public: + + AddFavouriteDlg( QWidget *parent, + cineplay::CFavourites *favs, + const QString &fname, + int currentFrame, + QImage thumbnail ); + + void accept(); +}; Modified: cinesuite/cineplay-cinecode/trunk/src/CineCode.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CineCode.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/CineCode.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -19,19 +19,19 @@ // For more information, see http://www.audiotube.com // local -#include "CineCode.h" -#include "Common.h" -#include "Tray.h" -#include "Utils.h" -#include "EncodeJob.h" -#include "SetupDefs.h" -#include "Version.h" -#include "EncodeTrayEntry.h" -#include "FavoriteTrayEntry.h" -#include "LogMessageHandler.h" -#include "log.h" +#include "CineCode.hpp" +#include "Common.hpp" +#include "Tray.hpp" +#include "Utils.hpp" +#include "EncodeJob.hpp" +#include "SetupDefs.hpp" +#include "Version.hpp" +#include "EncodeTrayEntry.hpp" +#include "FavoriteTrayEntry.hpp" +#include "LogMessageHandler.hpp" +#include "log.hpp" #include "timelineSlider.h" -#include "ScrollViewResizer.h" +#include "ScrollViewResizer.hpp" // qt #include <QScrollArea> Deleted: cinesuite/cineplay-cinecode/trunk/src/CineCode.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CineCode.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/CineCode.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,119 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - - -#pragma once - -#include "ui_main_cinecode.h" -#include "FrameRange.hpp" - -// std -#include <list> -#include <vector> - -// qt -#include <QWidget> - -// generated -#include "ui_filters.h" - -class Tray; -class QStackedWidget; - -namespace cineplay -{ - -class Common; -class EncodeJob; - -class CineCode : public QWidget -{ - Q_OBJECT - -public: - typedef std::list< EncodeJob* > EncodeJobList; - typedef std::vector< QWidget* > WidgetVector; - - CineCode( QWidget *parent = NULL ); - ~CineCode(); - - bool LoadCmdLineInput( const QString& fname ); - bool init( const QStringList& args ); - -protected: - virtual void keyPressEvent( QKeyEvent* ); - virtual void mousePressEvent( QMouseEvent* ); - virtual void mouseReleaseEvent( QMouseEvent* ); - virtual void mouseMoveEvent( QMouseEvent* ); - virtual void mouseDoubleClickEvent( QMouseEvent* ); - virtual void resizeEvent( QResizeEvent* ); - virtual void dragEnterEvent( QDragEnterEvent* ); - virtual void dropEvent( QDropEvent* ); - virtual void customEvent( QEvent* ); - -private slots: - void onResetInOutPoints(); - void onSetInPoint(); - void onSetOutPoint(); - void onEncode(); - void onCancelAll(); - void onEncodeOptions(); - - void onCleanup(); - - // effects - void onFiltersEnabled( bool ); - void onContrastChanged( int ); - void onHueChanged( int ); - void onBrightnessChanged( int ); - void onSaturationChanged( int ); - - // favourites - void onFavouritesChanged(); - void onRemoveFavorite( int ); - void onSelectFavorite( int ); - - // stack management - void onShowEncode(); - void onShowFavourites(); - -private: - void setFilterValue( const char* key, double v ); - void storeFilterSettings(); - - Common* m_impl; - - Tray* m_effectsTray; - Ui::filters m_effects; - - Tray* m_encodeTray; - QWidget* m_encodeTrayPlaceholder; - QWidget* m_favouriteTrayPlaceholder; - EncodeJobList m_encodeJobList; - WidgetVector m_favouriteTrayEntries; - - QStackedWidget* m_encodeStack; - FrameRangeList m_frameRanges; - - Ui::Main ui; -}; - - -} //namespace cineplay Copied: cinesuite/cineplay-cinecode/trunk/src/CineCode.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/CineCode.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CineCode.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/CineCode.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,119 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + + +#pragma once + +#include "ui_main_cinecode.h" +#include "FrameRange.hpp" + +// std +#include <list> +#include <vector> + +// qt +#include <QWidget> + +// generated +#include "ui_filters.h" + +class Tray; +class QStackedWidget; + +namespace cineplay +{ + +class Common; +class EncodeJob; + +class CineCode : public QWidget +{ + Q_OBJECT + +public: + typedef std::list< EncodeJob* > EncodeJobList; + typedef std::vector< QWidget* > WidgetVector; + + CineCode( QWidget *parent = NULL ); + ~CineCode(); + + bool LoadCmdLineInput( const QString& fname ); + bool init( const QStringList& args ); + +protected: + virtual void keyPressEvent( QKeyEvent* ); + virtual void mousePressEvent( QMouseEvent* ); + virtual void mouseReleaseEvent( QMouseEvent* ); + virtual void mouseMoveEvent( QMouseEvent* ); + virtual void mouseDoubleClickEvent( QMouseEvent* ); + virtual void resizeEvent( QResizeEvent* ); + virtual void dragEnterEvent( QDragEnterEvent* ); + virtual void dropEvent( QDropEvent* ); + virtual void customEvent( QEvent* ); + +private slots: + void onResetInOutPoints(); + void onSetInPoint(); + void onSetOutPoint(); + void onEncode(); + void onCancelAll(); + void onEncodeOptions(); + + void onCleanup(); + + // effects + void onFiltersEnabled( bool ); + void onContrastChanged( int ); + void onHueChanged( int ); + void onBrightnessChanged( int ); + void onSaturationChanged( int ); + + // favourites + void onFavouritesChanged(); + void onRemoveFavorite( int ); + void onSelectFavorite( int ); + + // stack management + void onShowEncode(); + void onShowFavourites(); + +private: + void setFilterValue( const char* key, double v ); + void storeFilterSettings(); + + Common* m_impl; + + Tray* m_effectsTray; + Ui::filters m_effects; + + Tray* m_encodeTray; + QWidget* m_encodeTrayPlaceholder; + QWidget* m_favouriteTrayPlaceholder; + EncodeJobList m_encodeJobList; + WidgetVector m_favouriteTrayEntries; + + QStackedWidget* m_encodeStack; + FrameRangeList m_frameRanges; + + Ui::Main ui; +}; + + +} //namespace cineplay Modified: cinesuite/cineplay-cinecode/trunk/src/CinePlay.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CinePlay.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/CinePlay.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -19,18 +19,18 @@ // For more information, see http://www.audiotube.com // local -#include "CinePlay.h" -#include "Common.h" -#include "Tray.h" -#include "SetupDefs.h" -#include "Version.h" -#include "Utils.h" -#include "PlayList.h" -#include "FavoriteTrayEntry.h" -#include "SetupDefs.h" -#include "LogMessageHandler.h" -#include "log.h" -#include "ScrollViewResizer.h" +#include "CinePlay.hpp" +#include "Common.hpp" +#include "Tray.hpp" +#include "SetupDefs.hpp" +#include "Version.hpp" +#include "Utils.hpp" +#include "PlayList.hpp" +#include "FavoriteTrayEntry.hpp" +#include "SetupDefs.hpp" +#include "LogMessageHandler.hpp" +#include "log.hpp" +#include "ScrollViewResizer.hpp" // qt #include <QApplication> Deleted: cinesuite/cineplay-cinecode/trunk/src/CinePlay.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CinePlay.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/CinePlay.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,78 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - - -#pragma once - -#include "ui_main.h" - -// std -#include <vector> - -// qt -#include <QWidget> - -class Tray; - -namespace cineplay -{ - -class Common; - -class CinePlay : public QWidget -{ - Q_OBJECT - -public: - typedef std::vector< QWidget* > WidgetVector; - - CinePlay( QWidget *parent = NULL ); - - bool LoadCmdLineInput( const QString& fname ); - bool init( const QStringList& args ); - -protected: - virtual void keyPressEvent( QKeyEvent* ); - virtual void mousePressEvent( QMouseEvent* ); - virtual void mouseReleaseEvent( QMouseEvent* ); - virtual void mouseMoveEvent( QMouseEvent* ); - virtual void mouseDoubleClickEvent( QMouseEvent* ); - virtual void resizeEvent( QResizeEvent* ); - virtual void dragEnterEvent( QDragEnterEvent* ); - virtual void dropEvent( QDropEvent* ); - virtual void customEvent( QEvent* ); - -private slots: - void onFavouritesChanged(); - void onRemoveFavorite( int ); - void onSelectFavorite( int ); - -private: - Common* m_impl; - - Tray* m_favoritesTray; - QWidget* m_trayPlaceholder; - WidgetVector m_trayEntries; - - Ui::Main ui; -}; - -} //namespace cineplay - Copied: cinesuite/cineplay-cinecode/trunk/src/CinePlay.hpp (from rev 237, cinesuite/cineplay-cinecode/trunk/src/CinePlay.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/CinePlay.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/CinePlay.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,78 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + + +#pragma once + +#include "ui_main.h" + +// std +#include <vector> + +// qt +#include <QWidget> + +class Tray; + +namespace cineplay +{ + +class Common; + +class CinePlay : public QWidget +{ + Q_OBJECT + +public: + typedef std::vector< QWidget* > WidgetVector; + + CinePlay( QWidget *parent = NULL ); + + bool LoadCmdLineInput( const QString& fname ); + bool init( const QStringList& args ); + +protected: + virtual void keyPressEvent( QKeyEvent* ); + virtual void mousePressEvent( QMouseEvent* ); + virtual void mouseReleaseEvent( QMouseEvent* ); + virtual void mouseMoveEvent( QMouseEvent* ); + virtual void mouseDoubleClickEvent( QMouseEvent* ); + virtual void resizeEvent( QResizeEvent* ); + virtual void dragEnterEvent( QDragEnterEvent* ); + virtual void dropEvent( QDropEvent* ); + virtual void customEvent( QEvent* ); + +private slots: + void onFavouritesChanged(); + void onRemoveFavorite( int ); + void onSelectFavorite( int ); + +private: + Common* m_impl; + + Tray* m_favoritesTray; + QWidget* m_trayPlaceholder; + WidgetVector m_trayEntries; + + Ui::Main ui; +}; + +} //namespace cineplay + Modified: cinesuite/cineplay-cinecode/trunk/src/Command.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Command.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Command.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -18,10 +18,10 @@ // Copyright (C) 2008 Audiotube Ltd. // For more information, see http://www.audiotube.com -#include "Command.h" +#include "Command.hpp" // local -#include "log.h" +#include "log.hpp" namespace cineplay { Deleted: cinesuite/cineplay-cinecode/trunk/src/Command.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Command.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Command.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,77 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - - -#pragma once - -// boost -#include <boost/shared_ptr.hpp> - -// std -#include <deque> - -// qt -#include <QMutex> -#include <QWaitCondition> - - - -namespace cineplay -{ - class Command; - typedef boost::shared_ptr< Command > CommandPtr; - typedef std::deque< CommandPtr > CommandPtrQueue; - - class Command - { - public: - Command() {} - virtual ~Command() {} - virtual void execute() = 0; - virtual int id() { return 0; } - virtual bool groupSimilar() { return false; } - virtual void combine( CommandPtr ) {} - }; - - - class CommandQueue - { - public: - CommandQueue(); - ~CommandQueue() {} - - void postCommand( CommandPtr cmd ); - CommandPtr deliverCommand(); - CommandPtrQueue deliverAllCommands(); - unsigned short size(); - bool haveCommands(); - void waitForCommands(); - - private: - QWaitCondition m_condition; - CommandPtrQueue m_deque; - QMutex m_mutex; - }; - - - - -} //namespace cineplay - Copied: cinesuite/cineplay-cinecode/trunk/src/Command.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/Command.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Command.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/Command.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,77 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + + +#pragma once + +// boost +#include <boost/shared_ptr.hpp> + +// std +#include <deque> + +// qt +#include <QMutex> +#include <QWaitCondition> + + + +namespace cineplay +{ + class Command; + typedef boost::shared_ptr< Command > CommandPtr; + typedef std::deque< CommandPtr > CommandPtrQueue; + + class Command + { + public: + Command() {} + virtual ~Command() {} + virtual void execute() = 0; + virtual int id() { return 0; } + virtual bool groupSimilar() { return false; } + virtual void combine( CommandPtr ) {} + }; + + + class CommandQueue + { + public: + CommandQueue(); + ~CommandQueue() {} + + void postCommand( CommandPtr cmd ); + CommandPtr deliverCommand(); + CommandPtrQueue deliverAllCommands(); + unsigned short size(); + bool haveCommands(); + void waitForCommands(); + + private: + QWaitCondition m_condition; + CommandPtrQueue m_deque; + QMutex m_mutex; + }; + + + + +} //namespace cineplay + Modified: cinesuite/cineplay-cinecode/trunk/src/Common.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Common.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Common.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -21,29 +21,29 @@ // Must be included before any other gl headers #include "shader_state.h" -#include "Common.h" +#include "Common.hpp" // std #include <fstream> // local -#include "OpenGLStore.h" +#include "OpenGLStore.hpp" #include "opengl_store.hpp" -#include "Download.h" -#include "Info.h" -#include "Release.h" -#include "ReleaseDlg.h" -#include "SetupDefs.h" -#include "SkinDlg.h" -#include "Version.h" -#include "PlayerDelegate.h" -#include "AddFavouriteDlg.h" -#include "RemoveFavouriteDlg.h" -#include "Utils.h" -#include "Tray.h" -#include "log.h" -#include "GridLayoutCallback.h" -#include "about.h" +#include "Download.hpp" +#include "Info.hpp" +#include "Release.hpp" +#include "ReleaseDlg.hpp" +#include "SetupDefs.hpp" +#include "SkinDlg.hpp" +#include "Version.hpp" +#include "PlayerDelegate.hpp" +#include "AddFavouriteDlg.hpp" +#include "RemoveFavouriteDlg.hpp" +#include "Utils.hpp" +#include "Tray.hpp" +#include "log.hpp" +#include "GridLayoutCallback.hpp" +#include "about.hpp" #include "ResourceUtil.hpp" #include "CSSEditor.hpp" Deleted: cinesuite/cineplay-cinecode/trunk/src/Common.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Common.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Common.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,251 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - -#pragma once - -// local -#include "Player.h" -#include "PlayList.h" -#include "PlayerMultiplexer.hpp" - -// qt -#include <QObject> -#include <QString> -#include <QRect> -#include <QMutex> -#include <QDateTime> - -// std -#include <map> - -class Download; -class Info; -class Release; -class ReleaseDlg; -class Tray; -class QMenu; -class QMenuBar; -class QStringList; -class QKeyEvent; -class QMouseEvent; -class QResizeEvent; -class QDragEnterEvent; -class QDropEvent; -class QAction; - -namespace cineplay -{ - -class Common : public QObject -{ - Q_OBJECT - -public: - Common( QWidget* parent ); - ~Common(); - - bool init( const QStringList& args ); - bool LoadCmdLineInput( const QString& fname ); - bool HandlePush() { return m_handlePush; } - void FrameUpdate( IPlayerPtr, const ml::frame_type_ptr& frame ); - void keyPressEvent( QKeyEvent* ); - -signals: - void LoadInputStarted( const QString& ); - -public slots: - void toggleMaximized(); - void toggleFullScreen(); - - // transport controls - void onPlay(); - void onStepFwd(); - void onStepBack(); - void onStart(); - void onEnd(); - - // load - void onLoad(); - void onLoadUrl(); - void onLoadSequence(); - void onClose(); - void onSaveAs(); - - // display options - void onViewHalfSize(); - void onViewNormalSize(); - void onViewDoubleSize(); - void onViewHideVideo(); - void onViewLoop(); - void onPlayAll(); - - void onWindowInfo(); - void onWindowFavourites(); - void onWindowAddFav(); - void onHelp(); - void onAbout(); - void onCheckVersion(); - void checkVersionDone( const bool ); - void onCheckRelease( const bool ); - void checkReleaseDone( const bool, const bool ); - void onGotoWebsite(); - void onMruSelected(); - void onFavSelected(); - void onFavSelected( int index ); - void onFavAdd(); - void onFavRemove(); - void updateFavMenu(); - void onShowMovieInfo(); - - // time line - void timeSliderPressed(); - void timeSliderReleased(); - void timeSliderMoved( int ); - void timeValueChanged( int ); - void timeInValueChanged( int ); - void timeOutValueChanged( int ); - void timeMinValueChanged( int ); - void timeMaxValueChanged( int ); - - // volume - void volumeSliderMoved( int ); - void muteToggled( bool ); - - void UrlLoadDone( const QString& fname ); - bool LoadInput( const QString& fname ); - bool LoadInput( const QStringList& fnames ); - - // proxied from widget that aggregates common - void mousePressEvent(QMouseEvent *); - void mouseReleaseEvent(QMouseEvent *); - void mouseMoveEvent(QMouseEvent *); - void mouseDoubleClickEvent(QMouseEvent *); - void resizeEvent(QResizeEvent*); - void dragEnterEvent(QDragEnterEvent *de); - void dropEvent(QDropEvent *); - void customEvent(QEvent* e); - - // interaction with in page video - void onVideoSelected( int ); - -public: - bool SetupStores(); - void SimulatePlayClick(); - bool IsResizePos(const QPoint &pt); - bool LoadDefaultInput(); - int SliderToFrame(int val); - int FrameToSlider(int val); - void UpdateSliderPos(int pos); - void SetPlaybuttonState(bool on); - void SetVideoSizeFromStore(float scale = 1.0f); - void SetVideoSize(const QSize &size, float scale = 1.0f); - void SetSizeCheck(int index, bool set); - void ClearSizeChecks(); - void BuildMruMenu( QMenu* menu ); - void onLoad( bool isSequence ); - QString GetLastPath(); - void ShowBorderWidgets(bool show); - - // trays - void saveTrayStates() const; - void restoreTrayStates(); - - // player - IPlayerPtr activePlayer() const; - - // generate a thumbnail from the current frame of the active player - QImage createThumb() const; - - QWidget* m_parent; - QWidget* m_hTitlebar; - QWidget* m_hTitlelogo; - QWidget* m_playButton; - QWidget* m_timeSlider; - QWidget* m_volumeSlider; - int m_timeSliderMin; - int m_timeSliderMax; - bool m_timeSliderBlock; - bool m_timeSliderPlayState; - - bool m_draggingApp; - bool m_resizingApp; - bool m_resizingBlock; - bool m_fullScreen; - bool m_handlePush; - bool m_playerRefresh; - bool m_playControlPopup; - - QMenuBar* m_menubar; - QMenu* m_menuView; - QAction* m_menuViewHalfAction; - QAction* m_menuViewNormalAction; - QAction* m_menuViewDoubleAction; - QAction* m_menuViewShowAction; - QAction* m_menuViewLoopAction; - QAction* m_menuViewPlayAllAction; - QMenu* m_fileMenu; - QMenu* m_windowMenu; - QMenu* m_mruMenu; - QAction* m_mruItemAction; - QMenu* m_favMenu; - QAction* m_favItemAction; - QMenu* m_helpMenu; - QAction* m_helpMenuAction; - - QPoint m_dragClickPos; - QSize m_dragAppSize; - QSize m_mediaSize; - CMruList m_mruList; - CFavourites* m_favList; - int m_currentFavourite; - QString m_lastFile; - int m_lastFrame; - QRect m_preFullScreenRect; - QRect m_preHideScreenRect; - - jw::widget_store* m_jwStore; - QWidget* m_storeAsWidget; - ml::store_type_ptr m_audioStore; - PlayerMultiplexerPtr m_players; - unsigned int m_activePlayerAndStore; - - mutable QMutex m_frameCacheMutex; - ml::frame_type_ptr m_frameCache; - - Download* m_download; - Info* m_info; - bool m_ver_appload; - Release* m_release; - ReleaseDlg* m_release_dialog; - bool m_checkRelease; - bool m_ioPointBlock; - - QTime m_lastMoveTime; - - typedef std::map< QString, Tray* > TrayMap; - TrayMap m_trays; - -#ifdef Q_OS_WIN32 - HINSTANCE hLib; -#endif -}; - -} //namespace cineplay - Copied: cinesuite/cineplay-cinecode/trunk/src/Common.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/Common.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Common.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/Common.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,251 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + +#pragma once + +// local +#include "Player.hpp" +#include "PlayList.hpp" +#include "PlayerMultiplexer.hpp" + +// qt +#include <QObject> +#include <QString> +#include <QRect> +#include <QMutex> +#include <QDateTime> + +// std +#include <map> + +class Download; +class Info; +class Release; +class ReleaseDlg; +class Tray; +class QMenu; +class QMenuBar; +class QStringList; +class QKeyEvent; +class QMouseEvent; +class QResizeEvent; +class QDragEnterEvent; +class QDropEvent; +class QAction; + +namespace cineplay +{ + +class Common : public QObject +{ + Q_OBJECT + +public: + Common( QWidget* parent ); + ~Common(); + + bool init( const QStringList& args ); + bool LoadCmdLineInput( const QString& fname ); + bool HandlePush() { return m_handlePush; } + void FrameUpdate( IPlayerPtr, const ml::frame_type_ptr& frame ); + void keyPressEvent( QKeyEvent* ); + +signals: + void LoadInputStarted( const QString& ); + +public slots: + void toggleMaximized(); + void toggleFullScreen(); + + // transport controls + void onPlay(); + void onStepFwd(); + void onStepBack(); + void onStart(); + void onEnd(); + + // load + void onLoad(); + void onLoadUrl(); + void onLoadSequence(); + void onClose(); + void onSaveAs(); + + // display options + void onViewHalfSize(); + void onViewNormalSize(); + void onViewDoubleSize(); + void onViewHideVideo(); + void onViewLoop(); + void onPlayAll(); + + void onWindowInfo(); + void onWindowFavourites(); + void onWindowAddFav(); + void onHelp(); + void onAbout(); + void onCheckVersion(); + void checkVersionDone( const bool ); + void onCheckRelease( const bool ); + void checkReleaseDone( const bool, const bool ); + void onGotoWebsite(); + void onMruSelected(); + void onFavSelected(); + void onFavSelected( int index ); + void onFavAdd(); + void onFavRemove(); + void updateFavMenu(); + void onShowMovieInfo(); + + // time line + void timeSliderPressed(); + void timeSliderReleased(); + void timeSliderMoved( int ); + void timeValueChanged( int ); + void timeInValueChanged( int ); + void timeOutValueChanged( int ); + void timeMinValueChanged( int ); + void timeMaxValueChanged( int ); + + // volume + void volumeSliderMoved( int ); + void muteToggled( bool ); + + void UrlLoadDone( const QString& fname ); + bool LoadInput( const QString& fname ); + bool LoadInput( const QStringList& fnames ); + + // proxied from widget that aggregates common + void mousePressEvent(QMouseEvent *); + void mouseReleaseEvent(QMouseEvent *); + void mouseMoveEvent(QMouseEvent *); + void mouseDoubleClickEvent(QMouseEvent *); + void resizeEvent(QResizeEvent*); + void dragEnterEvent(QDragEnterEvent *de); + void dropEvent(QDropEvent *); + void customEvent(QEvent* e); + + // interaction with in page video + void onVideoSelected( int ); + +public: + bool SetupStores(); + void SimulatePlayClick(); + bool IsResizePos(const QPoint &pt); + bool LoadDefaultInput(); + int SliderToFrame(int val); + int FrameToSlider(int val); + void UpdateSliderPos(int pos); + void SetPlaybuttonState(bool on); + void SetVideoSizeFromStore(float scale = 1.0f); + void SetVideoSize(const QSize &size, float scale = 1.0f); + void SetSizeCheck(int index, bool set); + void ClearSizeChecks(); + void BuildMruMenu( QMenu* menu ); + void onLoad( bool isSequence ); + QString GetLastPath(); + void ShowBorderWidgets(bool show); + + // trays + void saveTrayStates() const; + void restoreTrayStates(); + + // player + IPlayerPtr activePlayer() const; + + // generate a thumbnail from the current frame of the active player + QImage createThumb() const; + + QWidget* m_parent; + QWidget* m_hTitlebar; + QWidget* m_hTitlelogo; + QWidget* m_playButton; + QWidget* m_timeSlider; + QWidget* m_volumeSlider; + int m_timeSliderMin; + int m_timeSliderMax; + bool m_timeSliderBlock; + bool m_timeSliderPlayState; + + bool m_draggingApp; + bool m_resizingApp; + bool m_resizingBlock; + bool m_fullScreen; + bool m_handlePush; + bool m_playerRefresh; + bool m_playControlPopup; + + QMenuBar* m_menubar; + QMenu* m_menuView; + QAction* m_menuViewHalfAction; + QAction* m_menuViewNormalAction; + QAction* m_menuViewDoubleAction; + QAction* m_menuViewShowAction; + QAction* m_menuViewLoopAction; + QAction* m_menuViewPlayAllAction; + QMenu* m_fileMenu; + QMenu* m_windowMenu; + QMenu* m_mruMenu; + QAction* m_mruItemAction; + QMenu* m_favMenu; + QAction* m_favItemAction; + QMenu* m_helpMenu; + QAction* m_helpMenuAction; + + QPoint m_dragClickPos; + QSize m_dragAppSize; + QSize m_mediaSize; + CMruList m_mruList; + CFavourites* m_favList; + int m_currentFavourite; + QString m_lastFile; + int m_lastFrame; + QRect m_preFullScreenRect; + QRect m_preHideScreenRect; + + jw::widget_store* m_jwStore; + QWidget* m_storeAsWidget; + ml::store_type_ptr m_audioStore; + PlayerMultiplexerPtr m_players; + unsigned int m_activePlayerAndStore; + + mutable QMutex m_frameCacheMutex; + ml::frame_type_ptr m_frameCache; + + Download* m_download; + Info* m_info; + bool m_ver_appload; + Release* m_release; + ReleaseDlg* m_release_dialog; + bool m_checkRelease; + bool m_ioPointBlock; + + QTime m_lastMoveTime; + + typedef std::map< QString, Tray* > TrayMap; + TrayMap m_trays; + +#ifdef Q_OS_WIN32 + HINSTANCE hLib; +#endif +}; + +} //namespace cineplay + Modified: cinesuite/cineplay-cinecode/trunk/src/Download.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Download.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Download.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -19,9 +19,9 @@ // For more information, see http://www.audiotube.com -#include "Download.h" -#include "SkinDlg.h" -#include "Utils.h" +#include "Download.hpp" +#include "SkinDlg.hpp" +#include "Utils.hpp" // generated #include "ui_downloadDialog.h" Deleted: cinesuite/cineplay-cinecode/trunk/src/Download.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Download.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/Download.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,48 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - - -#pragma once - -// qt -#include <QObject> - -class QString; -class QUrl; - -class Download : public QObject -{ - Q_OBJECT - -public: - class DownloadImpl; - - Download( QObject* parent ); - - void show(); - void close(); - -signals: - /// location of the file that has been downloaded - void done( const QString& ); - -private: - DownloadImpl* impl_; -}; Copied: cinesuite/cineplay-cinecode/trunk/src/Download.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/Download.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/Download.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/Download.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,48 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + + +#pragma once + +// qt +#include <QObject> + +class QString; +class QUrl; + +class Download : public QObject +{ + Q_OBJECT + +public: + class DownloadImpl; + + Download( QObject* parent ); + + void show(); + void close(); + +signals: + /// location of the file that has been downloaded + void done( const QString& ); + +private: + DownloadImpl* impl_; +}; Modified: cinesuite/cineplay-cinecode/trunk/src/EncodeJob.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeJob.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeJob.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -20,10 +20,10 @@ // local -#include "EncodeJob.h" -#include "Command.h" -#include "FilterGraph.h" -#include "Utils.h" +#include "EncodeJob.hpp" +#include "Command.hpp" +#include "FilterGraph.hpp" +#include "Utils.hpp" // qt #include <QThread> Deleted: cinesuite/cineplay-cinecode/trunk/src/EncodeJob.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeJob.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeJob.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,73 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - - -#pragma once - -#include <QString> -#include <QStringList> - -#include "FrameRange.hpp" - -namespace cineplay -{ - -class EncodeJobCallback -{ -public: - virtual ~EncodeJobCallback() {} - - virtual void Pausing() = 0; - virtual void Continuing() = 0; - virtual void Progress(float percent) = 0; - virtual void Cancelling() = 0; - virtual void Finished() = 0; - virtual void Error(int code) = 0; -}; - - -class EncodeJob -{ -public: - virtual ~EncodeJob() {} - - virtual void SetCallback(EncodeJobCallback*) = 0; - virtual void Pause() = 0; - virtual void Resume() = 0; - virtual void Cancel() = 0; - virtual bool IsFinished() const = 0; - virtual QString GetInputFilename() = 0; - virtual QString GetOutputFilename() = 0; -}; - -class EncodeManager -{ -public: - virtual ~EncodeManager(); - - EncodeJob* BeginJob( const QString& infile, const QString& outfile, const FrameRangeList& io ); - static EncodeManager* instance(); - -private: - EncodeManager(); -}; - -} //namespace cineplay - Copied: cinesuite/cineplay-cinecode/trunk/src/EncodeJob.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/EncodeJob.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeJob.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeJob.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,73 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + + +#pragma once + +#include <QString> +#include <QStringList> + +#include "FrameRange.hpp" + +namespace cineplay +{ + +class EncodeJobCallback +{ +public: + virtual ~EncodeJobCallback() {} + + virtual void Pausing() = 0; + virtual void Continuing() = 0; + virtual void Progress(float percent) = 0; + virtual void Cancelling() = 0; + virtual void Finished() = 0; + virtual void Error(int code) = 0; +}; + + +class EncodeJob +{ +public: + virtual ~EncodeJob() {} + + virtual void SetCallback(EncodeJobCallback*) = 0; + virtual void Pause() = 0; + virtual void Resume() = 0; + virtual void Cancel() = 0; + virtual bool IsFinished() const = 0; + virtual QString GetInputFilename() = 0; + virtual QString GetOutputFilename() = 0; +}; + +class EncodeManager +{ +public: + virtual ~EncodeManager(); + + EncodeJob* BeginJob( const QString& infile, const QString& outfile, const FrameRangeList& io ); + static EncodeManager* instance(); + +private: + EncodeManager(); +}; + +} //namespace cineplay + Modified: cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -18,13 +18,13 @@ // Copyright (C) 2008 Audiotube Ltd. // For more information, see http://www.audiotube.com -#include "EncodeTrayEntry.h" +#include "EncodeTrayEntry.hpp" // local -#include "Utils.h" -#include "SetupDefs.h" +#include "Utils.hpp" +#include "SetupDefs.hpp" #include "progress.h" -#include "EncodeJob.h" +#include "EncodeJob.hpp" // qt #include <QLayout> Deleted: cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,59 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - -#pragma once - -// qt -#include <QWidget> -#include <QImage> -#include <QEvent> - -// generated -#include "ui_encode_tray_entry.h" - - -class EncodeCustomEvent; -namespace cineplay { - class EncodeJob; -} - -class EncodeTrayEntry : public QWidget -{ - Q_OBJECT - -public: - Ui::encode_tray_entry ui; - - EncodeTrayEntry( QWidget* parent, cineplay::EncodeJob*, QImage thumb ); - bool isFinished() const; - void setFinished(); - -protected: - virtual void customEvent( QEvent* e ); - -private slots: - void onPlayPause(); - void onCancel(); - -private: - friend class EncodeCustomEvent; - cineplay::EncodeJob* m_job; - bool m_finished; -}; Copied: cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/EncodeTrayEntry.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,59 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + +#pragma once + +// qt +#include <QWidget> +#include <QImage> +#include <QEvent> + +// generated +#include "ui_encode_tray_entry.h" + + +class EncodeCustomEvent; +namespace cineplay { + class EncodeJob; +} + +class EncodeTrayEntry : public QWidget +{ + Q_OBJECT + +public: + Ui::encode_tray_entry ui; + + EncodeTrayEntry( QWidget* parent, cineplay::EncodeJob*, QImage thumb ); + bool isFinished() const; + void setFinished(); + +protected: + virtual void customEvent( QEvent* e ); + +private slots: + void onPlayPause(); + void onCancel(); + +private: + friend class EncodeCustomEvent; + cineplay::EncodeJob* m_job; + bool m_finished; +}; Modified: cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -18,7 +18,7 @@ // Copyright (C) 2008 Audiotube Ltd. // For more information, see http://www.audiotube.com -#include "FavoriteTrayEntry.h" +#include "FavoriteTrayEntry.hpp" // local #include "TextElider.hpp" Deleted: cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.h =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.h 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.h 2008-11-07 13:49:07 UTC (rev 238) @@ -1,53 +0,0 @@ -/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ - -// This file is part of Cineplay -// -// Cineplay is free software; you can redistribute it and/or modify -// 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. -// -// Cineplay 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 -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. -// -// Copyright (C) 2008 Audiotube Ltd. -// For more information, see http://www.audiotube.com - -#pragma once - -// qt -#include <QWidget> - -// generated -#include "ui_favorite_tray_entry.h" - -class FavoriteTrayEntry : public QWidget -{ - Q_OBJECT - -public: - FavoriteTrayEntry( QWidget* parent, - int id, - const QString& name, - const QString& location, - const QImage& thumb ); - -signals: - void remove( int id ); - void selected( int id ); - -protected: - void mouseDoubleClickEvent( QMouseEvent* e ); - -private slots: - void onRemoveClicked(); - -private: - int id_; - Ui::favorite_tray_entry ui; -}; Copied: cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.hpp (from rev 232, cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.h) =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.hpp (rev 0) +++ cinesuite/cineplay-cinecode/trunk/src/FavoriteTrayEntry.hpp 2008-11-07 13:49:07 UTC (rev 238) @@ -0,0 +1,53 @@ +/* -*- mode: C++; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*- */ + +// This file is part of Cineplay +// +// Cineplay is free software; you can redistribute it and/or modify +// 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. +// +// Cineplay 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 +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see <http://www.gnu.org/licenses/>. +// +// Copyright (C) 2008 Audiotube Ltd. +// For more information, see http://www.audiotube.com + +#pragma once + +// qt +#include <QWidget> + +// generated +#include "ui_favorite_tray_entry.h" + +class FavoriteTrayEntry : public QWidget +{ + Q_OBJECT + +public: + FavoriteTrayEntry( QWidget* parent, + int id, + const QString& name, + const QString& location, + const QImage& thumb ); + +signals: + void remove( int id ); + void selected( int id ); + +protected: + void mouseDoubleClickEvent( QMouseEvent* e ); + +private slots: + void onRemoveClicked(); + +private: + int id_; + Ui::favorite_tray_entry ui; +}; Modified: cinesuite/cineplay-cinecode/trunk/src/FilterGraph.cpp =================================================================== --- cinesuite/cineplay-cinecode/trunk/src/FilterGraph.cpp 2008-11-07 13:12:43 UTC (rev 237) +++ cinesuite/cineplay-cinecode/trunk/src/FilterGraph.cpp 2008-11-07 13:49:07 UTC (rev 238) @@ -18,7 +18,7 @@ // Copyright (C) 2008 Audiotube Ltd. // For more information, see http://www.audiotube.com -#include "FilterGraph.h" +#include "FilterGraph.hpp" // opl #include <openpluginlib/pl/utf8_utils.hpp> @@ -29,8 +29,8 @@ #include <QtXml> // local -#include "Utils.h" -#include "log.h" +#include "Utils.hpp" +#include "log.hpp" FGException::FGException(const char *str) { Deleted: cinesuite/cineplay-cinecode/trunk/src/FilterGraph.h ===================================================... [truncated message content] |