[longomatch/refactor] WIP
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch/refactor] WIP
- Date: Wed, 2 Nov 2011 00:59:34 +0000 (UTC)
commit 8df1b27a229d9339e9bc7ff04d1b2386236c63d9
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Tue Nov 1 22:57:08 2011 +0100
WIP
CesarPlayer/CesarPlayer.mdp | 82 ---
CesarPlayer/Makefile.am | 54 --
{LongoMatch => LongoMatch.Core}/Common/Cairo.cs | 0
.../Common/CaptureSettings.cs | 3 +-
{LongoMatch => LongoMatch.Core}/Common/Cloner.cs | 0
.../Common/ConsoleCrayon.cs | 0
.../Common/Constants.cs | 3 +-
.../Common/Device.cs | 45 +-
.../Common/EncodingProfiles.cs | 2 +-
.../Common/EncodingSettings.cs | 2 +-
{LongoMatch => LongoMatch.Core}/Common/Enums.cs | 50 ++
{LongoMatch => LongoMatch.Core}/Common/Images.cs | 0
.../JobsManager => LongoMatch.Core/Common}/Job.cs | 6 +-
{LongoMatch => LongoMatch.Core}/Common/Log.cs | 0
.../Common}/PlayList.cs | 28 +-
.../Common/SerializableObject.cs | 0
.../Common/VideoStandards.cs | 2 +-
LongoMatch.Core/Config.cs | 67 ++
.../Handlers/Handlers.cs | 106 ++--
.../Interfaces/IDatabase.cs | 16 +-
.../Interfaces}/IPlayList.cs | 8 +-
.../Interfaces/IPlaylistWidget.cs | 17 +-
.../Interfaces/IRenderingJobsManager.cs | 23 +-
.../Interfaces/ISubCategory.cs | 0
{LongoMatch => LongoMatch.Core}/Interfaces/ITag.cs | 0
.../Interfaces/ITemplates.cs | 0
.../Interfaces/ITemplatesService.cs | 19 +-
LongoMatch.Core/LongoMatch.Core.mdp | 84 +++
LongoMatch.Core/Makefile.am | 54 ++
{LongoMatch => LongoMatch.Core}/Store/Category.cs | 0
{LongoMatch => LongoMatch.Core}/Store/Drawing.cs | 0
{LongoMatch => LongoMatch.Core}/Store/HotKey.cs | 1 -
.../Utils => LongoMatch.Core/Store}/MediaFile.cs | 70 +--
.../Store/PixbufTimeNode.cs | 0
{LongoMatch => LongoMatch.Core}/Store/Play.cs | 0
.../Store/PlayListPlay.cs | 13 +-
{LongoMatch => LongoMatch.Core}/Store/Player.cs | 0
{LongoMatch => LongoMatch.Core}/Store/Project.cs | 0
.../Store/ProjectDescription.cs | 3 +-
.../Store/SubCategory.cs | 0
{LongoMatch => LongoMatch.Core}/Store/Tag.cs | 0
{LongoMatch => LongoMatch.Core}/Store/TagStore.cs | 0
.../Store/Templates/CategoriesTemplate.cs | 0
.../Store/Templates/SubCategoryTemplate.cs | 0
.../Store/Templates/TeamTemplate.cs | 0
.../Store/Templates/Template.cs | 0
{LongoMatch => LongoMatch.Core}/Store/Time.cs | 0
{LongoMatch => LongoMatch.Core}/Store/TimeNode.cs | 10 +
.../AssemblyInfo.cs | 2 +-
.../AssemblyInfo.cs.in | 0
.../CesarPlayer.csproj | 0
.../CesarPlayer.dll.config.in | 0
.../Gui/CapturerBin.cs | 3 +-
.../Gui/PlayerBin.cs | 1 +
.../Gui/VolumeWindow.cs | 0
.../LongoMatch.GUI.Multimedia.mdp | 53 ++
.../LongoMatch.Gui.Multimedia.dll.config | 3 +
LongoMatch.GUI.Multimedia/Makefile.am | 23 +
LongoMatch.GUI.Multimedia/a.dll | Bin 0 -> 110080 bytes
LongoMatch.GUI.Multimedia/a.dll.mdb | Bin 0 -> 32860 bytes
.../cesarplayer.key | Bin 596 -> 596 bytes
.../cesarplayer.pc | 2 +-
.../cesarplayer.pc.in | 0
.../gtk-gui/LongoMatch.Gui.CapturerBin.cs | 0
.../gtk-gui/LongoMatch.Gui.PlayerBin.cs | 0
.../gtk-gui/LongoMatch.Gui.VolumeWindow.cs | 0
.../gtk-gui/generated.cs | 0
.../gtk-gui/gui.stetic | 4 +-
.../gtk-gui/objects.xml | 18 +-
.../Gui/Component/ButtonsWidget.cs | 6 +-
.../Gui/Component/CategoriesScale.cs | 0
.../Gui/Component/CategoriesTemplateEditor.cs | 9 +-
.../Gui/Component/CategoryProperties.cs | 20 +-
.../Gui/Component/DrawingToolBox.cs | 1 +
.../Gui/Component/DrawingWidget.cs | 13 +-
.../Gui/Component/NotesWidget.cs | 0
LongoMatch.GUI/Gui/Component/PlayListWidget.cs | 123 ++++
.../Gui/Component/PlayerProperties.cs | 0
.../Gui/Component/PlayersListTreeWidget.cs | 2 +-
.../Gui/Component/PlayersTaggerWidget.cs | 0
.../Gui/Component/PlaysListTreeWidget.cs | 12 +-
.../Gui/Component/ProjectDetailsWidget.cs | 70 +-
.../Gui/Component/ProjectListWidget.cs | 2 -
.../Gui/Component/RenderingStateBar.cs | 0
.../Gui/Component/StringTaggerWidget.cs | 0
.../Gui/Component/TaggerWidget.cs | 0
.../Gui/Component/TagsTreeWidget.cs | 3 +-
.../Gui/Component/TeamTaggerWidget.cs | 0
.../Gui/Component/TeamTemplateEditor.cs | 5 +-
.../Gui/Component/TemplatesEditorBase.cs | 4 +-
.../Gui/Component/TimeLineWidget.cs | 12 +-
.../Gui/Component/TimeReferenceWidget.cs | 0
.../Gui/Component/TimeScale.cs | 6 +-
.../Gui/Dialog/About.cs | 34 +-
.../Gui/Dialog/BusyDialog.cs | 0
.../Gui/Dialog/DrawingTool.cs | 8 +-
.../Gui/Dialog/EditCategoryDialog.cs | 0
.../Gui/Dialog/EditPlayerDialog.cs | 0
.../Gui/Dialog/EndCaptureDialog.cs | 0
.../Gui/Dialog/EntryDialog.cs | 0
.../Gui/Dialog/FramesCaptureProgressDialog.cs | 0
.../Gui/Dialog/HotKeySelectorDialog.cs | 0
.../Gui/Dialog/NewProjectDialog.cs | 0
.../Gui/Dialog/OpenProjectDialog.cs | 5 +-
.../Gui/Dialog/PlayersSelectionDialog.cs | 0
.../Gui/Dialog/ProjectSelectionDialog.cs | 0
.../Gui/Dialog/ProjectsManager.cs | 22 +-
.../Gui/Dialog/RenderingJobsDialog.cs | 6 +-
.../Gui/Dialog/SnapshotsDialog.cs | 0
.../Gui/Dialog/SubCategoryTagsEditor.cs | 4 +-
.../Gui/Dialog/TaggerDialog.cs | 0
.../Gui/Dialog/TemplateEditorDialog.cs | 4 +-
.../Gui/Dialog/TemplatesManager.cs | 10 +-
.../Gui/Dialog/UpdateDialog.cs | 0
.../Gui/Dialog/VideoEditionProperties.cs | 3 +-
.../Gui/Dialog/Win32CalendarDialog.cs | 0
LongoMatch.GUI/Gui/MainWindow.cs | 738 ++++++++++++++++++++
.../Gui/Popup/CalendarPopup.cs | 0
.../Gui/Popup/MessagePopup.cs | 0
.../Gui/TransparentDrawingArea.cs | 0
.../Gui/TreeView/CategoriesTreeView.cs | 0
.../Gui/TreeView/ListTreeViewBase.cs | 4 +-
.../Gui/TreeView/PlayListTreeView.cs | 50 +-
.../Gui/TreeView/PlayerPropertiesTreeView.cs | 0
.../Gui/TreeView/PlayersTreeView.cs | 0
.../Gui/TreeView/PlaysTreeView.cs | 0
.../Gui/TreeView/RenderingJobsTreeView.cs | 2 +-
.../Gui/TreeView/SubCategoriesTreeView.cs | 0
.../Gui/TreeView/TagsTreeView.cs | 0
LongoMatch.GUI/LongoMatch.GUI.mdp | 157 +++++
LongoMatch.GUI/Makefile.am | 125 ++++
.../LongoMatch.Gui.Component.ButtonsWidget.cs | 0
.../LongoMatch.Gui.Component.CategoryProperties.cs | 0
.../LongoMatch.Gui.Component.DrawingToolBox.cs | 0
.../LongoMatch.Gui.Component.DrawingWidget.cs | 0
.../LongoMatch.Gui.Component.NotesWidget.cs | 0
.../LongoMatch.Gui.Component.PlayListWidget.cs | 1 -
.../LongoMatch.Gui.Component.PlayerProperties.cs | 0
...ngoMatch.Gui.Component.PlayersListTreeWidget.cs | 0
...LongoMatch.Gui.Component.PlayersTaggerWidget.cs | 0
...LongoMatch.Gui.Component.PlaysListTreeWidget.cs | 0
...ongoMatch.Gui.Component.ProjectDetailsWidget.cs | 0
.../LongoMatch.Gui.Component.ProjectListWidget.cs | 0
.../LongoMatch.Gui.Component.RenderingStateBar.cs | 0
.../LongoMatch.Gui.Component.StringTaggerWidget.cs | 0
.../LongoMatch.Gui.Component.TaggerWidget.cs | 0
.../LongoMatch.Gui.Component.TagsTreeWidget.cs | 0
.../LongoMatch.Gui.Component.TeamTaggerWidget.cs | 0
...LongoMatch.Gui.Component.TemplatesEditorBase.cs | 0
.../LongoMatch.Gui.Component.TimeLineWidget.cs | 0
.../gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs | 0
.../gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs | 0
.../LongoMatch.Gui.Dialog.EditCategoryDialog.cs | 0
.../LongoMatch.Gui.Dialog.EditPlayerDialog.cs | 0
.../LongoMatch.Gui.Dialog.EndCaptureDialog.cs | 0
.../gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs | 0
...Match.Gui.Dialog.FramesCaptureProgressDialog.cs | 0
.../LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs | 0
.../LongoMatch.Gui.Dialog.NewProjectDialog.cs | 0
.../LongoMatch.Gui.Dialog.OpenProjectDialog.cs | 0
...LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs | 0
...LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs | 0
.../LongoMatch.Gui.Dialog.ProjectsManager.cs | 0
.../LongoMatch.Gui.Dialog.RenderingJobsDialog.cs | 0
.../LongoMatch.Gui.Dialog.SnapshotsDialog.cs | 0
.../LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs | 0
.../gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs | 0
.../LongoMatch.Gui.Dialog.TemplateEditorDialog.cs | 0
.../LongoMatch.Gui.Dialog.TemplatesManager.cs | 0
.../gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs | 0
...LongoMatch.Gui.Dialog.VideoEditionProperties.cs | 0
.../LongoMatch.Gui.Dialog.Win32CalendarDialog.cs | 0
.../gtk-gui/LongoMatch.Gui.MainWindow.cs | 174 +++---
.../gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs | 0
.../LongoMatch.Gui.Popup.TransparentDrawingArea.cs | 0
.../gtk-gui/generated.cs | 0
{LongoMatch => LongoMatch.GUI}/gtk-gui/gui.stetic | 39 +-
{LongoMatch => LongoMatch.GUI}/gtk-gui/objects.xml | 220 +++---
.../Capturer/FakeCapturer.cs | 2 +
.../Capturer/GstCameraCapturer.cs | 40 +-
.../Capturer/LiveSourceTimer.cs | 0
.../Capturer/ObjectManager.cs | 0
.../Common/Constants.cs | 2 +-
.../Common/Enum.cs | 37 +-
.../Common/Handlers.cs | 2 +-
.../Editor/EditorState.cs | 0
.../Editor/GstVideoSplitter.cs | 2 +
.../Editor/VideoSegment.cs | 0
.../Interfaces}/ICapturer.cs | 3 +-
.../Interfaces}/IFramesCapturer.cs | 2 +-
.../Interfaces}/IPlayer.cs | 3 +-
.../Interfaces}/IVideoEditor.cs | 4 +-
LongoMatch.Multimedia/LongoMatch.Multimedia.mdp | 68 ++
LongoMatch.Multimedia/Makefile.am | 33 +
.../MultimediaFactory.cs | 9 +
.../Player/GstPlayer.cs | 1 +
.../Player/ObjectManager.cs | 0
.../Utils/FramesCapturer.cs | 1 +
.../Utils}/GStreamer.cs | 30 +-
.../Utils/IMetadataReader.cs | 0
.../Utils/MpegRemuxer.cs | 0
.../Utils/PreviewMediaFile.cs | 52 +--
.../Utils/TimeString.cs | 0
.../Utils/VideoDevice.cs | 88 +--
LongoMatch.Services/LongoMatch.Services.mdp | 39 +
LongoMatch.Services/Makefile.am | 17 +
LongoMatch.Services/Services/Core.cs | 167 +++++
.../Services/DataBase.cs | 9 +-
LongoMatch.Services/Services/EventsManager.cs | 314 +++++++++
.../Services}/HotKeysManager.cs | 5 +-
LongoMatch.Services/Services/PlaylistManager.cs | 219 ++++++
LongoMatch.Services/Services/ProjectsManager.cs | 505 +++++++++++++
.../Services}/RenderingJobsManager.cs | 43 +-
.../Services/TemplatesService.cs | 6 +-
.../Services}/VideoDrawingsManager.cs | 18 +-
LongoMatch.mds | 36 +-
LongoMatch/Common/GuiUtils.cs | 53 --
LongoMatch/Common/ProjectUtils.cs | 298 --------
LongoMatch/Gui/Component/PlayListWidget.cs | 262 -------
LongoMatch/Gui/Dialog/Migrator.cs | 133 ----
LongoMatch/Gui/MainWindow.cs | 643 -----------------
LongoMatch/Handlers/DrawingManager.cs | 80 ---
LongoMatch/Handlers/EventsManager.cs | 430 ------------
LongoMatch/IO/CSVExport.cs | 184 -----
LongoMatch/IO/XMLReader.cs | 88 ---
LongoMatch/LongoMatch.csproj | 207 ------
LongoMatch/LongoMatch.mdp | 221 +------
LongoMatch/Main.cs | 178 +-----
LongoMatch/Makefile.am | 177 +-----
LongoMatch/Updates/Updater.cs | 104 ---
LongoMatch/Updates/XmlUpdateParser.cs | 74 --
.../gtk-gui/LongoMatch.Gui.Dialog.Migrator.cs | 188 -----
...ongoMatch.Gui.TreeView.RenderingJobsTreeView.cs | 19 -
Makefile.am | 11 +-
build/build.environment.mk | 54 ++-
configure.ac | 12 +-
{LongoMatch/images => images}/background.png | Bin 53472 -> 53472 bytes
{LongoMatch/images => images}/background.svg | 0
{LongoMatch/images => images}/camera-video.png | Bin 1660 -> 1660 bytes
{LongoMatch/images => images}/logo.svg | 0
{LongoMatch/images => images}/logo_48x48.png | Bin 3045 -> 3045 bytes
{LongoMatch/images => images}/longomatch.png | Bin 3045 -> 3045 bytes
{LongoMatch/images => images}/minilogo.ico | Bin 9662 -> 9662 bytes
{LongoMatch/images => images}/minilogo.png | Bin 3045 -> 3045 bytes
{LongoMatch/images => images}/minilogo.rc | 0
{LongoMatch/images => images}/resource.h | 0
.../stock_draw-circle-unfilled.png | Bin 418 -> 418 bytes
.../images => images}/stock_draw-freeform-line.png | Bin 276 -> 276 bytes
.../images => images}/stock_draw-line-45.png | Bin 113 -> 113 bytes
.../stock_draw-line-ends-with-arrow.png | Bin 155 -> 155 bytes
.../stock_draw-rectangle-unfilled.png | Bin 123 -> 123 bytes
{LongoMatch/images => images}/video.png | Bin 2044 -> 2044 bytes
libcesarplayer/video-utils.c | 7 +
libcesarplayer/video-utils.h | 8 +
po/Translations.mdse | 6 +-
tools/deb-pkg.sh | 2 +-
256 files changed, 3760 insertions(+), 4207 deletions(-)
---
diff --git a/LongoMatch/Common/Cairo.cs b/LongoMatch.Core/Common/Cairo.cs
similarity index 100%
rename from LongoMatch/Common/Cairo.cs
rename to LongoMatch.Core/Common/Cairo.cs
diff --git a/CesarPlayer/Common/CaptureSettings.cs b/LongoMatch.Core/Common/CaptureSettings.cs
similarity index 95%
rename from CesarPlayer/Common/CaptureSettings.cs
rename to LongoMatch.Core/Common/CaptureSettings.cs
index 1151e85..d28ddd6 100644
--- a/CesarPlayer/Common/CaptureSettings.cs
+++ b/LongoMatch.Core/Common/CaptureSettings.cs
@@ -17,9 +17,8 @@
//
using System;
-using LongoMatch.Video.Common;
-namespace LongoMatch.Video.Capturer
+namespace LongoMatch.Common
{
public struct CaptureSettings
diff --git a/LongoMatch/Common/Cloner.cs b/LongoMatch.Core/Common/Cloner.cs
similarity index 100%
copy from LongoMatch/Common/Cloner.cs
copy to LongoMatch.Core/Common/Cloner.cs
diff --git a/LongoMatch/Common/ConsoleCrayon.cs b/LongoMatch.Core/Common/ConsoleCrayon.cs
similarity index 100%
rename from LongoMatch/Common/ConsoleCrayon.cs
rename to LongoMatch.Core/Common/ConsoleCrayon.cs
diff --git a/LongoMatch/Common/Constants.cs b/LongoMatch.Core/Common/Constants.cs
similarity index 99%
rename from LongoMatch/Common/Constants.cs
rename to LongoMatch.Core/Common/Constants.cs
index dcd3ebe..3c14bcf 100644
--- a/LongoMatch/Common/Constants.cs
+++ b/LongoMatch.Core/Common/Constants.cs
@@ -19,9 +19,10 @@
using System;
using Gdk;
+
namespace LongoMatch.Common
{
- class Constants {
+ public class Constants {
public const string SOFTWARE_NAME = "LongoMatch";
public const string PROJECT_NAME = SOFTWARE_NAME + " project";
diff --git a/LongoMatch/Gui/Dialog/ProjectSelectionDialog.cs b/LongoMatch.Core/Common/Device.cs
similarity index 57%
copy from LongoMatch/Gui/Dialog/ProjectSelectionDialog.cs
copy to LongoMatch.Core/Common/Device.cs
index e62a596..e27c303 100644
--- a/LongoMatch/Gui/Dialog/ProjectSelectionDialog.cs
+++ b/LongoMatch.Core/Common/Device.cs
@@ -17,30 +17,45 @@
//
using System;
-using LongoMatch.Common;
+using System.Collections.Generic;
+using Mono.Unix;
-namespace LongoMatch.Gui.Dialog
+
+namespace LongoMatch.Common
{
- public partial class ProjectSelectionDialog : Gtk.Dialog
+ public class Device
{
+ public Device() {
+
+ }
- public ProjectSelectionDialog()
- {
- this.Build();
+ /// <summary>
+ /// Device Type among Video, Audio or DV (for dv cameras)
+ /// </summary>
+ public DeviceType DeviceType {
+ get;
+ set;
}
- public ProjectType ProjectType {
- get {
- if(fromfileradiobutton.Active)
- return ProjectType.FileProject;
- else if(liveradiobutton.Active)
- return ProjectType.CaptureProject;
- else
- return ProjectType.FakeCaptureProject;
+ /// <summary>
+ /// Device id, can be a human friendly name (for DirectShow devices),
+ /// the de device name (/dev/video0) or the GUID (dv1394src)
+ /// </summary>
+ public string ID {
+ get;
+ set;
+ }
+
+ /// <summary>
+ /// The name of the gstreamer element property used to set the device
+ /// </summary>
- }
+ public string IDProperty {
+ get;
+ set;
}
+
}
}
diff --git a/CesarPlayer/Common/EncodingProfiles.cs b/LongoMatch.Core/Common/EncodingProfiles.cs
similarity index 98%
rename from CesarPlayer/Common/EncodingProfiles.cs
rename to LongoMatch.Core/Common/EncodingProfiles.cs
index 9aa9317..03f4cf2 100644
--- a/CesarPlayer/Common/EncodingProfiles.cs
+++ b/LongoMatch.Core/Common/EncodingProfiles.cs
@@ -16,7 +16,7 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
-namespace LongoMatch.Video.Common
+namespace LongoMatch.Common
{
[Serializable]
public struct EncodingProfile
diff --git a/CesarPlayer/Common/EncodingSettings.cs b/LongoMatch.Core/Common/EncodingSettings.cs
similarity index 97%
rename from CesarPlayer/Common/EncodingSettings.cs
rename to LongoMatch.Core/Common/EncodingSettings.cs
index e9d9926..eabc120 100644
--- a/CesarPlayer/Common/EncodingSettings.cs
+++ b/LongoMatch.Core/Common/EncodingSettings.cs
@@ -16,7 +16,7 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
-namespace LongoMatch.Video.Common
+namespace LongoMatch.Common
{
[Serializable]
public struct EncodingSettings
diff --git a/LongoMatch/Common/Enums.cs b/LongoMatch.Core/Common/Enums.cs
similarity index 72%
rename from LongoMatch/Common/Enums.cs
rename to LongoMatch.Core/Common/Enums.cs
index f7906b5..ddfd87f 100644
--- a/LongoMatch/Common/Enums.cs
+++ b/LongoMatch.Core/Common/Enums.cs
@@ -61,4 +61,54 @@ namespace LongoMatch.Common
Cancelled,
Error,
}
+
+ public enum VideoEncoderType {
+ Mpeg4,
+ Xvid,
+ Theora,
+ H264,
+ Mpeg2,
+ VP8,
+ }
+
+ public enum AudioEncoderType {
+ Mp3,
+ Aac,
+ Vorbis,
+ }
+
+ public enum VideoMuxerType {
+ Avi,
+ Mp4,
+ Matroska,
+ Ogg,
+ MpegPS,
+ WebM,
+ }
+
+ public enum DrawTool {
+ PEN,
+ LINE,
+ DASHED_LINE,
+ CIRCLE,
+ DASHED_CIRCLE,
+ RECTANGLE,
+ DASHED_RECTANGLE,
+ CROSS,
+ DASHED_CROSS,
+ ERASER
+ }
+
+ public enum CaptureSourceType {
+ None,
+ DV,
+ Raw,
+ DShow
+ }
+
+ public enum DeviceType {
+ Video,
+ Audio,
+ DV
+ }
}
diff --git a/LongoMatch/Common/Images.cs b/LongoMatch.Core/Common/Images.cs
similarity index 100%
rename from LongoMatch/Common/Images.cs
rename to LongoMatch.Core/Common/Images.cs
diff --git a/LongoMatch/Services/JobsManager/Job.cs b/LongoMatch.Core/Common/Job.cs
similarity index 93%
rename from LongoMatch/Services/JobsManager/Job.cs
rename to LongoMatch.Core/Common/Job.cs
index a6d2cf5..51e80c5 100644
--- a/LongoMatch/Services/JobsManager/Job.cs
+++ b/LongoMatch.Core/Common/Job.cs
@@ -16,14 +16,10 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
-using Gdk;
-using Stetic;
using LongoMatch.Common;
-using LongoMatch.Playlist;
-using LongoMatch.Video.Common;
-namespace LongoMatch.Services.JobsManager
+namespace LongoMatch.Common
{
[Serializable]
public class Job
diff --git a/LongoMatch/Common/Log.cs b/LongoMatch.Core/Common/Log.cs
similarity index 100%
rename from LongoMatch/Common/Log.cs
rename to LongoMatch.Core/Common/Log.cs
diff --git a/LongoMatch/Playlist/PlayList.cs b/LongoMatch.Core/Common/PlayList.cs
similarity index 84%
rename from LongoMatch/Playlist/PlayList.cs
rename to LongoMatch.Core/Common/PlayList.cs
index 583ec95..d4f100f 100644
--- a/LongoMatch/Playlist/PlayList.cs
+++ b/LongoMatch.Core/Common/PlayList.cs
@@ -20,15 +20,12 @@
using System;
using System.Collections.Generic;
-using System.Collections;
-using System.IO;
-using System.Runtime.Serialization.Formatters.Binary;
-using System.Xml.Serialization;
using Gtk;
using LongoMatch.Store;
using LongoMatch.Common;
-using Mono.Unix;
-namespace LongoMatch.Playlist
+using LongoMatch.Interfaces;
+
+namespace LongoMatch.Common
{
@@ -97,6 +94,25 @@ namespace LongoMatch.Playlist
indexSelection--;
return this[indexSelection];
}
+
+ public void Reorder (int indexIn, int indexOut) {
+ var play = this[indexIn];
+ RemoveAt(indexIn);
+ Insert(indexOut, play);
+
+ /* adjust selection index */
+ if (indexIn == indexSelection)
+ indexSelection = indexOut;
+ if (indexIn < indexOut) {
+ if (indexSelection < indexIn || indexSelection > indexOut)
+ return;
+ indexSelection++;
+ } else {
+ if (indexSelection > indexIn || indexSelection < indexOut)
+ return;
+ indexSelection--;
+ }
+ }
public new bool Remove(PlayListPlay plNode) {
bool ret = base.Remove(plNode);
diff --git a/LongoMatch/Common/SerializableObject.cs b/LongoMatch.Core/Common/SerializableObject.cs
similarity index 100%
rename from LongoMatch/Common/SerializableObject.cs
rename to LongoMatch.Core/Common/SerializableObject.cs
diff --git a/CesarPlayer/Common/VideoStandards.cs b/LongoMatch.Core/Common/VideoStandards.cs
similarity index 98%
rename from CesarPlayer/Common/VideoStandards.cs
rename to LongoMatch.Core/Common/VideoStandards.cs
index aa4f2b8..415fd12 100644
--- a/CesarPlayer/Common/VideoStandards.cs
+++ b/LongoMatch.Core/Common/VideoStandards.cs
@@ -18,7 +18,7 @@
using System;
using Mono.Unix;
-namespace LongoMatch.Video.Common
+namespace LongoMatch.Common
{
[Serializable]
public struct VideoStandard
diff --git a/LongoMatch.Core/Config.cs b/LongoMatch.Core/Config.cs
new file mode 100644
index 0000000..262c3ad
--- /dev/null
+++ b/LongoMatch.Core/Config.cs
@@ -0,0 +1,67 @@
+//
+// Copyright (C) 2011 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+using System;
+using System.IO;
+
+namespace LongoMatch
+{
+ public class Config
+ {
+ public static string baseDirectory;
+ public static string homeDirectory;
+ public static string configDirectory;
+
+ public static string HomeDir() {
+ return homeDirectory;
+ }
+
+ public static string PlayListDir() {
+ return Path.Combine(homeDirectory, "playlists");
+ }
+
+ public static string SnapshotsDir() {
+ return Path.Combine(homeDirectory, "snapshots");
+ }
+
+ public static string TemplatesDir() {
+ return Path.Combine(configDirectory, "templates");
+ }
+
+ public static string VideosDir() {
+ return Path.Combine(homeDirectory, "videos");
+ }
+
+ public static string TempVideosDir() {
+ return Path.Combine(configDirectory, "temp");
+ }
+
+ public static string ImagesDir() {
+ return RelativeToPrefix("share/longomatch/images");
+ }
+
+ public static string DBDir() {
+ return Path.Combine(configDirectory, "db");
+ }
+
+ public static string RelativeToPrefix(string relativePath) {
+ return Path.Combine(baseDirectory, relativePath);
+ }
+
+ }
+}
+
diff --git a/LongoMatch/Handlers/Handlers.cs b/LongoMatch.Core/Handlers/Handlers.cs
similarity index 51%
rename from LongoMatch/Handlers/Handlers.cs
rename to LongoMatch.Core/Handlers/Handlers.cs
index 5e6e3e6..543f4a3 100644
--- a/LongoMatch/Handlers/Handlers.cs
+++ b/LongoMatch.Core/Handlers/Handlers.cs
@@ -20,80 +20,102 @@
using System;
using System.Collections.Generic;
-using LongoMatch;
-using LongoMatch.DB;
using LongoMatch.Interfaces;
using LongoMatch.Store;
using LongoMatch.Common;
-using LongoMatch.Services.JobsManager;
namespace LongoMatch.Handlers
{
/*Tagging Events*/
- //A Play was selected
- public delegate void TimeNodeSelectedHandler(Play play);
- //A new play needs to be create for a specific category at the current play time
- public delegate void NewMarkEventHandler(Category category);
- //The start time of a new play has been signaled
- public delegate void NewMarkStartHandler();
- //The stop of a nes play has been signaled
- public delegate void NewMarkStopHandler(Category category);
- //Several plays needs to be created for a several categories
- public delegate void NewMarksEventHandler(List<int> sections);
- //A need play needs to be created at precise frame
- public delegate void NewMarkAtFrameEventHandler(Category category,int frame);
+ /* A Play was selected */
+ public delegate void PlaySelectedHandler(Play play);
+ /* A new play needs to be create for a specific category at the current play time */
+ public delegate void NewTagHandler(Category category);
+ /* Signal the start time to tag a new play */
+ public delegate void NewTagStartHandler();
+ /* Signal the stop time to tag a new play */
+ public delegate void NewTagStopHandler(Category category);
+ /* A new play needs to be created at a defined frame */
+ public delegate void NewTagAtFrameHandler(Category category,int frame);
//A play was edited
public delegate void TimeNodeChangedHandler(TimeNode tNode, object val);
- //A list of plays was deleted
- public delegate void TimeNodeDeletedHandler(List<Play> plays);
- //Players needs to be tagged
- public delegate void PlayersTaggedHandler(Play play, Team team);
- //Tag a play
+ /* A list of plays needs to be deleted */
+ public delegate void PlaysDeletedHandler(List<Play> plays);
+ /* Tag a play */
public delegate void TagPlayHandler(Play play);
+
+ /* Project Events */
+ public delegate void SaveProjectHandler(Project project, ProjectType projectType);
+ public delegate void OpenProjectHandler();
+ public delegate void NewProjectHandler();
+ public delegate void ImportProjectHandler();
+ public delegate void ExportProjectHandler();
+
+ /* GUI */
+ public delegate void ManageJobsHandler();
+ public delegate void ManageTeamsHandler();
+ public delegate void ManageCategoriesHandler();
+ public delegate void ManageProjects();
+
/*Playlist Events*/
- //Add the a play to the opened playlist
+ /* Add the a play to the opened playlist */
public delegate void PlayListNodeAddedHandler(Play play);
- //A play list element is selected
- public delegate void PlayListNodeSelectedHandler(PlayListPlay play, bool hasNext);
- //Save current playrate to a play list element
+ /* A play list element is selected */
+ public delegate void PlayListNodeSelectedHandler(PlayListPlay play);
+ /* Save current playrate for a play list element */
public delegate void ApplyCurrentRateHandler(PlayListPlay play);
+ /* Open a playlist */
+ public delegate void OpenPlaylistHandler();
+ /* New a playlist */
+ public delegate void NewPlaylistHandler();
+ /* Save a playlist */
+ public delegate void SavePlaylistHandler();
+ /* Render a playlist */
+ public delegate void RenderPlaylistHandler();
- //Drawing events
- //Draw tool changed
- public delegate void DrawToolChangedHandler(LongoMatch.Gui.Component.DrawTool drawTool);
- //Paint color changed
+ /* Drawing events */
+ /* Draw tool changed */
+ public delegate void DrawToolChangedHandler(DrawTool drawTool);
+ /* Paint color changed */
public delegate void ColorChangedHandler(Gdk.Color color);
- //Paint line width changed
+ /* Paint line width changed */
public delegate void LineWidthChangedHandler(int width);
- //Toggle widget visibility
+ /* Toggle widget visibility */
public delegate void VisibilityChangedHandler(bool visible);
- //Clear drawings
+ /* Clear drawings */
public delegate void ClearDrawingHandler();
- //Transparency value changed
+ /* Transparency value changed */
public delegate void TransparencyChangedHandler(double transparency);
-
-
- //The position of the stream has changed
+
+ /* The position of the stream has changed */
public delegate void PositionChangedHandler(Time pos);
- //A date was selected
- public delegate void DateSelectedHandler(DateTime selectedDate);
- //Create snapshots for a play
+
+ /* Create snapshots for a play */
public delegate void SnapshotSeriesHandler(Play tNode);
- //A new version of the software exists
+
+ /* Add a new rendering job */
+ public delegate void NewJobHandler(Job job);
+
+ /* A date was selected */
+ public delegate void DateSelectedHandler(DateTime selectedDate);
+
+ /* A new version of the software exists */
public delegate void NewVersionHandler(Version version, string URL);
-
+ /* Edit Category */
public delegate void CategoryHandler(Category category);
public delegate void CategoriesHandler(List<Category> categoriesList);
+
+ /* Edit Subcategory properties */
public delegate void SubCategoryHandler(ISubCategory subcat);
public delegate void SubCategoriesHandler(List<ISubCategory> subcat);
+ /* Edit player properties */
public delegate void PlayerPropertiesHandler(Player player);
public delegate void PlayersPropertiesHandler(List<Player> players);
+ /* A list of projects have been selected */
public delegate void ProjectsSelectedHandler(List<ProjectDescription> projects);
-
- public delegate void JobHandler(Job job);
}
diff --git a/LongoMatch/Interfaces/ISubCategory.cs b/LongoMatch.Core/Interfaces/IDatabase.cs
similarity index 73%
copy from LongoMatch/Interfaces/ISubCategory.cs
copy to LongoMatch.Core/Interfaces/IDatabase.cs
index b78486e..2f91133 100644
--- a/LongoMatch/Interfaces/ISubCategory.cs
+++ b/LongoMatch.Core/Interfaces/IDatabase.cs
@@ -16,18 +16,24 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
+using System.Collections.Generic;
+using LongoMatch.Store;
+
namespace LongoMatch.Interfaces
{
- public interface ISubCategory
+ public interface IDatabase
{
- string Name {get; set;}
+ List<ProjectDescription> GetAllProjects();
+
+ Project GetProject(Guid id);
- bool AllowMultiple {get; set;}
+ void AddProject(Project project);
- bool FastTag {get; set;}
+ void RemoveProject(Guid id);
- string ToMarkupString();
+ void UpdateProject(Project project);
+ bool Exists(Project project);
}
}
diff --git a/LongoMatch/Playlist/IPlayList.cs b/LongoMatch.Core/Interfaces/IPlayList.cs
similarity index 92%
rename from LongoMatch/Playlist/IPlayList.cs
rename to LongoMatch.Core/Interfaces/IPlayList.cs
index f787cd7..63a9ed5 100644
--- a/LongoMatch/Playlist/IPlayList.cs
+++ b/LongoMatch.Core/Interfaces/IPlayList.cs
@@ -23,14 +23,16 @@ using System.Collections;
using Gtk;
using LongoMatch.Store;
-namespace LongoMatch.Playlist {
+namespace LongoMatch.Interfaces {
public interface IPlayList:IEnumerable
{
int Count {
get;
}
-
+
+ void Save();
+
void Save(string path);
void Add(PlayListPlay play);
@@ -43,6 +45,8 @@ namespace LongoMatch.Playlist {
PlayListPlay Select(int index);
+ void Reorder(int indexIn, int indexOut);
+
int GetCurrentIndex();
bool HasNext();
diff --git a/LongoMatch/Interfaces/ISubCategory.cs b/LongoMatch.Core/Interfaces/IPlaylistWidget.cs
similarity index 79%
copy from LongoMatch/Interfaces/ISubCategory.cs
copy to LongoMatch.Core/Interfaces/IPlaylistWidget.cs
index b78486e..5a4051e 100644
--- a/LongoMatch/Interfaces/ISubCategory.cs
+++ b/LongoMatch.Core/Interfaces/IPlaylistWidget.cs
@@ -16,18 +16,17 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
+
+using LongoMatch.Interfaces;
+using LongoMatch.Store;
+
namespace LongoMatch.Interfaces
{
- public interface ISubCategory
+ public interface IPlaylistWidget
{
- string Name {get; set;}
-
- bool AllowMultiple {get; set;}
-
- bool FastTag {get; set;}
-
- string ToMarkupString();
-
+ void Load(IPlayList playlist);
+ void Add(PlayListPlay playlistPlay);
+ void SetActivePlay (PlayListPlay playlistplay, int index);
}
}
diff --git a/LongoMatch/Interfaces/ISubCategory.cs b/LongoMatch.Core/Interfaces/IRenderingJobsManager.cs
similarity index 69%
copy from LongoMatch/Interfaces/ISubCategory.cs
copy to LongoMatch.Core/Interfaces/IRenderingJobsManager.cs
index b78486e..a365cbc 100644
--- a/LongoMatch/Interfaces/ISubCategory.cs
+++ b/LongoMatch.Core/Interfaces/IRenderingJobsManager.cs
@@ -16,18 +16,23 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
+using System.Collections.Generic;
+using Gtk;
+using LongoMatch.Common;
+
namespace LongoMatch.Interfaces
{
- public interface ISubCategory
+ public interface IRenderingJobsManager
{
- string Name {get; set;}
-
- bool AllowMultiple {get; set;}
-
- bool FastTag {get; set;}
-
- string ToMarkupString();
-
+ void RetryJobs(List<Job> retryJobs);
+ void DeleteJob(Job job);
+ void ClearDoneJobs();
+ void CancelJobs(List<Job> cancelJobs);
+ void CancelCurrentJob ();
+ void CancelJob(Job job);
+ void CancelAllJobs();
+ void AddJob(Job job);
+ TreeStore Model {get;}
}
}
diff --git a/LongoMatch/Interfaces/ISubCategory.cs b/LongoMatch.Core/Interfaces/ISubCategory.cs
similarity index 100%
copy from LongoMatch/Interfaces/ISubCategory.cs
copy to LongoMatch.Core/Interfaces/ISubCategory.cs
diff --git a/LongoMatch/Interfaces/ITag.cs b/LongoMatch.Core/Interfaces/ITag.cs
similarity index 100%
rename from LongoMatch/Interfaces/ITag.cs
rename to LongoMatch.Core/Interfaces/ITag.cs
diff --git a/LongoMatch/Interfaces/ITemplates.cs b/LongoMatch.Core/Interfaces/ITemplates.cs
similarity index 100%
rename from LongoMatch/Interfaces/ITemplates.cs
rename to LongoMatch.Core/Interfaces/ITemplates.cs
diff --git a/LongoMatch/Interfaces/ISubCategory.cs b/LongoMatch.Core/Interfaces/ITemplatesService.cs
similarity index 58%
rename from LongoMatch/Interfaces/ISubCategory.cs
rename to LongoMatch.Core/Interfaces/ITemplatesService.cs
index b78486e..aa1d61a 100644
--- a/LongoMatch/Interfaces/ISubCategory.cs
+++ b/LongoMatch.Core/Interfaces/ITemplatesService.cs
@@ -16,18 +16,27 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
+using System.Collections.Generic;
+using LongoMatch.Store;
+using LongoMatch.Store.Templates;
+
namespace LongoMatch.Interfaces
{
- public interface ISubCategory
+ public interface ITemplatesService
{
- string Name {get; set;}
+ ITemplateProvider<T, U> GetTemplateProvider<T, U>() where T: ITemplate<U>;
+
+ ITemplateWidget<T, U> GetTemplateEditor<T, U>() where T: ITemplate<U>;
- bool AllowMultiple {get; set;}
+ ITemplateProvider<SubCategoryTemplate, string> SubCategoriesTemplateProvider {get;}
- bool FastTag {get; set;}
+ ITemplateProvider<TeamTemplate, Player> TeamTemplateProvider {get;}
+
+ ITemplateProvider<Categories, Category> CategoriesTemplateProvider {get;}
- string ToMarkupString();
+ List<PlayerSubCategory> PlayerSubcategories {get;}
+ List<TeamSubCategory> TeamSubcategories {get;}
}
}
diff --git a/LongoMatch.Core/LongoMatch.Core.mdp b/LongoMatch.Core/LongoMatch.Core.mdp
new file mode 100644
index 0000000..8925628
--- /dev/null
+++ b/LongoMatch.Core/LongoMatch.Core.mdp
@@ -0,0 +1,84 @@
+<Project name="LongoMatch.Core" fileversion="2.0" DefaultNamespace="LongoMatch.Core" language="C#" targetFramework="3.5" ctype="DotNetProject">
+ <Configurations active="Release">
+ <Configuration name="Debug" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Core" />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" definesymbols="DEBUG" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ <Configuration name="Release" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Core" />
+ <Build debugmode="False" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ </Configurations>
+ <Contents>
+ <File subtype="Code" buildaction="Compile" name="Common/Cairo.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Cloner.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/ConsoleCrayon.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Constants.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Enums.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Images.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Log.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/SerializableObject.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Category.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Drawing.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/HotKey.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/PixbufTimeNode.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Play.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Player.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/PlayListPlay.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Project.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/ProjectDescription.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/SubCategory.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Tag.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/TagStore.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Time.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/TimeNode.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Templates/CategoriesTemplate.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Templates/SubCategoryTemplate.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Templates/TeamTemplate.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Templates/Template.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/ISubCategory.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/ITag.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/ITemplates.cs" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Code" buildaction="Compile" name="Store/MediaFile.cs" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="Handlers" />
+ <File subtype="Code" buildaction="Compile" name="Handlers/Handlers.cs" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Code" buildaction="Compile" name="Common/Job.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/EncodingProfiles.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/EncodingSettings.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/VideoStandards.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IPlayList.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/PlayList.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/CaptureSettings.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Device.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IRenderingJobsManager.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Interfaces" />
+ <File subtype="Directory" buildaction="Compile" name="Interfaces" />
+ <File subtype="Directory" buildaction="Compile" name="Interfaces" />
+ <File subtype="Directory" buildaction="Compile" name="Interfaces" />
+ <File subtype="Code" buildaction="Compile" name="Config.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/ITemplatesService.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IDatabase.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IPlaylistWidget.cs" />
+ </Contents>
+ <References>
+ <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Gac" localcopy="True" refto="System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Gac" localcopy="True" refto="Db4objects.Db4o, Version=7.4.121.14026, Culture=neutral, PublicKeyToken=6199cd4f203aa8eb" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Cairo, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ </References>
+</Project>
\ No newline at end of file
diff --git a/LongoMatch.Core/Makefile.am b/LongoMatch.Core/Makefile.am
new file mode 100644
index 0000000..a661dc6
--- /dev/null
+++ b/LongoMatch.Core/Makefile.am
@@ -0,0 +1,54 @@
+ASSEMBLY = LongoMatch.Core
+TARGET = library
+
+LINK = $(REF_DEP_LONGOMATCH_CORE)
+
+SOURCES = \
+ Common/Cairo.cs \
+ Common/CaptureSettings.cs \
+ Common/Cloner.cs \
+ Common/ConsoleCrayon.cs \
+ Common/Constants.cs \
+ Common/Device.cs \
+ Common/EncodingProfiles.cs \
+ Common/EncodingSettings.cs \
+ Common/Enums.cs \
+ Common/Images.cs \
+ Common/Job.cs \
+ Common/Log.cs \
+ Common/PlayList.cs \
+ Common/SerializableObject.cs \
+ Common/VideoStandards.cs \
+ Config.cs \
+ Handlers/Handlers.cs \
+ Interfaces/IDatabase.cs \
+ Interfaces/IPlayList.cs \
+ Interfaces/IPlaylistWidget.cs \
+ Interfaces/IRenderingJobsManager.cs \
+ Interfaces/ISubCategory.cs \
+ Interfaces/ITag.cs \
+ Interfaces/ITemplates.cs \
+ Interfaces/ITemplatesService.cs \
+ Store/Category.cs \
+ Store/Drawing.cs \
+ Store/HotKey.cs \
+ Store/MediaFile.cs \
+ Store/PixbufTimeNode.cs \
+ Store/Play.cs \
+ Store/Player.cs \
+ Store/PlayListPlay.cs \
+ Store/Project.cs \
+ Store/ProjectDescription.cs \
+ Store/SubCategory.cs \
+ Store/Tag.cs \
+ Store/TagStore.cs \
+ Store/Templates/CategoriesTemplate.cs \
+ Store/Templates/SubCategoryTemplate.cs \
+ Store/Templates/TeamTemplate.cs \
+ Store/Templates/Template.cs \
+ Store/Time.cs \
+ Store/TimeNode.cs
+
+RESOURCES =
+
+include $(top_srcdir)/build/build.mk
diff --git a/LongoMatch/Store/Category.cs b/LongoMatch.Core/Store/Category.cs
similarity index 100%
rename from LongoMatch/Store/Category.cs
rename to LongoMatch.Core/Store/Category.cs
diff --git a/LongoMatch/Store/Drawing.cs b/LongoMatch.Core/Store/Drawing.cs
similarity index 100%
rename from LongoMatch/Store/Drawing.cs
rename to LongoMatch.Core/Store/Drawing.cs
diff --git a/LongoMatch/Store/HotKey.cs b/LongoMatch.Core/Store/HotKey.cs
similarity index 99%
rename from LongoMatch/Store/HotKey.cs
rename to LongoMatch.Core/Store/HotKey.cs
index d3ff711..e58870d 100644
--- a/LongoMatch/Store/HotKey.cs
+++ b/LongoMatch.Core/Store/HotKey.cs
@@ -23,7 +23,6 @@
using System;
using System.Collections.Generic;
using System.Runtime.Serialization;
-using Gtk;
using Gdk;
using Mono.Unix;
diff --git a/CesarPlayer/Utils/MediaFile.cs b/LongoMatch.Core/Store/MediaFile.cs
similarity index 66%
rename from CesarPlayer/Utils/MediaFile.cs
rename to LongoMatch.Core/Store/MediaFile.cs
index 1c76a5f..708e8e5 100644
--- a/CesarPlayer/Utils/MediaFile.cs
+++ b/LongoMatch.Core/Store/MediaFile.cs
@@ -21,15 +21,11 @@
using System;
using Mono.Unix;
using Gdk;
-using LongoMatch.Video;
-using LongoMatch.Video.Player;
-using LongoMatch.Video.Common;
-namespace LongoMatch.Video.Utils
+namespace LongoMatch.Store
{
[Serializable]
-
public class MediaFile
{
@@ -42,6 +38,7 @@ namespace LongoMatch.Video.Utils
string audioCodec;
uint videoHeight;
uint videoWidth;
+ byte[] thumbnailBuf;
public MediaFile() {}
@@ -54,7 +51,8 @@ namespace LongoMatch.Video.Utils
string videoCodec,
string audioCodec,
uint videoWidth,
- uint videoHeight)
+ uint videoHeight,
+ Pixbuf preview)
{
this.filePath = filePath;
this.length = length;
@@ -69,7 +67,7 @@ namespace LongoMatch.Video.Utils
this.fps=25;
else
this.fps = fps;
-
+ this.Preview = preview;
}
public string FilePath {
@@ -156,50 +154,24 @@ namespace LongoMatch.Video.Utils
this.fps = value;
}
}
-
- public uint GetFrames() {
- return (uint)(Fps*Length/1000);
- }
-
-
-
- public static MediaFile GetMediaFile(string filePath) {
- int duration, fps=0, height=0, width=0;
- bool hasVideo, hasAudio;
- string audioCodec = "", videoCodec = "";
- MultimediaFactory factory;
- IMetadataReader reader = null;
-
- try {
- factory = new MultimediaFactory();
- reader = factory.getMetadataReader();
- reader.Open(filePath);
- duration = (int)reader.GetMetadata(MetadataType.Duration);
- hasVideo = (bool) reader.GetMetadata(MetadataType.HasVideo);
- hasAudio = (bool) reader.GetMetadata(MetadataType.HasAudio);
- if(hasAudio)
- audioCodec = (string) reader.GetMetadata(MetadataType.AudioEncoderType);
- if(hasVideo) {
- videoCodec = (string) reader.GetMetadata(MetadataType.VideoEncoderType);
- fps = (int) reader.GetMetadata(MetadataType.Fps);
- }
- height = (int) reader.GetMetadata(MetadataType.DimensionX);
- width = (int) reader.GetMetadata(MetadataType.DimensionY);
-
- return new MediaFile(filePath,duration*1000,(ushort)fps,
- hasAudio,hasVideo,videoCodec,audioCodec,
- (uint)height,(uint)width);
-
- }
- catch(GLib.GException ex) {
- throw new Exception(Catalog.GetString("Invalid video file:")+"\n"+ex.Message);
+
+ public Pixbuf Preview {
+ get {
+ if(thumbnailBuf != null)
+ return new Pixbuf(thumbnailBuf);
+ return null;
}
- finally {
- reader.Close();
- reader.Dispose();
+ set {
+ if(value != null) {
+ thumbnailBuf = value.SaveToBuffer("png");
+ value.Dispose();
+ } else
+ thumbnailBuf = null;
}
}
-
-
+
+ public uint GetFrames() {
+ return (uint)(Fps*Length/1000);
+ }
}
}
diff --git a/LongoMatch/Store/PixbufTimeNode.cs b/LongoMatch.Core/Store/PixbufTimeNode.cs
similarity index 100%
rename from LongoMatch/Store/PixbufTimeNode.cs
rename to LongoMatch.Core/Store/PixbufTimeNode.cs
diff --git a/LongoMatch/Store/Play.cs b/LongoMatch.Core/Store/Play.cs
similarity index 100%
rename from LongoMatch/Store/Play.cs
rename to LongoMatch.Core/Store/Play.cs
diff --git a/LongoMatch/Store/PlayListPlay.cs b/LongoMatch.Core/Store/PlayListPlay.cs
similarity index 88%
rename from LongoMatch/Store/PlayListPlay.cs
rename to LongoMatch.Core/Store/PlayListPlay.cs
index 480116e..affb607 100644
--- a/LongoMatch/Store/PlayListPlay.cs
+++ b/LongoMatch.Core/Store/PlayListPlay.cs
@@ -21,7 +21,6 @@
using System;
using System.Collections.Generic;
using Gdk;
-using LongoMatch.Video.Utils;
namespace LongoMatch.Store
{
@@ -38,7 +37,7 @@ namespace LongoMatch.Store
Valid = true;
}
- public PlayListPlay(Play play, PreviewMediaFile mediaFile, float rate, bool valid)
+ public PlayListPlay(Play play, MediaFile mediaFile, float rate, bool valid)
{
Name = play.Name;
Start = play.Start;
@@ -55,15 +54,7 @@ namespace LongoMatch.Store
/// <summary>
/// Media File
/// </summary>
- public PreviewMediaFile MediaFile {
- get;
- set;
- }
-
- /// <summary>
- /// Play rate
- /// </summary>
- public float Rate {
+ public MediaFile MediaFile {
get;
set;
}
diff --git a/LongoMatch/Store/Player.cs b/LongoMatch.Core/Store/Player.cs
similarity index 100%
rename from LongoMatch/Store/Player.cs
rename to LongoMatch.Core/Store/Player.cs
diff --git a/LongoMatch/Store/Project.cs b/LongoMatch.Core/Store/Project.cs
similarity index 100%
rename from LongoMatch/Store/Project.cs
rename to LongoMatch.Core/Store/Project.cs
diff --git a/LongoMatch/Store/ProjectDescription.cs b/LongoMatch.Core/Store/ProjectDescription.cs
similarity index 97%
rename from LongoMatch/Store/ProjectDescription.cs
rename to LongoMatch.Core/Store/ProjectDescription.cs
index 144aa86..216a7af 100644
--- a/LongoMatch/Store/ProjectDescription.cs
+++ b/LongoMatch.Core/Store/ProjectDescription.cs
@@ -18,7 +18,6 @@
using System;
using LongoMatch.Store;
-using LongoMatch.Video.Utils;
namespace LongoMatch.Store
{
@@ -49,7 +48,7 @@ namespace LongoMatch.Store
/// <summary>
/// Media file asigned to this project
/// </summary>
- public PreviewMediaFile File {
+ public MediaFile File {
get;
set;
}
diff --git a/LongoMatch/Store/SubCategory.cs b/LongoMatch.Core/Store/SubCategory.cs
similarity index 100%
rename from LongoMatch/Store/SubCategory.cs
rename to LongoMatch.Core/Store/SubCategory.cs
diff --git a/LongoMatch/Store/Tag.cs b/LongoMatch.Core/Store/Tag.cs
similarity index 100%
rename from LongoMatch/Store/Tag.cs
rename to LongoMatch.Core/Store/Tag.cs
diff --git a/LongoMatch/Store/TagStore.cs b/LongoMatch.Core/Store/TagStore.cs
similarity index 100%
rename from LongoMatch/Store/TagStore.cs
rename to LongoMatch.Core/Store/TagStore.cs
diff --git a/LongoMatch/Store/Templates/CategoriesTemplate.cs b/LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
similarity index 100%
rename from LongoMatch/Store/Templates/CategoriesTemplate.cs
rename to LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
diff --git a/LongoMatch/Store/Templates/SubCategoryTemplate.cs b/LongoMatch.Core/Store/Templates/SubCategoryTemplate.cs
similarity index 100%
rename from LongoMatch/Store/Templates/SubCategoryTemplate.cs
rename to LongoMatch.Core/Store/Templates/SubCategoryTemplate.cs
diff --git a/LongoMatch/Store/Templates/TeamTemplate.cs b/LongoMatch.Core/Store/Templates/TeamTemplate.cs
similarity index 100%
rename from LongoMatch/Store/Templates/TeamTemplate.cs
rename to LongoMatch.Core/Store/Templates/TeamTemplate.cs
diff --git a/LongoMatch/Store/Templates/Template.cs b/LongoMatch.Core/Store/Templates/Template.cs
similarity index 100%
rename from LongoMatch/Store/Templates/Template.cs
rename to LongoMatch.Core/Store/Templates/Template.cs
diff --git a/LongoMatch/Store/Time.cs b/LongoMatch.Core/Store/Time.cs
similarity index 100%
rename from LongoMatch/Store/Time.cs
rename to LongoMatch.Core/Store/Time.cs
diff --git a/LongoMatch/Store/TimeNode.cs b/LongoMatch.Core/Store/TimeNode.cs
similarity index 93%
rename from LongoMatch/Store/TimeNode.cs
rename to LongoMatch.Core/Store/TimeNode.cs
index c1f7b5a..8a1eb19 100644
--- a/LongoMatch/Store/TimeNode.cs
+++ b/LongoMatch.Core/Store/TimeNode.cs
@@ -34,6 +34,7 @@ namespace LongoMatch.Store
{
#region Constructors
public TimeNode() {
+ Rate = 1;
}
#endregion
@@ -70,6 +71,15 @@ namespace LongoMatch.Store
return Stop-Start;
}
}
+
+ /// <summary>
+ /// Play rate
+ /// </summary>
+ public float Rate {
+ get;
+ set;
+ }
+
#endregion
}
diff --git a/CesarPlayer/AssemblyInfo.cs.in b/LongoMatch.GUI.Multimedia/AssemblyInfo.cs
similarity index 97%
copy from CesarPlayer/AssemblyInfo.cs.in
copy to LongoMatch.GUI.Multimedia/AssemblyInfo.cs
index 704b4fd..1c1a88f 100644
--- a/CesarPlayer/AssemblyInfo.cs.in
+++ b/LongoMatch.GUI.Multimedia/AssemblyInfo.cs
@@ -41,7 +41,7 @@ using System.Runtime.CompilerServices;
// You can specify all values by your own or you can build default build and revision
// numbers with the '*' character (the default):
-[assembly: AssemblyVersion("@PACKAGE_VERSION@")]
+[assembly: AssemblyVersion("0.17.2")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
diff --git a/CesarPlayer/AssemblyInfo.cs.in b/LongoMatch.GUI.Multimedia/AssemblyInfo.cs.in
similarity index 100%
rename from CesarPlayer/AssemblyInfo.cs.in
rename to LongoMatch.GUI.Multimedia/AssemblyInfo.cs.in
diff --git a/CesarPlayer/CesarPlayer.csproj b/LongoMatch.GUI.Multimedia/CesarPlayer.csproj
similarity index 100%
rename from CesarPlayer/CesarPlayer.csproj
rename to LongoMatch.GUI.Multimedia/CesarPlayer.csproj
diff --git a/CesarPlayer/CesarPlayer.dll.config.in b/LongoMatch.GUI.Multimedia/CesarPlayer.dll.config.in
similarity index 100%
rename from CesarPlayer/CesarPlayer.dll.config.in
rename to LongoMatch.GUI.Multimedia/CesarPlayer.dll.config.in
diff --git a/CesarPlayer/Gui/CapturerBin.cs b/LongoMatch.GUI.Multimedia/Gui/CapturerBin.cs
similarity index 99%
rename from CesarPlayer/Gui/CapturerBin.cs
rename to LongoMatch.GUI.Multimedia/Gui/CapturerBin.cs
index bb5c8dd..20a3c8c 100644
--- a/CesarPlayer/Gui/CapturerBin.cs
+++ b/LongoMatch.GUI.Multimedia/Gui/CapturerBin.cs
@@ -21,7 +21,8 @@
using System;
using Gtk;
using Gdk;
-using GLib;
+using LongoMatch.Common;
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video;
using LongoMatch.Video.Common;
using LongoMatch.Video.Capturer;
diff --git a/CesarPlayer/Gui/PlayerBin.cs b/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
similarity index 99%
rename from CesarPlayer/Gui/PlayerBin.cs
rename to LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
index 242c7d7..7f98fbe 100644
--- a/CesarPlayer/Gui/PlayerBin.cs
+++ b/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
@@ -22,6 +22,7 @@ using Gtk;
using Gdk;
using Mono.Unix;
using System.Runtime.InteropServices;
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video;
using LongoMatch.Video.Common;
using LongoMatch.Video.Player;
diff --git a/CesarPlayer/Gui/VolumeWindow.cs b/LongoMatch.GUI.Multimedia/Gui/VolumeWindow.cs
similarity index 100%
rename from CesarPlayer/Gui/VolumeWindow.cs
rename to LongoMatch.GUI.Multimedia/Gui/VolumeWindow.cs
diff --git a/LongoMatch.GUI.Multimedia/LongoMatch.GUI.Multimedia.mdp b/LongoMatch.GUI.Multimedia/LongoMatch.GUI.Multimedia.mdp
new file mode 100644
index 0000000..1178417
--- /dev/null
+++ b/LongoMatch.GUI.Multimedia/LongoMatch.GUI.Multimedia.mdp
@@ -0,0 +1,53 @@
+<Project name="LongoMatch.GUI.Multimedia" fileversion="2.0" DefaultNamespace="longomatch" language="C#" clr-version="Net_2_0" targetFramework="3.5" ctype="DotNetProject">
+ <Deployment.LinuxDeployData generatePcFile="False" />
+ <MonoDevelop.Autotools.MakefileInfo RelativeMakefileName="Makefile.am" RelativeConfigureInPath="../">
+ <BuildFilesVar Name="FILES" />
+ <DeployFilesVar />
+ <ResourcesVar Name="RESOURCES" />
+ <OthersVar />
+ <GacRefVar Name="REFERENCES" />
+ <AsmRefVar Name="REFERENCES" />
+ <ProjectRefVar Name="REFERENCES" />
+ </MonoDevelop.Autotools.MakefileInfo>
+ <Configurations active="Release">
+ <Configuration name="Debug" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="a" assemblyKeyFile="/home/andoni/Proyectos/longomatch/CesarPlayer/." />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="True" unsafecodeallowed="True" generateoverflowchecks="True" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ <Configuration name="Release" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="CesarPlayer.dll" assemblyKeyFile="/home/andoni/Proyectos/longomatch/CesarPlayer/." />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="True" unsafecodeallowed="True" generateoverflowchecks="True" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ </Configurations>
+ <Contents>
+ <File subtype="Code" buildaction="EmbedAsResource" name="gtk-gui/objects.xml" />
+ <File subtype="Code" buildaction="EmbedAsResource" name="gtk-gui/gui.stetic" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/generated.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Gui" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.PlayerBin.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.VolumeWindow.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/VolumeWindow.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/CapturerBin.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/PlayerBin.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.CapturerBin.cs" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ </Contents>
+ <References>
+ <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Gac" localcopy="True" refto="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+ <ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="glib-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Multimedia" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Core" />
+ </References>
+ <LanguageParameters ApplicationIcon="." CodePage="65001" ctype="CSharpProjectParameters" />
+</Project>
\ No newline at end of file
diff --git a/LongoMatch.GUI.Multimedia/LongoMatch.Gui.Multimedia.dll.config b/LongoMatch.GUI.Multimedia/LongoMatch.Gui.Multimedia.dll.config
new file mode 100644
index 0000000..72f9cb1
--- /dev/null
+++ b/LongoMatch.GUI.Multimedia/LongoMatch.Gui.Multimedia.dll.config
@@ -0,0 +1,3 @@
+<configuration>
+ <dllmap dll="libcesarplayer.dll" target="/usr/local/lib/longomatch/libcesarplayer.so.0"/>
+</configuration>
diff --git a/LongoMatch.GUI.Multimedia/Makefile.am b/LongoMatch.GUI.Multimedia/Makefile.am
new file mode 100644
index 0000000..c5ed3a7
--- /dev/null
+++ b/LongoMatch.GUI.Multimedia/Makefile.am
@@ -0,0 +1,23 @@
+ASSEMBLY = LongoMatch.GUI.Multimedia
+TARGET = library
+
+LINK = $(REF_DEP_LONGOMATCH_GUI_MULTIMEDIA)
+
+SOURCES = \
+ gtk-gui/generated.cs \
+ gtk-gui/LongoMatch.Gui.CapturerBin.cs \
+ gtk-gui/LongoMatch.Gui.PlayerBin.cs \
+ gtk-gui/LongoMatch.Gui.VolumeWindow.cs \
+ Gui/CapturerBin.cs \
+ Gui/PlayerBin.cs \
+ Gui/VolumeWindow.cs
+
+RESOURCES = \
+ gtk-gui/objects.xml \
+ gtk-gui/gui.stetic
+
+DLLCONFIG = LongoMatch.Gui.Multimedia.dll.config
+
+include $(top_srcdir)/build/build.mk
+
+EXTRA_DIST += LongoMatch.Gui.Multimedia.dll.config
diff --git a/LongoMatch.GUI.Multimedia/a.dll b/LongoMatch.GUI.Multimedia/a.dll
new file mode 100755
index 0000000..1ad1367
Binary files /dev/null and b/LongoMatch.GUI.Multimedia/a.dll differ
diff --git a/LongoMatch.GUI.Multimedia/a.dll.mdb b/LongoMatch.GUI.Multimedia/a.dll.mdb
new file mode 100644
index 0000000..66e58d9
Binary files /dev/null and b/LongoMatch.GUI.Multimedia/a.dll.mdb differ
diff --git a/CesarPlayer/cesarplayer.key b/LongoMatch.GUI.Multimedia/cesarplayer.key
similarity index 100%
rename from CesarPlayer/cesarplayer.key
rename to LongoMatch.GUI.Multimedia/cesarplayer.key
diff --git a/CesarPlayer/cesarplayer.pc.in b/LongoMatch.GUI.Multimedia/cesarplayer.pc
similarity index 56%
copy from CesarPlayer/cesarplayer.pc.in
copy to LongoMatch.GUI.Multimedia/cesarplayer.pc
index 918f35c..e4e775c 100644
--- a/CesarPlayer/cesarplayer.pc.in
+++ b/LongoMatch.GUI.Multimedia/cesarplayer.pc
@@ -3,4 +3,4 @@ Description: CesarPlayer
Version: 0.1
Requires:
-Libs: -r:@expanded_libdir@/@PACKAGE@/CesarPlayer.dll
+Libs: -r:/usr/local/lib/longomatch/CesarPlayer.dll
diff --git a/CesarPlayer/cesarplayer.pc.in b/LongoMatch.GUI.Multimedia/cesarplayer.pc.in
similarity index 100%
rename from CesarPlayer/cesarplayer.pc.in
rename to LongoMatch.GUI.Multimedia/cesarplayer.pc.in
diff --git a/CesarPlayer/gtk-gui/LongoMatch.Gui.CapturerBin.cs b/LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.CapturerBin.cs
similarity index 100%
rename from CesarPlayer/gtk-gui/LongoMatch.Gui.CapturerBin.cs
rename to LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.CapturerBin.cs
diff --git a/CesarPlayer/gtk-gui/LongoMatch.Gui.PlayerBin.cs b/LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.PlayerBin.cs
similarity index 100%
rename from CesarPlayer/gtk-gui/LongoMatch.Gui.PlayerBin.cs
rename to LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.PlayerBin.cs
diff --git a/CesarPlayer/gtk-gui/LongoMatch.Gui.VolumeWindow.cs b/LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.VolumeWindow.cs
similarity index 100%
rename from CesarPlayer/gtk-gui/LongoMatch.Gui.VolumeWindow.cs
rename to LongoMatch.GUI.Multimedia/gtk-gui/LongoMatch.Gui.VolumeWindow.cs
diff --git a/CesarPlayer/gtk-gui/generated.cs b/LongoMatch.GUI.Multimedia/gtk-gui/generated.cs
similarity index 100%
rename from CesarPlayer/gtk-gui/generated.cs
rename to LongoMatch.GUI.Multimedia/gtk-gui/generated.cs
diff --git a/CesarPlayer/gtk-gui/gui.stetic b/LongoMatch.GUI.Multimedia/gtk-gui/gui.stetic
similarity index 98%
rename from CesarPlayer/gtk-gui/gui.stetic
rename to LongoMatch.GUI.Multimedia/gtk-gui/gui.stetic
index 1421d4b..59a91c9 100644
--- a/CesarPlayer/gtk-gui/gui.stetic
+++ b/LongoMatch.GUI.Multimedia/gtk-gui/gui.stetic
@@ -5,7 +5,9 @@
<target-gtk-version>2.12</target-gtk-version>
</configuration>
<import>
- <widget-library name="../bin/Release/CesarPlayer.dll" internal="true" />
+ <widget-library name="../../LongoMatch.Multimedia/bin/Debug/LongoMatch.Multimedia.dll" />
+ <widget-library name="../../bin/LongoMatch.Core.dll" />
+ <widget-library name="../../bin/a.dll" internal="true" />
</import>
<widget class="Gtk.Window" id="LongoMatch.Gui.VolumeWindow" design-size="31 204">
<property name="MemberName" />
diff --git a/CesarPlayer/gtk-gui/objects.xml b/LongoMatch.GUI.Multimedia/gtk-gui/objects.xml
similarity index 99%
rename from CesarPlayer/gtk-gui/objects.xml
rename to LongoMatch.GUI.Multimedia/gtk-gui/objects.xml
index 8946adc..ecf433e 100644
--- a/CesarPlayer/gtk-gui/objects.xml
+++ b/LongoMatch.GUI.Multimedia/gtk-gui/objects.xml
@@ -1,13 +1,4 @@
<objects attr-sync="on">
- <object type="LongoMatch.Gui.CapturerBin" palette-category="CesarPlayer" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals>
- <itemgroup label="CapturerBin Signals">
- <signal name="CaptureFinished" />
- <signal name="Error" />
- </itemgroup>
- </signals>
- </object>
<object type="LongoMatch.Gui.PlayerBin" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups>
<itemgroup label="PlayerBin Properties">
@@ -28,4 +19,13 @@
</itemgroup>
</signals>
</object>
+ <object type="LongoMatch.Gui.CapturerBin" palette-category="CesarPlayer" allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals>
+ <itemgroup label="CapturerBin Signals">
+ <signal name="CaptureFinished" />
+ <signal name="Error" />
+ </itemgroup>
+ </signals>
+ </object>
</objects>
\ No newline at end of file
diff --git a/LongoMatch/Gui/Component/ButtonsWidget.cs b/LongoMatch.GUI/Gui/Component/ButtonsWidget.cs
similarity index 96%
rename from LongoMatch/Gui/Component/ButtonsWidget.cs
rename to LongoMatch.GUI/Gui/Component/ButtonsWidget.cs
index d18b169..8414975 100644
--- a/LongoMatch/Gui/Component/ButtonsWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/ButtonsWidget.cs
@@ -38,9 +38,9 @@ namespace LongoMatch.Gui.Component
private TagMode tagMode;
private Dictionary<Widget, Category> buttonsDic;
- public event NewMarkEventHandler NewMarkEvent;
- public event NewMarkStartHandler NewMarkStartEvent;
- public event NewMarkStopHandler NewMarkStopEvent;
+ public event NewTagHandler NewMarkEvent;
+ public event NewTagStartHandler NewMarkStartEvent;
+ public event NewTagStopHandler NewMarkStopEvent;
public ButtonsWidget()
diff --git a/LongoMatch/Gui/Component/CategoriesScale.cs b/LongoMatch.GUI/Gui/Component/CategoriesScale.cs
similarity index 100%
rename from LongoMatch/Gui/Component/CategoriesScale.cs
rename to LongoMatch.GUI/Gui/Component/CategoriesScale.cs
diff --git a/LongoMatch/Gui/Component/CategoriesTemplateEditor.cs b/LongoMatch.GUI/Gui/Component/CategoriesTemplateEditor.cs
similarity index 96%
rename from LongoMatch/Gui/Component/CategoriesTemplateEditor.cs
rename to LongoMatch.GUI/Gui/Component/CategoriesTemplateEditor.cs
index fcfd06d..6589b3c 100644
--- a/LongoMatch/Gui/Component/CategoriesTemplateEditor.cs
+++ b/LongoMatch.GUI/Gui/Component/CategoriesTemplateEditor.cs
@@ -16,19 +16,14 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
-using System;
using System.Collections.Generic;
-using System.IO;
-using Gdk;
using Gtk;
using Mono.Unix;
-using Stetic;
-using LongoMatch.Common;
using LongoMatch.Gui.Dialog;
using LongoMatch.Interfaces;
-using LongoMatch.IO;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
+
namespace LongoMatch.Gui.Component
{
public class CategoriesTemplateEditorWidget: TemplatesEditorWidget<Categories, Category>
@@ -36,7 +31,7 @@ namespace LongoMatch.Gui.Component
private CategoriesTreeView categoriestreeview;
private List<HotKey> hkList;
- public CategoriesTemplateEditorWidget (): base()
+ public CategoriesTemplateEditorWidget (ITemplateProvider<Categories, Category> provider): base(provider)
{
hkList = new List<HotKey>();
categoriestreeview = new CategoriesTreeView();
diff --git a/LongoMatch/Gui/Component/CategoryProperties.cs b/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
similarity index 94%
rename from LongoMatch/Gui/Component/CategoryProperties.cs
rename to LongoMatch.GUI/Gui/Component/CategoryProperties.cs
index 0a40b3d..109e160 100644
--- a/LongoMatch/Gui/Component/CategoryProperties.cs
+++ b/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
@@ -26,7 +26,6 @@ using Mono.Unix;
using LongoMatch.Common;
using LongoMatch.Interfaces;
-using LongoMatch.Services;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
using LongoMatch.Gui.Dialog;
@@ -53,11 +52,20 @@ namespace LongoMatch.Gui.Component
this.Build();
subcategoriestreeview1.SubCategoriesDeleted += OnSubcategoriesDeleted;
subcategoriestreeview1.SubCategorySelected += OnSubcategorySelected;
- subcategoriesTemplates = MainClass.ts.SubCategoriesTemplateProvider;
- LoadSubcategories();
}
- private void LoadSubcategories() {
+ public ITemplateProvider<SubCategoryTemplate, string> Template {
+ set {
+ subcategoriesTemplates = value;
+ }
+ }
+ public List<PlayerSubCategory> PlayerSubcategories{
+ set{
+ LoadSubcategories(value);
+ }
+ }
+
+ private void LoadSubcategories(List<PlayerSubCategory> playerSubcategories) {
model = new ListStore(typeof(string), typeof(ISubCategory));
model.AppendValues(Catalog.GetString("Create new..."), "");
@@ -68,7 +76,7 @@ namespace LongoMatch.Gui.Component
subcat.Name),
subcat);
}
- foreach (PlayerSubCategory subcat in MainClass.ts.PlayerSubcategories) {
+ foreach (PlayerSubCategory subcat in playerSubcategories) {
Log.Debug("Adding player subcategory: ", subcat.Name);
model.AppendValues(String.Format("[{0}] {1}",
Catalog.GetString("Players"),
@@ -126,7 +134,7 @@ namespace LongoMatch.Gui.Component
}
private TagSubCategory EditSubCategoryTags (TagSubCategory template, bool checkName){
- SubCategoryTagsEditor se = new SubCategoryTagsEditor(template);
+ SubCategoryTagsEditor se = new SubCategoryTagsEditor(template, subcategoriesTemplates.TemplatesNames);
se.CheckName = checkName;
int ret = se.Run();
diff --git a/LongoMatch/Gui/Component/DrawingToolBox.cs b/LongoMatch.GUI/Gui/Component/DrawingToolBox.cs
similarity index 99%
rename from LongoMatch/Gui/Component/DrawingToolBox.cs
rename to LongoMatch.GUI/Gui/Component/DrawingToolBox.cs
index 8c4c27b..c0cae4a 100644
--- a/LongoMatch/Gui/Component/DrawingToolBox.cs
+++ b/LongoMatch.GUI/Gui/Component/DrawingToolBox.cs
@@ -20,6 +20,7 @@ using System;
using Gtk;
using Gdk;
using LongoMatch.Handlers;
+using LongoMatch.Common;
namespace LongoMatch.Gui.Component
{
diff --git a/LongoMatch/Gui/Component/DrawingWidget.cs b/LongoMatch.GUI/Gui/Component/DrawingWidget.cs
similarity index 98%
rename from LongoMatch/Gui/Component/DrawingWidget.cs
rename to LongoMatch.GUI/Gui/Component/DrawingWidget.cs
index 586c938..0e4ba50 100644
--- a/LongoMatch/Gui/Component/DrawingWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/DrawingWidget.cs
@@ -20,22 +20,11 @@ using System;
using Gdk;
using Gtk;
using Cairo;
+using LongoMatch.Common;
namespace LongoMatch.Gui.Component
{
- public enum DrawTool {
- PEN,
- LINE,
- DASHED_LINE,
- CIRCLE,
- DASHED_CIRCLE,
- RECTANGLE,
- DASHED_RECTANGLE,
- CROSS,
- DASHED_CROSS,
- ERASER
- }
[System.ComponentModel.ToolboxItem(true)]
public partial class DrawingWidget : Gtk.Bin
diff --git a/LongoMatch/Gui/Component/NotesWidget.cs b/LongoMatch.GUI/Gui/Component/NotesWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/NotesWidget.cs
rename to LongoMatch.GUI/Gui/Component/NotesWidget.cs
diff --git a/LongoMatch.GUI/Gui/Component/PlayListWidget.cs b/LongoMatch.GUI/Gui/Component/PlayListWidget.cs
new file mode 100644
index 0000000..48108cf
--- /dev/null
+++ b/LongoMatch.GUI/Gui/Component/PlayListWidget.cs
@@ -0,0 +1,123 @@
+// PlayListWidget.cs
+//
+// Copyright (C) 2007-2009 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+//Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+//
+
+using System;
+using Gtk;
+using LongoMatch.Common;
+using LongoMatch.Handlers;
+using LongoMatch.Store;
+using LongoMatch.Interfaces;
+
+
+namespace LongoMatch.Gui.Component
+{
+
+ [System.ComponentModel.Category("LongoMatch")]
+ [System.ComponentModel.ToolboxItem(true)]
+ public partial class PlayListWidget : Gtk.Bin, IPlaylistWidget
+ {
+ public event PlayListNodeSelectedHandler PlayListNodeSelected;
+ public event ApplyCurrentRateHandler ApplyCurrentRate;
+ public event NewJobHandler NewRenderingJob;
+ public event OpenPlaylistHandler OpenPlaylistEvent;
+ public event NewPlaylistHandler NewPlaylistEvent;
+ public event SavePlaylistHandler SavePlaylistEvent;
+ public event RenderPlaylistHandler RenderPlaylistEvent;
+
+ public PlayListWidget()
+ {
+ this.Build();
+ playlisttreeview1.Reorderable = true;
+ playlisttreeview1.RowActivated += OnPlaylisttreeview1RowActivated;
+ playlisttreeview1.ApplyCurrentRate += OnApplyRate;
+ savebutton.Sensitive = false;
+
+ newbutton.CanFocus = false;
+ openbutton.CanFocus = false;
+ savebutton.CanFocus = false;
+ newvideobutton.CanFocus = false;
+ }
+
+ public void Load(IPlayList playlist) {
+ label1.Visible = false;
+ newvideobutton.Show();
+ playlisttreeview1.PlayList = playlist;
+ playlisttreeview1.Sensitive = true;
+ savebutton.Sensitive = true;
+ Model = playlist.GetModel();
+ }
+
+ public ListStore Model {
+ set {
+ playlisttreeview1.Model = value;
+ }
+ get {
+ return (ListStore)playlisttreeview1.Model;
+ }
+ }
+
+ public void Add(PlayListPlay plNode) {
+ Model.AppendValues(plNode);
+ }
+
+ public void SetActivePlay (PlayListPlay plNode, int index) {
+ playlisttreeview1.Selection.SelectPath(new TreePath(index.ToString()));
+ playlisttreeview1.LoadedPlay = plNode;
+ }
+
+ protected virtual void OnPlaylisttreeview1RowActivated(object o, Gtk.RowActivatedArgs args)
+ {
+ if (PlayListNodeSelected != null) {
+ TreeIter iter;
+ Model.GetIterFromString(out iter, args.Path.ToString());
+ PlayListNodeSelected(Model.GetValue(iter, 0) as PlayListPlay);
+ }
+ }
+
+ protected virtual void OnApplyRate(PlayListPlay plNode) {
+ if(ApplyCurrentRate != null)
+ ApplyCurrentRate(plNode);
+ }
+
+ protected virtual void OnSavebuttonClicked(object sender, System.EventArgs e)
+ {
+ if (SavePlaylistEvent != null)
+ SavePlaylistEvent();
+ }
+
+ protected virtual void OnOpenbuttonClicked(object sender, System.EventArgs e)
+ {
+ if (OpenPlaylistEvent != null)
+ OpenPlaylistEvent();
+ }
+
+ protected virtual void OnNewbuttonClicked(object sender, System.EventArgs e)
+ {
+ if (NewPlaylistEvent != null)
+ NewPlaylistEvent();
+ }
+
+ protected virtual void OnNewvideobuttonClicked(object sender, System.EventArgs e)
+ {
+ if (RenderPlaylistEvent != null)
+ RenderPlaylistEvent();
+ }
+ }
+}
diff --git a/LongoMatch/Gui/Component/PlayerProperties.cs b/LongoMatch.GUI/Gui/Component/PlayerProperties.cs
similarity index 100%
rename from LongoMatch/Gui/Component/PlayerProperties.cs
rename to LongoMatch.GUI/Gui/Component/PlayerProperties.cs
diff --git a/LongoMatch/Gui/Component/PlayersListTreeWidget.cs b/LongoMatch.GUI/Gui/Component/PlayersListTreeWidget.cs
similarity index 97%
rename from LongoMatch/Gui/Component/PlayersListTreeWidget.cs
rename to LongoMatch.GUI/Gui/Component/PlayersListTreeWidget.cs
index 24eb24e..32be788 100644
--- a/LongoMatch/Gui/Component/PlayersListTreeWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/PlayersListTreeWidget.cs
@@ -32,7 +32,7 @@ namespace LongoMatch.Gui.Component
public partial class PlayersListTreeWidget : Gtk.Bin
{
- public event TimeNodeSelectedHandler TimeNodeSelected;
+ public event PlaySelectedHandler TimeNodeSelected;
public event TimeNodeChangedHandler TimeNodeChanged;
public event PlayListNodeAddedHandler PlayListNodeAdded;
public event SnapshotSeriesHandler SnapshotSeriesEvent;
diff --git a/LongoMatch/Gui/Component/PlayersTaggerWidget.cs b/LongoMatch.GUI/Gui/Component/PlayersTaggerWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/PlayersTaggerWidget.cs
rename to LongoMatch.GUI/Gui/Component/PlayersTaggerWidget.cs
diff --git a/LongoMatch/Gui/Component/PlaysListTreeWidget.cs b/LongoMatch.GUI/Gui/Component/PlaysListTreeWidget.cs
similarity index 95%
rename from LongoMatch/Gui/Component/PlaysListTreeWidget.cs
rename to LongoMatch.GUI/Gui/Component/PlaysListTreeWidget.cs
index 8ec6f8f..cb6ef4f 100644
--- a/LongoMatch/Gui/Component/PlaysListTreeWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/PlaysListTreeWidget.cs
@@ -22,13 +22,10 @@ using System;
using System.Collections.Generic;
using Gtk;
using Mono.Unix;
-using LongoMatch.DB;
using LongoMatch.Gui.Dialog;
using LongoMatch.Handlers;
using LongoMatch.Store;
-using LongoMatch.Services.JobsManager;
using LongoMatch.Common;
-using LongoMatch.Playlist;
namespace LongoMatch.Gui.Component
{
@@ -39,13 +36,13 @@ namespace LongoMatch.Gui.Component
public partial class PlaysListTreeWidget : Gtk.Bin
{
- public event TimeNodeSelectedHandler TimeNodeSelected;
+ public event PlaySelectedHandler TimeNodeSelected;
public event TimeNodeChangedHandler TimeNodeChanged;
- public event TimeNodeDeletedHandler TimeNodeDeleted;
+ public event PlaysDeletedHandler TimeNodeDeleted;
public event PlayListNodeAddedHandler PlayListNodeAdded;
public event SnapshotSeriesHandler SnapshotSeriesEvent;
public event TagPlayHandler TagPlay;
- public event JobHandler NewRenderingJob;
+ public event NewJobHandler NewRenderingJob;
private Project project;
@@ -197,9 +194,10 @@ namespace LongoMatch.Gui.Component
playlist.Add(new PlayListPlay((Play)treeview.Model.GetValue(iter, 0),
project.Description.File, 1, true));
}
+ /* FIXME
job = GuiUtils.ConfigureRenderingJob(playlist, this);
if (job != null && NewRenderingJob != null)
- NewRenderingJob(job);
+ NewRenderingJob(job); */
}
}
}
diff --git a/LongoMatch/Gui/Component/ProjectDetailsWidget.cs b/LongoMatch.GUI/Gui/Component/ProjectDetailsWidget.cs
similarity index 92%
rename from LongoMatch/Gui/Component/ProjectDetailsWidget.cs
rename to LongoMatch.GUI/Gui/Component/ProjectDetailsWidget.cs
index 8402942..2ce690e 100644
--- a/LongoMatch/Gui/Component/ProjectDetailsWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/ProjectDetailsWidget.cs
@@ -25,12 +25,9 @@ using LongoMatch.Common;
using LongoMatch.Gui.Dialog;
using LongoMatch.Gui.Popup;
using LongoMatch.Handlers;
-using LongoMatch.IO;
using LongoMatch.Interfaces;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
-using LongoMatch.Video.Capturer;
-using LongoMatch.Video.Common;
using LongoMatch.Video.Utils;
using Mono.Unix;
@@ -43,23 +40,26 @@ namespace LongoMatch.Gui.Component
public partial class ProjectDetailsWidget : Gtk.Bin
{
public event EventHandler EditedEvent;
- private Project project;
- private LongoMatch.Video.Utils.PreviewMediaFile mFile;
- private bool edited;
- private DateTime date;
- private CalendarPopup cp;
- private Win32CalendarDialog win32CP;
- private Categories actualCategory;
- private TeamTemplate actualVisitorTeam;
- private TeamTemplate actualLocalTeam;
- private ITemplateProvider<Categories, Category> tpc;
- private ITemplateProvider<TeamTemplate, Player> tpt;
- private ProjectType useType;
- private List<Device> videoDevices;
- private ListStore videoStandardList;
- private ListStore encProfileList;
+ Project project;
+ MediaFile mFile;
+ bool edited;
+ DateTime date;
+ CalendarPopup cp;
+ Win32CalendarDialog win32CP;
+ Categories actualCategory;
+ TeamTemplate actualVisitorTeam;
+ TeamTemplate actualLocalTeam;
+ ITemplateProvider<Categories, Category> tpc;
+ ITemplateProvider<TeamTemplate, Player> tpt;
+ ITemplateWidget<Categories, Category> twc;
+ ITemplateWidget<TeamTemplate, Player> twt;
+ ProjectType useType;
+ List<Device> videoDevices;
+ ListStore videoStandardList;
+ ListStore encProfileList;
private const string DV_SOURCE = "DV Source";
private const string GCONF_SOURCE = "GConf Source";
+ string videosDir;
public ProjectDetailsWidget()
@@ -73,18 +73,22 @@ namespace LongoMatch.Gui.Component
cp.DateSelectedEvent += new DateSelectedHandler(OnDateSelected);
}
- tpc = MainClass.ts.CategoriesTemplateProvider;
- tpt = MainClass.ts.TeamTemplateProvider;
-
- FillCategories();
- FillTeamsTemplate();
FillFormats();
-
videoDevices = new List<Device>();
-
Use=ProjectType.FileProject;
}
-
+
+ public ITemplatesService TemplatesService {
+ set {
+ tpc = value.CategoriesTemplateProvider;
+ tpt = value.TeamTemplateProvider;
+ twc = value.GetTemplateEditor<Categories, Category> ();
+ twt = value.GetTemplateEditor<TeamTemplate, Player>();
+ FillCategories();
+ FillTeamsTemplate();
+ }
+ }
+
public ProjectType Use {
set {
bool visible1 = value == ProjectType.CaptureProject;
@@ -294,11 +298,11 @@ namespace LongoMatch.Gui.Component
return null;
else {
if(useType == ProjectType.FakeCaptureProject) {
- mFile = new PreviewMediaFile();
+ mFile = new MediaFile();
mFile.FilePath = Constants.FAKE_PROJECT;
mFile.Fps = 25;
} else if(useType == ProjectType.CaptureProject) {
- mFile = new PreviewMediaFile();
+ mFile = new MediaFile();
mFile.FilePath = fileEntry.Text;
mFile.Fps = 25;
}
@@ -438,7 +442,7 @@ namespace LongoMatch.Gui.Component
FileChooserAction.Save,
"gtk-cancel",ResponseType.Cancel,
"gtk-save",ResponseType.Accept);
- fChooser.SetCurrentFolder(MainClass.VideosDir());
+ fChooser.SetCurrentFolder(videosDir);
fChooser.DoOverwriteConfirmation = true;
if(fChooser.Run() == (int)ResponseType.Accept)
fileEntry.Text = fChooser.Filename;
@@ -474,7 +478,7 @@ namespace LongoMatch.Gui.Component
Catalog.GetString("Analyzing video file:")+"\n"+filename);
md.Icon=Stetic.IconLoader.LoadIcon(this, "longomatch", Gtk.IconSize.Dialog);
md.Show();
- mFile = LongoMatch.Video.Utils.PreviewMediaFile.GetMediaFile(filename);
+ mFile = PreviewMediaFile.DiscoverFile(filename);
if(!mFile.HasVideo || mFile.VideoCodec == "")
throw new Exception(Catalog.GetString("This file doesn't contain a video stream."));
if(mFile.HasVideo && mFile.Length == 0)
@@ -528,7 +532,7 @@ namespace LongoMatch.Gui.Component
protected virtual void OnEditbuttonClicked(object sender, System.EventArgs e)
{
- var editor = new TemplateEditorDialog<Categories, Category>();
+ var editor = new TemplateEditorDialog<Categories, Category>(twc);
editor.Template = Categories;
if (Use == ProjectType.EditProject) {
editor.Project = project;
@@ -538,7 +542,7 @@ namespace LongoMatch.Gui.Component
}
protected virtual void OnLocaltemplatebuttonClicked(object sender, System.EventArgs e) {
- var editor = new TemplateEditorDialog<TeamTemplate, Player>();
+ var editor = new TemplateEditorDialog<TeamTemplate, Player>(twt);
editor.Template = LocalTeamTemplate;
if (Use == ProjectType.EditProject) {
editor.Project = project;
@@ -548,7 +552,7 @@ namespace LongoMatch.Gui.Component
}
protected virtual void OnVisitorbuttonClicked(object sender, System.EventArgs e) {
- var editor = new TemplateEditorDialog<TeamTemplate, Player>();
+ var editor = new TemplateEditorDialog<TeamTemplate, Player>(twt);
editor.Template = VisitorTeamTemplate;
if (Use == ProjectType.EditProject) {
editor.Project = project;
diff --git a/LongoMatch/Gui/Component/ProjectListWidget.cs b/LongoMatch.GUI/Gui/Component/ProjectListWidget.cs
similarity index 99%
rename from LongoMatch/Gui/Component/ProjectListWidget.cs
rename to LongoMatch.GUI/Gui/Component/ProjectListWidget.cs
index dd7691b..a752040 100644
--- a/LongoMatch/Gui/Component/ProjectListWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/ProjectListWidget.cs
@@ -23,8 +23,6 @@ using System.Collections.Generic;
using System.IO;
using Mono.Unix;
using Gtk;
-using Db4objects.Db4o;
-using LongoMatch.DB;
using LongoMatch.Handlers;
using LongoMatch.Store;
using LongoMatch.Video.Utils;
diff --git a/LongoMatch/Gui/Component/RenderingStateBar.cs b/LongoMatch.GUI/Gui/Component/RenderingStateBar.cs
similarity index 100%
rename from LongoMatch/Gui/Component/RenderingStateBar.cs
rename to LongoMatch.GUI/Gui/Component/RenderingStateBar.cs
diff --git a/LongoMatch/Gui/Component/StringTaggerWidget.cs b/LongoMatch.GUI/Gui/Component/StringTaggerWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/StringTaggerWidget.cs
rename to LongoMatch.GUI/Gui/Component/StringTaggerWidget.cs
diff --git a/LongoMatch/Gui/Component/TaggerWidget.cs b/LongoMatch.GUI/Gui/Component/TaggerWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/TaggerWidget.cs
rename to LongoMatch.GUI/Gui/Component/TaggerWidget.cs
diff --git a/LongoMatch/Gui/Component/TagsTreeWidget.cs b/LongoMatch.GUI/Gui/Component/TagsTreeWidget.cs
similarity index 98%
rename from LongoMatch/Gui/Component/TagsTreeWidget.cs
rename to LongoMatch.GUI/Gui/Component/TagsTreeWidget.cs
index b291069..7ac7994 100644
--- a/LongoMatch/Gui/Component/TagsTreeWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/TagsTreeWidget.cs
@@ -22,7 +22,6 @@ using System;
using System.Collections.Generic;
using Gtk;
using Mono.Unix;
-using LongoMatch.DB;
using LongoMatch.Handlers;
using LongoMatch.Store;
@@ -50,7 +49,7 @@ namespace LongoMatch.Gui.Component
public partial class TagsTreeWidget : Gtk.Bin
{
- public event TimeNodeSelectedHandler TimeNodeSelected;
+ public event PlaySelectedHandler TimeNodeSelected;
public event TimeNodeChangedHandler TimeNodeChanged;
public event PlayListNodeAddedHandler PlayListNodeAdded;
public event SnapshotSeriesHandler SnapshotSeriesEvent;
diff --git a/LongoMatch/Gui/Component/TeamTaggerWidget.cs b/LongoMatch.GUI/Gui/Component/TeamTaggerWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/TeamTaggerWidget.cs
rename to LongoMatch.GUI/Gui/Component/TeamTaggerWidget.cs
diff --git a/LongoMatch/Gui/Component/TeamTemplateEditor.cs b/LongoMatch.GUI/Gui/Component/TeamTemplateEditor.cs
similarity index 97%
rename from LongoMatch/Gui/Component/TeamTemplateEditor.cs
rename to LongoMatch.GUI/Gui/Component/TeamTemplateEditor.cs
index 0ba91c6..f197dfe 100644
--- a/LongoMatch/Gui/Component/TeamTemplateEditor.cs
+++ b/LongoMatch.GUI/Gui/Component/TeamTemplateEditor.cs
@@ -18,7 +18,6 @@
using System;
using System.Collections.Generic;
-using System.IO;
using Gdk;
using Gtk;
using Mono.Unix;
@@ -26,9 +25,9 @@ using Stetic;
using LongoMatch.Common;
using LongoMatch.Gui.Dialog;
using LongoMatch.Interfaces;
-using LongoMatch.IO;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
+
namespace LongoMatch.Gui.Component
{
public class TeamTemplateEditorWidget: TemplatesEditorWidget<TeamTemplate, Player>
@@ -38,7 +37,7 @@ namespace LongoMatch.Gui.Component
Gtk.Image shieldImage;
VBox box;
- public TeamTemplateEditorWidget () {
+ public TeamTemplateEditorWidget (ITemplateProvider<TeamTemplate, Player> provider): base(provider) {
treeview = new PlayerPropertiesTreeView();
treeview.PlayerClicked += this.OnPlayerClicked;
treeview.PlayersSelected += this.OnPlayersSelected;
diff --git a/LongoMatch/Gui/Component/TemplatesEditorBase.cs b/LongoMatch.GUI/Gui/Component/TemplatesEditorBase.cs
similarity index 97%
rename from LongoMatch/Gui/Component/TemplatesEditorBase.cs
rename to LongoMatch.GUI/Gui/Component/TemplatesEditorBase.cs
index 2e5f9ca..de3aa76 100644
--- a/LongoMatch/Gui/Component/TemplatesEditorBase.cs
+++ b/LongoMatch.GUI/Gui/Component/TemplatesEditorBase.cs
@@ -103,9 +103,9 @@ namespace LongoMatch.Gui.Component
protected List<U> selected;
protected ITemplateProvider<T, U> provider;
- public TemplatesEditorWidget (): base()
+ public TemplatesEditorWidget (ITemplateProvider<T, U> provider): base()
{
- provider = MainClass.ts.GetTemplateProvider<T, U>();
+ this.provider = provider;
}
public abstract T Template {get; set;}
diff --git a/LongoMatch/Gui/Component/TimeLineWidget.cs b/LongoMatch.GUI/Gui/Component/TimeLineWidget.cs
similarity index 94%
rename from LongoMatch/Gui/Component/TimeLineWidget.cs
rename to LongoMatch.GUI/Gui/Component/TimeLineWidget.cs
index cf25361..5efd169 100644
--- a/LongoMatch/Gui/Component/TimeLineWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/TimeLineWidget.cs
@@ -32,9 +32,9 @@ namespace LongoMatch.Gui.Component {
{
public event TimeNodeChangedHandler TimeNodeChanged;
- public event TimeNodeSelectedHandler TimeNodeSelected;
- public event TimeNodeDeletedHandler TimeNodeDeleted;
- public event NewMarkAtFrameEventHandler NewMarkEvent;
+ public event PlaySelectedHandler TimeNodeSelected;
+ public event PlaysDeletedHandler TimeNodeDeleted;
+ public event NewTagAtFrameHandler NewMarkEvent;
//public event PlayListNodeAddedHandler PlayListNodeAdded;
private Dictionary<Category,TimeScale> tsList;
@@ -165,9 +165,9 @@ namespace LongoMatch.Gui.Component {
TimeScale ts = new TimeScale(cat, playsList,frames);
tsList[cat] = ts;
ts.TimeNodeChanged += new TimeNodeChangedHandler(OnTimeNodeChanged);
- ts.TimeNodeSelected += new TimeNodeSelectedHandler(OnTimeNodeSelected);
- ts.TimeNodeDeleted += new TimeNodeDeletedHandler(OnTimeNodeDeleted);
- ts.NewMarkAtFrameEvent += new NewMarkAtFrameEventHandler(OnNewMark);
+ ts.TimeNodeSelected += new PlaySelectedHandler(OnTimeNodeSelected);
+ ts.TimeNodeDeleted += new PlaysDeletedHandler(OnTimeNodeDeleted);
+ ts.NewMarkAtFrameEvent += new NewTagAtFrameHandler(OnNewMark);
vbox1.PackStart(ts,true,true,0);
ts.Show();
}
diff --git a/LongoMatch/Gui/Component/TimeReferenceWidget.cs b/LongoMatch.GUI/Gui/Component/TimeReferenceWidget.cs
similarity index 100%
rename from LongoMatch/Gui/Component/TimeReferenceWidget.cs
rename to LongoMatch.GUI/Gui/Component/TimeReferenceWidget.cs
diff --git a/LongoMatch/Gui/Component/TimeScale.cs b/LongoMatch.GUI/Gui/Component/TimeScale.cs
similarity index 98%
rename from LongoMatch/Gui/Component/TimeScale.cs
rename to LongoMatch.GUI/Gui/Component/TimeScale.cs
index d5a0f4f..36d7601 100644
--- a/LongoMatch/Gui/Component/TimeScale.cs
+++ b/LongoMatch.GUI/Gui/Component/TimeScale.cs
@@ -65,10 +65,10 @@ namespace LongoMatch.Gui.Component
private Pango.Layout layout;
- public event NewMarkAtFrameEventHandler NewMarkAtFrameEvent;
+ public event NewTagAtFrameHandler NewMarkAtFrameEvent;
public event TimeNodeChangedHandler TimeNodeChanged;
- public event TimeNodeSelectedHandler TimeNodeSelected;
- public event TimeNodeDeletedHandler TimeNodeDeleted;
+ public event PlaySelectedHandler TimeNodeSelected;
+ public event PlaysDeletedHandler TimeNodeDeleted;
public TimeScale(Category category, List<Play> list, uint frames)
diff --git a/LongoMatch/Common/Cloner.cs b/LongoMatch.GUI/Gui/Dialog/About.cs
similarity index 51%
rename from LongoMatch/Common/Cloner.cs
rename to LongoMatch.GUI/Gui/Dialog/About.cs
index 7b00c09..1c7c8d4 100644
--- a/LongoMatch/Common/Cloner.cs
+++ b/LongoMatch.GUI/Gui/Dialog/About.cs
@@ -16,24 +16,32 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
//
using System;
-using System.IO;
+using System.Reflection;
+using Gtk;
using LongoMatch.Common;
-namespace LongoMatch.Common
+namespace LongoMatch.Gui.Dialog
{
- public static class Cloner
+ public class AboutDialog: Gtk.AboutDialog
{
- public static T Clone<T> (this T source) {
- if (Object.ReferenceEquals(source, null))
- return default(T);
-
- Stream s = new MemoryStream();
- using (s) {
- SerializableObject.Save<T>(source, s);
- s.Seek(0, SeekOrigin.Begin);
- return SerializableObject.Load<T>(s);
- }
+ public AboutDialog ()
+ {
+ Version version = Assembly.GetExecutingAssembly().GetName().Version;
+ if(Environment.OSVersion.Platform == PlatformID.Unix)
+ ProgramName = Constants.SOFTWARE_NAME;
+ Version = String.Format("{0}.{1}.{2}",version.Major,version.Minor,version.Build);
+ Copyright = Constants.COPYRIGHT;
+ Website = Constants.WEBSITE;
+ License = Constants.LICENSE;
+ Authors = new string[] {"Andoni Morales Alastruey"};
+ Artists = new string[] {"Bencomo GonzÃlez Marrero"};
+ TranslatorCredits = Constants.TRANSLATORS;
+ SetUrlHook(delegate(Gtk.AboutDialog dialog, string url) {
+ try {
+ System.Diagnostics.Process.Start(url);
+ } catch {}
+ });
}
}
}
diff --git a/LongoMatch/Gui/Dialog/BusyDialog.cs b/LongoMatch.GUI/Gui/Dialog/BusyDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/BusyDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/BusyDialog.cs
diff --git a/LongoMatch/Gui/Dialog/DrawingTool.cs b/LongoMatch.GUI/Gui/Dialog/DrawingTool.cs
similarity index 96%
rename from LongoMatch/Gui/Dialog/DrawingTool.cs
rename to LongoMatch.GUI/Gui/Dialog/DrawingTool.cs
index 14dae05..a8b2823 100644
--- a/LongoMatch/Gui/Dialog/DrawingTool.cs
+++ b/LongoMatch.GUI/Gui/Dialog/DrawingTool.cs
@@ -20,6 +20,7 @@ using System;
using Gdk;
using Gtk;
using Mono.Unix;
+using LongoMatch.Common;
using LongoMatch.Gui.Component;
using LongoMatch.Store;
@@ -29,8 +30,9 @@ namespace LongoMatch.Gui.Dialog
public partial class DrawingTool : Gtk.Dialog
{
- private Play play;
- private int stopTime;
+ Play play;
+ int stopTime;
+ string snapshotsDir;
public DrawingTool()
{
@@ -100,7 +102,7 @@ namespace LongoMatch.Gui.Dialog
FileChooserAction.Save,
"gtk-cancel",ResponseType.Cancel,
"gtk-save",ResponseType.Accept);
- fChooser.SetCurrentFolder(MainClass.SnapshotsDir());
+ fChooser.SetCurrentFolder(snapshotsDir);
fChooser.Filter = filter;
fChooser.DoOverwriteConfirmation = true;
diff --git a/LongoMatch/Gui/Dialog/EditCategoryDialog.cs b/LongoMatch.GUI/Gui/Dialog/EditCategoryDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/EditCategoryDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/EditCategoryDialog.cs
diff --git a/LongoMatch/Gui/Dialog/EditPlayerDialog.cs b/LongoMatch.GUI/Gui/Dialog/EditPlayerDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/EditPlayerDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/EditPlayerDialog.cs
diff --git a/LongoMatch/Gui/Dialog/EndCaptureDialog.cs b/LongoMatch.GUI/Gui/Dialog/EndCaptureDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/EndCaptureDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/EndCaptureDialog.cs
diff --git a/LongoMatch/Gui/Dialog/EntryDialog.cs b/LongoMatch.GUI/Gui/Dialog/EntryDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/EntryDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/EntryDialog.cs
diff --git a/LongoMatch/Gui/Dialog/FramesCaptureProgressDialog.cs b/LongoMatch.GUI/Gui/Dialog/FramesCaptureProgressDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/FramesCaptureProgressDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/FramesCaptureProgressDialog.cs
diff --git a/LongoMatch/Gui/Dialog/HotKeySelectorDialog.cs b/LongoMatch.GUI/Gui/Dialog/HotKeySelectorDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/HotKeySelectorDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/HotKeySelectorDialog.cs
diff --git a/LongoMatch/Gui/Dialog/NewProjectDialog.cs b/LongoMatch.GUI/Gui/Dialog/NewProjectDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/NewProjectDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/NewProjectDialog.cs
diff --git a/LongoMatch/Gui/Dialog/OpenProjectDialog.cs b/LongoMatch.GUI/Gui/Dialog/OpenProjectDialog.cs
similarity index 93%
rename from LongoMatch/Gui/Dialog/OpenProjectDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/OpenProjectDialog.cs
index 08d4702..36c412b 100644
--- a/LongoMatch/Gui/Dialog/OpenProjectDialog.cs
+++ b/LongoMatch.GUI/Gui/Dialog/OpenProjectDialog.cs
@@ -33,7 +33,6 @@ namespace LongoMatch.Gui.Dialog
public OpenProjectDialog()
{
this.Build();
- this.Fill();
projectlistwidget.SelectionMode = SelectionMode.Single;
}
@@ -42,8 +41,8 @@ namespace LongoMatch.Gui.Dialog
set;
}
- public void Fill() {
- projectlistwidget.Fill(MainClass.DB.GetAllProjects());
+ public void Fill(List<ProjectDescription> list) {
+ projectlistwidget.Fill(list);
}
protected virtual void OnProjectlistwidgetProjectsSelected(List<ProjectDescription> projects)
diff --git a/LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs b/LongoMatch.GUI/Gui/Dialog/PlayersSelectionDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/PlayersSelectionDialog.cs
diff --git a/LongoMatch/Gui/Dialog/ProjectSelectionDialog.cs b/LongoMatch.GUI/Gui/Dialog/ProjectSelectionDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/ProjectSelectionDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/ProjectSelectionDialog.cs
diff --git a/LongoMatch/Gui/Dialog/ProjectsManager.cs b/LongoMatch.GUI/Gui/Dialog/ProjectsManager.cs
similarity index 92%
rename from LongoMatch/Gui/Dialog/ProjectsManager.cs
rename to LongoMatch.GUI/Gui/Dialog/ProjectsManager.cs
index ea2d9ae..e1da773 100644
--- a/LongoMatch/Gui/Dialog/ProjectsManager.cs
+++ b/LongoMatch.GUI/Gui/Dialog/ProjectsManager.cs
@@ -22,6 +22,7 @@ using System;
using System.Collections.Generic;
using Gtk;
using LongoMatch.Common;
+using LongoMatch.Interfaces;
using LongoMatch.Store;
using Mono.Unix;
@@ -33,21 +34,22 @@ namespace LongoMatch.Gui.Dialog
public partial class ProjectsManager : Gtk.Dialog
{
- private Project openedProject;
- private List<ProjectDescription> selectedProjects;
+ Project openedProject;
+ List<ProjectDescription> selectedProjects;
+ IDatabase DB;
+ string homeDir = null;
- public ProjectsManager(Project openedProject)
+ public ProjectsManager(Project openedProject, IDatabase DB)
{
this.Build();
this.openedProject = openedProject;
- this.Fill();
this.projectdetails.Use = ProjectType.EditProject;
+ this.DB = DB;
projectdetails.Edited = false;
}
public void Fill() {
- List<ProjectDescription> projectsList = MainClass.DB.GetAllProjects();
- projectlistwidget1.Fill(projectsList);
+ projectlistwidget1.Fill(DB.GetAllProjects());
projectlistwidget1.ClearSearch();
projectlistwidget1.SelectionMode = SelectionMode.Multiple;
Clear();
@@ -78,7 +80,7 @@ namespace LongoMatch.Gui.Dialog
if(project == null)
return;
- MainClass.DB.UpdateProject(project);
+ DB.UpdateProject(project);
saveButton.Sensitive = false;
projectlistwidget1.QueueDraw();
}
@@ -105,7 +107,7 @@ namespace LongoMatch.Gui.Dialog
Catalog.GetString("Do you really want to delete:")+
"\n"+selectedProject.Title);
if(md.Run()== (int)ResponseType.Yes) {
- MainClass.DB.RemoveProject(selectedProject.UUID);
+ DB.RemoveProject(selectedProject.UUID);
deletedProjects.Add(selectedProject);
}
md.Destroy();
@@ -165,7 +167,7 @@ namespace LongoMatch.Gui.Dialog
}
else {
projectdetails.Sensitive = true;
- projectdetails.SetProject(MainClass.DB.GetProject(project.UUID));
+ projectdetails.SetProject(DB.GetProject(project.UUID));
saveButton.Sensitive = false;
deleteButton.Sensitive = true;
exportbutton.Sensitive = true;
@@ -184,7 +186,7 @@ namespace LongoMatch.Gui.Dialog
FileChooserAction.Save,
"gtk-cancel",ResponseType.Cancel,
"gtk-save",ResponseType.Accept);
- fChooser.SetCurrentFolder(MainClass.HomeDir());
+ fChooser.SetCurrentFolder(homeDir);
FileFilter filter = new FileFilter();
filter.Name = Constants.PROJECT_NAME;
filter.AddPattern("*.lpr");
diff --git a/LongoMatch/Gui/Dialog/RenderingJobsDialog.cs b/LongoMatch.GUI/Gui/Dialog/RenderingJobsDialog.cs
similarity index 95%
rename from LongoMatch/Gui/Dialog/RenderingJobsDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/RenderingJobsDialog.cs
index ae413fb..8b9eb33 100644
--- a/LongoMatch/Gui/Dialog/RenderingJobsDialog.cs
+++ b/LongoMatch.GUI/Gui/Dialog/RenderingJobsDialog.cs
@@ -20,17 +20,17 @@ using System.Collections.Generic;
using Gtk;
using LongoMatch.Common;
+using LongoMatch.Interfaces;
-using LongoMatch.Services.JobsManager;
namespace LongoMatch.Gui.Dialog
{
public partial class RenderingJobsDialog : Gtk.Dialog
{
- RenderingJobsManager manager;
+ IRenderingJobsManager manager;
TreeStore model;
- public RenderingJobsDialog (RenderingJobsManager manager)
+ public RenderingJobsDialog (IRenderingJobsManager manager)
{
this.Build ();
this.manager = manager;
diff --git a/LongoMatch/Gui/Dialog/SnapshotsDialog.cs b/LongoMatch.GUI/Gui/Dialog/SnapshotsDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/SnapshotsDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/SnapshotsDialog.cs
diff --git a/LongoMatch/Gui/Dialog/SubCategoryTagsEditor.cs b/LongoMatch.GUI/Gui/Dialog/SubCategoryTagsEditor.cs
similarity index 96%
rename from LongoMatch/Gui/Dialog/SubCategoryTagsEditor.cs
rename to LongoMatch.GUI/Gui/Dialog/SubCategoryTagsEditor.cs
index acc1f70..e4391d6 100644
--- a/LongoMatch/Gui/Dialog/SubCategoryTagsEditor.cs
+++ b/LongoMatch.GUI/Gui/Dialog/SubCategoryTagsEditor.cs
@@ -31,11 +31,11 @@ namespace LongoMatch.Gui.Dialog
private List<string> templates;
private Color templateExistsColor;
- public SubCategoryTagsEditor (TagSubCategory template)
+ public SubCategoryTagsEditor (TagSubCategory template, List<string> templates)
{
this.Build ();
Gdk.Color.Parse("red", ref templateExistsColor);
- templates = MainClass.ts.SubCategoriesTemplateProvider.TemplatesNames;
+ this.templates = templates;
tagsDict = new Dictionary<string, Widget>();
addtagbutton.Clicked += OnAddTag;
tagentry.Activated += OnAddTag;
diff --git a/LongoMatch/Gui/Dialog/TaggerDialog.cs b/LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/TaggerDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs
diff --git a/LongoMatch/Gui/Dialog/TemplateEditorDialog.cs b/LongoMatch.GUI/Gui/Dialog/TemplateEditorDialog.cs
similarity index 94%
rename from LongoMatch/Gui/Dialog/TemplateEditorDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/TemplateEditorDialog.cs
index 236087e..fc6e163 100644
--- a/LongoMatch/Gui/Dialog/TemplateEditorDialog.cs
+++ b/LongoMatch.GUI/Gui/Dialog/TemplateEditorDialog.cs
@@ -45,8 +45,8 @@ namespace LongoMatch.Gui.Dialog
public class TemplateEditorDialog<T, U> : TemplateEditorDialog where T: ITemplate<U> {
ITemplateWidget<T, U> templateEditor;
- public TemplateEditorDialog () {
- templateEditor = MainClass.ts.GetTemplateEditor<T, U> ();
+ public TemplateEditorDialog (ITemplateWidget<T, U> templateEditor) {
+ this.templateEditor = templateEditor;
templateEditor.CanExport = true;
AddTemplateEditor ((Widget)templateEditor);
diff --git a/LongoMatch/Gui/Dialog/TemplatesManager.cs b/LongoMatch.GUI/Gui/Dialog/TemplatesManager.cs
similarity index 96%
rename from LongoMatch/Gui/Dialog/TemplatesManager.cs
rename to LongoMatch.GUI/Gui/Dialog/TemplatesManager.cs
index 1dd6514..c766e29 100644
--- a/LongoMatch/Gui/Dialog/TemplatesManager.cs
+++ b/LongoMatch.GUI/Gui/Dialog/TemplatesManager.cs
@@ -27,7 +27,6 @@ using Mono.Unix;
using LongoMatch.Interfaces;
using LongoMatch.Gui.Component;
using LongoMatch.Store.Templates;
-using LongoMatch.Services;
namespace LongoMatch.Gui.Dialog
{
@@ -79,11 +78,14 @@ namespace LongoMatch.Gui.Dialog
private ITemplateWidget<T, U> templatesWidget;
private string templateName;
- public TemplatesManager() : base()
+ public TemplatesManager(ITemplateProvider<T, U> templatesProvider,
+ ITemplateWidget<T, U> templatesWidget) : base()
{
treeview = this.TreeView;
- templatesProvider = MainClass.ts.GetTemplateProvider<T, U> ();
- templatesWidget = MainClass.ts.GetTemplateEditor <T, U> ();
+ this.templatesProvider = templatesProvider;
+ //MainClass.ts.GetTemplateProvider<T, U> ();
+ this.templatesWidget = templatesWidget;
+ //MainClass.ts.GetTemplateEditor <T, U> ();
AddTemplateEditor ((Widget) templatesWidget);
Gtk.TreeViewColumn templateFileColumn = new Gtk.TreeViewColumn();
diff --git a/LongoMatch/Gui/Dialog/UpdateDialog.cs b/LongoMatch.GUI/Gui/Dialog/UpdateDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/UpdateDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/UpdateDialog.cs
diff --git a/LongoMatch/Gui/Dialog/VideoEditionProperties.cs b/LongoMatch.GUI/Gui/Dialog/VideoEditionProperties.cs
similarity index 98%
rename from LongoMatch/Gui/Dialog/VideoEditionProperties.cs
rename to LongoMatch.GUI/Gui/Dialog/VideoEditionProperties.cs
index 0dba29c..bb7d06a 100644
--- a/LongoMatch/Gui/Dialog/VideoEditionProperties.cs
+++ b/LongoMatch.GUI/Gui/Dialog/VideoEditionProperties.cs
@@ -35,6 +35,7 @@ namespace LongoMatch.Gui.Dialog
private EncodingSettings encSettings;
private ListStore stdStore;
private ListStore encStore;
+ private string videosDir;
#region Constructors
@@ -147,7 +148,7 @@ namespace LongoMatch.Gui.Dialog
FileChooserAction.Save,
"gtk-cancel",ResponseType.Cancel,
"gtk-save",ResponseType.Accept);
- fChooser.SetCurrentFolder(MainClass.VideosDir());
+ fChooser.SetCurrentFolder(videosDir);
fChooser.CurrentName = "NewVideo."+GetExtension();
fChooser.DoOverwriteConfirmation = true;
FileFilter filter = new FileFilter();
diff --git a/LongoMatch/Gui/Dialog/Win32CalendarDialog.cs b/LongoMatch.GUI/Gui/Dialog/Win32CalendarDialog.cs
similarity index 100%
rename from LongoMatch/Gui/Dialog/Win32CalendarDialog.cs
rename to LongoMatch.GUI/Gui/Dialog/Win32CalendarDialog.cs
diff --git a/LongoMatch.GUI/Gui/MainWindow.cs b/LongoMatch.GUI/Gui/MainWindow.cs
new file mode 100644
index 0000000..fb99c65
--- /dev/null
+++ b/LongoMatch.GUI/Gui/MainWindow.cs
@@ -0,0 +1,738 @@
+// MainWindow.cs
+//
+// Copyright (C) 2007-2009 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+//Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+//
+
+using System;
+using System.Collections.Generic;
+using System.IO;
+using Gdk;
+using GLib;
+using Gtk;
+using LongoMatch.Common;
+using LongoMatch.Gui.Dialog;
+using LongoMatch.Handlers;
+using LongoMatch.Interfaces;
+using LongoMatch.Store;
+using LongoMatch.Store.Templates;
+using LongoMatch.Video.Common;
+
+using Mono.Unix;
+using LongoMatch.Gui.Component;
+using LongoMatch.Multimedia.Interfaces;
+
+
+
+namespace LongoMatch.Gui
+{
+ [System.ComponentModel.Category("LongoMatch")]
+ [System.ComponentModel.ToolboxItem(false)]
+ public partial class MainWindow : Gtk.Window
+ {
+
+ /* Tags */
+ public event NewTagHandler NewTagEvent;
+ public event NewTagStartHandler NewTagStartEvent;
+ public event NewTagStopHandler NewTagStopEvent;
+ public event PlaySelectedHandler PlaySelectedEvent;
+ public event NewTagAtFrameHandler NewTagAtFrameEvent;
+ public event TagPlayHandler TagPlayEvent;
+ public event PlaysDeletedHandler PlaysDeletedEvent;
+ public event TimeNodeChangedHandler TimeNodeChanged;
+
+ /* Playlist */
+ public event NewJobHandler NewJobEvent;
+ public event PlayListNodeAddedHandler PlayListNodeAddedEvent;
+ public event PlayListNodeSelectedHandler PlayListNodeSelectedEvent;
+ public event OpenPlaylistHandler OpenPlaylistEvent;
+ public event NewPlaylistHandler NewPlaylistEvent;
+ public event SavePlaylistHandler SavePlaylistEvent;
+
+ /* Snapshots */
+ public event SnapshotSeriesHandler SnapshotSeriesEvent;
+
+ /* Projects */
+ public event SaveProjectHandler SaveProjectEvent;
+ public event NewProjectHandler NewProjectEvent;
+ public event OpenProjectHandler OpenProjectEvent;
+ public event ImportProjectHandler ImportProjectEvent;
+ public event ExportProjectHandler ExportProjectEvent;
+
+ /* Managers */
+ public event ManageJobsHandler ManageJobsEvent;
+ public event ManageTeamsHandler ManageTeamsEvent;
+ public event ManageCategoriesHandler ManageCategoriesEvent;
+ public event ManageProjects ManageProjectsEvent;
+ public event ApplyCurrentRateHandler ApplyRateEvent;
+
+ private static Project openedProject;
+ private ProjectType projectType;
+ private TimeNode selectedTimeNode;
+
+ #region Constructors
+ public MainWindow() :
+ base("LongoMatch")
+ {
+ this.Build();
+
+ projectType = ProjectType.None;
+
+ player.SetLogo(System.IO.Path.Combine(Config.ImagesDir(),"background.png"));
+ player.LogoMode = true;
+ player.Tick += OnTick;
+
+ capturer.Visible = false;
+ capturer.Logo = System.IO.Path.Combine(Config.ImagesDir(),"background.png");
+ capturer.CaptureFinished += delegate {
+ CloseCaptureProject();
+ };
+
+ buttonswidget.Mode = TagMode.Predifined;
+ localPlayersList.Team = Team.LOCAL;
+ visitorPlayersList.Team = Team.VISITOR;
+
+ ConnectSignals();
+ ConnectMenuSignals();
+ }
+
+ #endregion
+
+ #region Plubic Methods
+ public void AddPlay(Play play) {
+ playsList.AddPlay(play);
+ tagsList.AddPlay(play);
+ timeline.AddPlay(play);
+ /* FIXME: Check performance */
+ UpdateTeamsModels();
+ timeline.QueueDraw();
+ }
+
+ public void UpdateSelectedPlay (Play play) {
+ timeline.SelectedTimeNode = play;
+ notes.Visible = true;
+ notes.Play= play;
+ }
+
+ public void UpdateCategories (Categories categories) {
+ buttonswidget.Categories = openedProject.Categories;
+ }
+
+ public void DeletePlays (List<Play> plays) {
+ playsList.RemovePlays(plays);
+ timeline.RemovePlays(plays);
+ tagsList.RemovePlays(plays);
+ UpdateTeamsModels();
+ timeline.QueueDraw();
+ }
+
+ public RenderingStateBar RenderingStateBar{
+ get {
+ return renderingstatebar1;
+ }
+ }
+
+ public PlayerBin Player{
+ get {
+ return player;
+ }
+ }
+
+ public CapturerBin Capturer{
+ get {
+ return capturer;
+ }
+ }
+
+ public PlayListWidget Playlist{
+ get {
+ return playlist;
+ }
+ }
+ #endregion
+
+ #region Private Methods
+
+ private void ConnectSignals() {
+ /* Adding Handlers for each event */
+
+ /* Connect new mark event */
+ buttonswidget.NewMarkEvent += EmitNewTag;;
+ buttonswidget.NewMarkStartEvent += EmitNewTagStart;
+ buttonswidget.NewMarkStopEvent += EmitNewTagStop;
+
+ /* Connect TimeNodeChanged events */
+ playsList.TimeNodeChanged += EmitTimeNodeChanged;
+ localPlayersList.TimeNodeChanged += EmitTimeNodeChanged;
+ visitorPlayersList.TimeNodeChanged += EmitTimeNodeChanged;
+ tagsList.TimeNodeChanged += EmitTimeNodeChanged;
+ timeline.TimeNodeChanged += EmitTimeNodeChanged;
+ notes.TimeNodeChanged += EmitTimeNodeChanged;
+
+ /* Connect TimeNodeDeleted events */
+ playsList.TimeNodeDeleted += EmitPlaysDeleted;
+ timeline.TimeNodeDeleted += EmitPlaysDeleted;
+
+ /* Connect TimeNodeSelected events */
+ playsList.TimeNodeSelected += OnTimeNodeSelected;
+ localPlayersList.TimeNodeSelected += OnTimeNodeSelected;
+ visitorPlayersList.TimeNodeSelected += OnTimeNodeSelected;
+ tagsList.TimeNodeSelected += OnTimeNodeSelected;
+ timeline.TimeNodeSelected += OnTimeNodeSelected;
+
+ /* Connect playlist events */
+ playlist.PlayListNodeSelected += EmitPlayListNodeSelected;
+ playlist.ApplyCurrentRate += EmitApplyRate;
+ playlist.NewPlaylistEvent += EmitNewPlaylist;
+ playlist.OpenPlaylistEvent += EmitOpenPlaylist;
+ playlist.SavePlaylistEvent += EmitSavePlaylist;
+
+ /* Connect PlayListNodeAdded events */
+ playsList.PlayListNodeAdded += OnPlayListNodeAdded;
+ localPlayersList.PlayListNodeAdded += OnPlayListNodeAdded;
+ visitorPlayersList.PlayListNodeAdded += OnPlayListNodeAdded;
+ tagsList.PlayListNodeAdded += OnPlayListNodeAdded;
+
+ /* Connect tags events */
+ playsList.TagPlay += EmitTagPlay;
+
+ /* Connect SnapshotSeries events */
+ playsList.SnapshotSeriesEvent += EmitSnapshotSeries;
+ localPlayersList.SnapshotSeriesEvent += EmitSnapshotSeries;
+ visitorPlayersList.SnapshotSeriesEvent += EmitSnapshotSeries;
+ tagsList.SnapshotSeriesEvent += EmitSnapshotSeries;
+
+ /* Connect timeline events */
+ timeline.NewMarkEvent += EmitNewTagAtFrame;
+
+ playlist.NewRenderingJob += EmitNewJob;
+ playsList.NewRenderingJob += EmitNewJob;
+
+ renderingstatebar1.ManageJobs += (e, o) => {EmitManageJobs();};
+ }
+
+ private void ConnectMenuSignals() {
+ SaveProjectAction.Activated += (o, e) => {EmitSaveProject();};
+ CloseProjectAction.Activated += (o, e) => {PromptCloseProject();};
+ ImportProjectAction.Activated += (o, e) => {EmitImportProject();};
+ ExportProjectToCSVFileAction.Activated += (o, e) => {EmitExportProject();};
+ QuitAction.Activated += (o, e) => {CloseAndQuit();};
+ CategoriesTemplatesManagerAction.Activated += (o, e) => {EmitManageCategories();};
+ TeamsTemplatesManagerAction.Activated += (o, e) => {EmitManageTeams();};
+ ProjectsManagerAction.Activated += (o, e) => {EmitManageProjects();};
+ }
+
+ private void UpdateTeamsModels() {
+ TreeStore local, visitor;
+
+ openedProject.GetPlayersModel (out local, out visitor);
+ localPlayersList.SetTeam(local);
+ visitorPlayersList.SetTeam(visitor);
+ }
+
+ public bool SetProject(Project project, ProjectType projectType, CaptureSettings props)
+ {
+ bool isLive = false;
+
+ /* Update tabs labels */
+ var desc = project.Description;
+ visitorteamlabel.Text = desc.VisitorName;
+ localteamlabel.Text = desc.LocalName;
+
+ if(projectType == ProjectType.FileProject) {
+ Title = System.IO.Path.GetFileNameWithoutExtension(desc.File.FilePath) +
+ " - " + Constants.SOFTWARE_NAME;
+ player.LogoMode = false;
+ timeline.Project = project;
+
+ } else {
+ Title = Constants.SOFTWARE_NAME;
+ isLive = true;
+ if(projectType == ProjectType.FakeCaptureProject)
+ capturer.Type = CapturerType.Fake;
+ player.Visible = false;
+ capturer.Visible = true;
+ TaggingViewAction.Active = true;
+ }
+
+ playsList.ProjectIsLive = isLive;
+ localPlayersList.ProjectIsLive = isLive;
+ visitorPlayersList.ProjectIsLive = isLive;
+ tagsList.ProjectIsLive = isLive;
+ playsList.Project=project;
+ tagsList.Project = project;
+ UpdateTeamsModels(project);
+ buttonswidget.Categories = project.Categories;
+ MakeActionsSensitive(true,projectType);
+ ShowWidgets();
+ return true;
+ }
+
+ private void UpdateTeamsModels(Project project) {
+ TreeStore local, visitor;
+
+ project.GetPlayersModel (out local, out visitor);
+ localPlayersList.SetTeam(local);
+ visitorPlayersList.SetTeam(visitor);
+ }
+
+ private void CloseCaptureProject() {
+ if(projectType == ProjectType.CaptureProject) {
+ capturer.Close();
+ player.Visible = true;
+ capturer.Visible = false;;
+ EmitSaveProject();
+ } else if(projectType == ProjectType.FakeCaptureProject) {
+ CloseOpenedProject(true);
+ }
+ }
+
+ private void CloseOpenedProject(bool save) {
+ /* FIXME
+ * EmitCloseOpenedProject(save);
+ */
+ if(projectType != ProjectType.FileProject)
+ capturer.Close();
+ else
+ player.Close();
+
+ if(openedProject != null)
+ openedProject.Clear();
+ openedProject = null;
+ projectType = ProjectType.None;
+ ResetGUI();
+ }
+
+ private void ResetGUI() {
+ bool playlistVisible = playlist.Visible;
+ Title = Constants.SOFTWARE_NAME;
+ player.Visible = true;
+ player.LogoMode = true;
+ capturer.Visible = false;
+ ClearWidgets();
+ HideWidgets();
+ playlist.Visible = playlistVisible;
+ rightvbox.Visible = playlistVisible;
+ notes.Visible = false;
+ selectedTimeNode = null;
+ MakeActionsSensitive(false, projectType);
+ }
+
+ private void MakeActionsSensitive(bool sensitive, ProjectType projectType) {
+ bool sensitive2 = sensitive && projectType == ProjectType.FileProject;
+ CloseProjectAction.Sensitive=sensitive;
+ SaveProjectAction.Sensitive = sensitive;
+ TaggingViewAction.Sensitive = sensitive2;
+ ManualTaggingViewAction.Sensitive = sensitive2;
+ TimelineViewAction.Sensitive = sensitive2;
+ ExportProjectToCSVFileAction.Sensitive = sensitive2;
+ HideAllWidgetsAction.Sensitive=sensitive2;
+ }
+
+ private void ShowWidgets() {
+ leftbox.Show();
+ if(TaggingViewAction.Active || ManualTaggingViewAction.Active)
+ buttonswidget.Show();
+ else
+ timeline.Show();
+ }
+
+ private void HideWidgets() {
+ leftbox.Hide();
+ rightvbox.Hide();
+ buttonswidget.Hide();
+ timeline.Hide();
+ }
+
+ private void ClearWidgets() {
+ buttonswidget.Categories = null;
+ playsList.Project = null;
+ tagsList.Clear();
+ timeline.Project = null;
+ localPlayersList.Clear();
+ visitorPlayersList.Clear();
+ }
+
+ private bool PromptCloseProject() {
+ int res;
+ EndCaptureDialog dialog;
+
+ if(openedProject == null)
+ return true;
+
+ if(projectType == ProjectType.FileProject) {
+ MessageDialog md = new MessageDialog(this, DialogFlags.Modal,
+ MessageType.Question, ButtonsType.OkCancel,
+ Catalog.GetString("Do you want to close the current project?"));
+ res = md.Run();
+ md.Destroy();
+ if(res == (int)ResponseType.Ok) {
+ CloseOpenedProject(true);
+ return true;
+ }
+ return false;
+ }
+
+ /* Capture project */
+ dialog = new EndCaptureDialog();
+ dialog.TransientFor = (Gtk.Window)this.Toplevel;
+ res = dialog.Run();
+ dialog.Destroy();
+
+ /* Close project wihtout saving */
+ if(res == (int)EndCaptureResponse.Quit) {
+ CloseOpenedProject(false);
+ return true;
+ } else if(res == (int)EndCaptureResponse.Save) {
+ /* Close and save project */
+ CloseOpenedProject(true);
+ return true;
+ } else
+ /* Continue with the current project */
+ return false;
+ }
+
+ private void CloseAndQuit() {
+ if(!PromptCloseProject())
+ return;
+ EmitSaveProject();
+ player.Dispose();
+ Application.Quit();
+ }
+
+ #endregion
+
+ #region Callbacks
+ #region File
+ protected virtual void OnNewActivated(object sender, System.EventArgs e)
+ {
+ if(!PromptCloseProject())
+ return;
+ EmitNewProject();
+ }
+
+ protected virtual void OnOpenActivated(object sender, System.EventArgs e)
+ {
+ if(!PromptCloseProject())
+ return;
+ EmitOpenProject();
+ }
+ #endregion
+
+ #region View
+ protected virtual void OnFullScreenActionToggled(object sender, System.EventArgs e)
+ {
+ player.FullScreen = (sender as Gtk.ToggleAction).Active;
+ }
+
+ protected virtual void OnPlaylistActionToggled(object sender, System.EventArgs e)
+ {
+ bool visible = (sender as Gtk.ToggleAction).Active;
+ playlist.Visible=visible;
+ playsList.PlayListLoaded=visible;
+ localPlayersList.PlayListLoaded=visible;
+ visitorPlayersList.PlayListLoaded=visible;
+
+ if(!visible && !notes.Visible) {
+ rightvbox.Visible = false;
+ } else if(visible) {
+ rightvbox.Visible = true;
+ }
+ }
+
+ protected virtual void OnHideAllWidgetsActionToggled(object sender, System.EventArgs e)
+ {
+ ToggleAction action = sender as ToggleAction;
+
+ if(openedProject == null)
+ return;
+
+ leftbox.Visible = !action.Active;
+ timeline.Visible = !action.Active && TimelineViewAction.Active;
+ buttonswidget.Visible = !action.Active &&
+ (TaggingViewAction.Active || ManualTaggingViewAction.Active);
+ if(action.Active)
+ rightvbox.Visible = false;
+ else if(!action.Active && (playlist.Visible || notes.Visible))
+ rightvbox.Visible = true;
+ }
+
+ protected virtual void OnViewToggled(object sender, System.EventArgs e)
+ {
+ /* this callback is triggered by Capture and Free Capture */
+ ToggleAction view = sender as Gtk.ToggleAction;
+ buttonswidget.Visible = view.Active;
+ timeline.Visible = !view.Active;
+ if(view == ManualTaggingViewAction)
+ buttonswidget.Mode = TagMode.Free;
+ else
+ buttonswidget.Mode = TagMode.Predifined;
+ }
+ #endregion
+ #region Help
+ protected virtual void OnHelpAction1Activated(object sender, System.EventArgs e)
+ {
+ try {
+ System.Diagnostics.Process.Start(Constants.MANUAL);
+ } catch {}
+ }
+
+ protected virtual void OnAboutActionActivated(object sender, System.EventArgs e)
+ {
+ var about = new LongoMatch.Gui.Dialog.AboutDialog();
+ about.TransientFor = this;
+ about.Run();
+ about.Destroy();
+ }
+ #endregion
+
+ protected virtual void OnPlayerbin1Error(object o, LongoMatch.Video.Common.ErrorArgs args)
+ {
+ MessagePopup.PopupMessage(this, MessageType.Info,
+ Catalog.GetString("The actual project will be closed due to an error in the media player:")+"\n" +args.Message);
+ CloseOpenedProject(true);
+ }
+
+ protected override bool OnKeyPressEvent(EventKey evnt)
+ {
+ Gdk.Key key = evnt.Key;
+ Gdk.ModifierType modifier = evnt.State;
+ bool ret;
+
+ ret = base.OnKeyPressEvent(evnt);
+
+ if(openedProject == null && !player.Opened)
+ return ret;
+
+ if(projectType != ProjectType.CaptureProject &&
+ projectType != ProjectType.FakeCaptureProject) {
+ switch(key) {
+ case Constants.SEEK_FORWARD:
+ if(modifier == Constants.STEP)
+ player.StepForward();
+ else
+ player.SeekToNextFrame(selectedTimeNode != null);
+ break;
+ case Constants.SEEK_BACKWARD:
+ if(modifier == Constants.STEP)
+ player.StepBackward();
+ else
+ player.SeekToPreviousFrame(selectedTimeNode != null);
+ break;
+ case Constants.FRAMERATE_UP:
+ player.FramerateUp();
+ break;
+ case Constants.FRAMERATE_DOWN:
+ player.FramerateDown();
+ break;
+ case Constants.TOGGLE_PLAY:
+ player.TogglePlay();
+ break;
+ }
+ } else {
+ switch(key) {
+ case Constants.TOGGLE_PLAY:
+ capturer.TogglePause();
+ break;
+ }
+ }
+ return ret;
+ }
+
+ protected virtual void OnTimeNodeSelected(Play play)
+ {
+ rightvbox.Visible=true;
+ }
+
+ protected virtual void OnSegmentClosedEvent()
+ {
+ if(!playlist.Visible)
+ rightvbox.Visible=false;
+ timeline.SelectedTimeNode = null;
+ notes.Visible = false;
+ }
+
+ protected virtual void OnTick(object o, TickArgs args)
+ {
+ if(args.CurrentTime != 0 && timeline != null && openedProject != null)
+ timeline.CurrentFrame=(uint)(args.CurrentTime *
+ openedProject.Description.File.Fps / 1000);
+ }
+
+
+ protected virtual void OnUpdate(Version version, string URL) {
+ LongoMatch.Gui.Dialog.UpdateDialog updater = new LongoMatch.Gui.Dialog.UpdateDialog();
+ updater.Fill(version, URL);
+ updater.TransientFor = this;
+ updater.Run();
+ updater.Destroy();
+ }
+
+ protected virtual void OnDrawingToolActionToggled(object sender, System.EventArgs e)
+ {
+ drawingtoolbox1.Visible = DrawingToolAction.Active;
+ drawingtoolbox1.DrawingVisibility = DrawingToolAction.Active;
+ }
+
+ protected override bool OnDeleteEvent(Gdk.Event evnt)
+ {
+ CloseAndQuit();
+ return true;
+ }
+
+ protected virtual void OnCapturerBinError(object o, LongoMatch.Video.Common.ErrorArgs args)
+ {
+ MessagePopup.PopupMessage(this, MessageType.Info,
+ Catalog.GetString("An error occured in the video capturer and the current project will be closed:")+"\n" +args.Message);
+ CloseOpenedProject(true);
+ }
+ #endregion
+
+ #region Events
+ private void EmitPlaySelected(Play play)
+ {
+ if (PlaySelectedEvent != null)
+ PlaySelectedEvent(play);
+ }
+
+ private void EmitTimeNodeChanged(TimeNode tNode, object val)
+ {
+ if (TimeNodeChanged != null)
+ TimeNodeChanged(tNode, val);
+ }
+
+ private void EmitPlaysDeleted(List<Play> plays)
+ {
+ if (PlaysDeletedEvent != null)
+ PlaysDeletedEvent(plays);
+ }
+
+ private void OnPlayListNodeAdded(Play play)
+ {
+ if (PlayListNodeAddedEvent != null)
+ PlayListNodeAddedEvent(play);
+ }
+
+ private void EmitPlayListNodeSelected(PlayListPlay plNode)
+ {
+ if (PlayListNodeSelectedEvent != null)
+ PlayListNodeSelectedEvent(plNode);
+ }
+
+ private void EmitSnapshotSeries(Play play) {
+ if (SnapshotSeriesEvent != null)
+ SnapshotSeriesEvent (play);
+ }
+
+ private void EmitNewTagAtFrame(Category category, int frame) {
+ if (NewTagAtFrameEvent != null)
+ NewTagAtFrameEvent(category, frame);
+ }
+
+ private void EmitNewTag(Category category) {
+ if (NewTagEvent != null)
+ NewTagEvent(category);
+ }
+
+ private void EmitNewTagStart() {
+ if (NewTagStartEvent != null)
+ NewTagStartEvent ();
+ }
+
+ private void EmitNewTagStop(Category category) {
+ if (NewTagStopEvent != null)
+ NewTagStopEvent (category);
+ }
+
+ private void EmitNewJob(Job job) {
+ if (NewJobEvent != null)
+ NewJobEvent(job);
+ }
+
+ private void EmitApplyRate(PlayListPlay plNode) {
+ if (ApplyRateEvent != null)
+ ApplyRateEvent (plNode);
+ }
+
+ private void EmitTagPlay(Play play) {
+ if (TagPlayEvent != null)
+ TagPlayEvent (play);
+ }
+
+ private void EmitSaveProject() {
+ if (SaveProjectEvent != null)
+ SaveProjectEvent(openedProject, projectType);
+ }
+
+ private void EmitNewProject() {
+ if (NewProjectEvent != null)
+ NewProjectEvent();
+ }
+
+ private void EmitImportProject() {
+ if (ImportProjectEvent != null)
+ ImportProjectEvent();
+ }
+
+ private void EmitOpenProject() {
+ if(OpenProjectEvent == null)
+ OpenProjectEvent();
+ }
+
+ private void EmitExportProject() {
+ if(ExportProjectEvent == null)
+ ExportProjectEvent();
+ }
+
+ private void EmitManageJobs() {
+ if(ManageJobsEvent == null)
+ ManageJobsEvent();
+ }
+
+ private void EmitManageTeams() {
+ if(ManageTeamsEvent == null)
+ ManageTeamsEvent();
+ }
+
+ private void EmitManageCategories() {
+ if(ManageCategoriesEvent == null)
+ ManageCategoriesEvent();
+ }
+
+ private void EmitManageProjects()
+ {
+ if (ManageProjectsEvent != null)
+ ManageProjectsEvent();
+ }
+
+ private void EmitNewPlaylist() {
+ if (NewPlaylistEvent != null)
+ NewPlaylistEvent();
+ }
+
+ private void EmitOpenPlaylist() {
+ if (OpenPlaylistEvent != null)
+ OpenPlaylistEvent();
+ }
+
+ private void EmitSavePlaylist() {
+ if (SavePlaylistEvent != null)
+ SavePlaylistEvent();
+ }
+ #endregion
+ }
+}
diff --git a/LongoMatch/Gui/Popup/CalendarPopup.cs b/LongoMatch.GUI/Gui/Popup/CalendarPopup.cs
similarity index 100%
rename from LongoMatch/Gui/Popup/CalendarPopup.cs
rename to LongoMatch.GUI/Gui/Popup/CalendarPopup.cs
diff --git a/LongoMatch/Gui/Popup/MessagePopup.cs b/LongoMatch.GUI/Gui/Popup/MessagePopup.cs
similarity index 100%
rename from LongoMatch/Gui/Popup/MessagePopup.cs
rename to LongoMatch.GUI/Gui/Popup/MessagePopup.cs
diff --git a/LongoMatch/Gui/TransparentDrawingArea.cs b/LongoMatch.GUI/Gui/TransparentDrawingArea.cs
similarity index 100%
rename from LongoMatch/Gui/TransparentDrawingArea.cs
rename to LongoMatch.GUI/Gui/TransparentDrawingArea.cs
diff --git a/LongoMatch/Gui/TreeView/CategoriesTreeView.cs b/LongoMatch.GUI/Gui/TreeView/CategoriesTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/CategoriesTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/CategoriesTreeView.cs
diff --git a/LongoMatch/Gui/TreeView/ListTreeViewBase.cs b/LongoMatch.GUI/Gui/TreeView/ListTreeViewBase.cs
similarity index 98%
rename from LongoMatch/Gui/TreeView/ListTreeViewBase.cs
rename to LongoMatch.GUI/Gui/TreeView/ListTreeViewBase.cs
index f04156e..2dcfe48 100644
--- a/LongoMatch/Gui/TreeView/ListTreeViewBase.cs
+++ b/LongoMatch.GUI/Gui/TreeView/ListTreeViewBase.cs
@@ -41,8 +41,8 @@ namespace LongoMatch.Gui.Component
protected bool projectIsLive;
public event TimeNodeChangedHandler TimeNodeChanged;
- public event TimeNodeSelectedHandler TimeNodeSelected;
- public event TimeNodeDeletedHandler TimeNodeDeleted;
+ public event PlaySelectedHandler TimeNodeSelected;
+ public event PlaysDeletedHandler TimeNodeDeleted;
public event PlayListNodeAddedHandler PlayListNodeAdded;
public event SnapshotSeriesHandler SnapshotSeriesEvent;
public event TagPlayHandler TagPlay;
diff --git a/LongoMatch/Gui/TreeView/PlayListTreeView.cs b/LongoMatch.GUI/Gui/TreeView/PlayListTreeView.cs
similarity index 80%
rename from LongoMatch/Gui/TreeView/PlayListTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/PlayListTreeView.cs
index d54981c..bdedd50 100644
--- a/LongoMatch/Gui/TreeView/PlayListTreeView.cs
+++ b/LongoMatch.GUI/Gui/TreeView/PlayListTreeView.cs
@@ -22,8 +22,9 @@ using Gtk;
using Gdk;
using Mono.Unix;
using LongoMatch.Store;
-using LongoMatch.Playlist;
+using LongoMatch.Common;
using LongoMatch.Handlers;
+using LongoMatch.Interfaces;
using LongoMatch.Gui.Dialog;
namespace LongoMatch.Gui.Component
@@ -34,13 +35,14 @@ namespace LongoMatch.Gui.Component
[System.ComponentModel.ToolboxItem(true)]
public class PlayListTreeView : Gtk.TreeView
{
- private Menu menu;
- private MenuItem setRate;
- private ListStore ls;
- private PlayList playlist;
- private PlayListPlay loadedTimeNode = null; //The play currently loaded in the player
- private PlayListPlay selectedTimeNode = null; //The play selected in the tree
- private TreeIter selectedIter;
+ Menu menu;
+ MenuItem setRate;
+ ListStore ls;
+ IPlayList playlist;
+ PlayListPlay loadedPlay = null; //The play currently loaded in the player
+ PlayListPlay selectedPlay = null; //The play selected in the tree
+ TreeIter selectedIter;
+ TreePath pathIn, pathOut;
public event ApplyCurrentRateHandler ApplyCurrentRate;
@@ -75,7 +77,7 @@ namespace LongoMatch.Gui.Component
this.AppendColumn(nameColumn);
}
- public PlayList PlayList {
+ public IPlayList PlayList {
set {
this.playlist = value;
}
@@ -83,7 +85,7 @@ namespace LongoMatch.Gui.Component
public PlayListPlay LoadedPlay {
set {
- loadedTimeNode = value;
+ loadedPlay = value;
this.QueueDraw();
}
}
@@ -92,7 +94,6 @@ namespace LongoMatch.Gui.Component
{
}
-
protected override bool OnButtonPressEvent(EventButton evnt)
{
if((evnt.Type == EventType.ButtonPress) && (evnt.Button == 3))
@@ -102,8 +103,8 @@ namespace LongoMatch.Gui.Component
if(path!=null) {
ListStore list = ((ListStore)Model);
Model.GetIter(out selectedIter,path);
- selectedTimeNode = (PlayListPlay)(list.GetValue(selectedIter,0));
- setRate.Sensitive = selectedTimeNode == loadedTimeNode;
+ selectedPlay = (PlayListPlay)(list.GetValue(selectedIter,0));
+ setRate.Sensitive = selectedPlay == loadedPlay;
menu.Popup();
}
}
@@ -113,9 +114,9 @@ namespace LongoMatch.Gui.Component
protected void OnTitle(object o, EventArgs args) {
EntryDialog ed = new EntryDialog();
ed.Title = Catalog.GetString("Edit Title");
- ed.Text = selectedTimeNode.Name;
+ ed.Text = selectedPlay.Name;
if(ed.Run() == (int)ResponseType.Ok) {
- selectedTimeNode.Name = ed.Text;
+ selectedPlay.Name = ed.Text;
this.QueueDraw();
}
ed.Destroy();
@@ -123,13 +124,13 @@ namespace LongoMatch.Gui.Component
protected void OnDelete(object obj, EventArgs args) {
ListStore list = ((ListStore)Model);
- playlist.Remove(selectedTimeNode);
+ playlist.Remove(selectedPlay);
list.Remove(ref selectedIter);
}
protected void OnApplyRate(object obj, EventArgs args) {
if(ApplyCurrentRate != null)
- ApplyCurrentRate(selectedTimeNode);
+ ApplyCurrentRate(selectedPlay);
}
private void RenderName(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
@@ -143,7 +144,7 @@ namespace LongoMatch.Gui.Component
(cell as Gtk.CellRendererText).Foreground = "red";
(cell as Gtk.CellRendererText).Text += "\n"+Catalog.GetString("File not found")+": "+tNode.MediaFile.FilePath;
}
- else if(tNode == loadedTimeNode)
+ else if(tNode == loadedPlay)
(cell as Gtk.CellRendererText).Foreground = "blue";
else
(cell as Gtk.CellRendererText).Foreground = "black";
@@ -154,5 +155,18 @@ namespace LongoMatch.Gui.Component
{
return false;
}
+
+ protected override void OnDragBegin (DragContext context)
+ {
+ pathIn = Selection.GetSelectedRows()[0];
+ base.OnDragBegin (context);
+ }
+
+ protected override void OnDragEnd (DragContext context)
+ {
+ base.OnDragEnd (context);
+ pathOut = Selection.GetSelectedRows()[0];
+ playlist.Reorder(pathIn.Indices[0], pathOut.Indices[0]);
+ }
}
}
diff --git a/LongoMatch/Gui/TreeView/PlayerPropertiesTreeView.cs b/LongoMatch.GUI/Gui/TreeView/PlayerPropertiesTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/PlayerPropertiesTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/PlayerPropertiesTreeView.cs
diff --git a/LongoMatch/Gui/TreeView/PlayersTreeView.cs b/LongoMatch.GUI/Gui/TreeView/PlayersTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/PlayersTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/PlayersTreeView.cs
diff --git a/LongoMatch/Gui/TreeView/PlaysTreeView.cs b/LongoMatch.GUI/Gui/TreeView/PlaysTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/PlaysTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/PlaysTreeView.cs
diff --git a/LongoMatch/Gui/TreeView/RenderingJobsTreeView.cs b/LongoMatch.GUI/Gui/TreeView/RenderingJobsTreeView.cs
similarity index 98%
rename from LongoMatch/Gui/TreeView/RenderingJobsTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/RenderingJobsTreeView.cs
index f08f009..c5f920a 100644
--- a/LongoMatch/Gui/TreeView/RenderingJobsTreeView.cs
+++ b/LongoMatch.GUI/Gui/TreeView/RenderingJobsTreeView.cs
@@ -20,8 +20,8 @@ using System.Collections.Generic;
using Gtk;
using Stetic;
using Mono.Unix;
+using LongoMatch.Common;
-using LongoMatch.Services.JobsManager;
namespace LongoMatch.Gui.Component
{
diff --git a/LongoMatch/Gui/TreeView/SubCategoriesTreeView.cs b/LongoMatch.GUI/Gui/TreeView/SubCategoriesTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/SubCategoriesTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/SubCategoriesTreeView.cs
diff --git a/LongoMatch/Gui/TreeView/TagsTreeView.cs b/LongoMatch.GUI/Gui/TreeView/TagsTreeView.cs
similarity index 100%
rename from LongoMatch/Gui/TreeView/TagsTreeView.cs
rename to LongoMatch.GUI/Gui/TreeView/TagsTreeView.cs
diff --git a/LongoMatch.GUI/LongoMatch.GUI.mdp b/LongoMatch.GUI/LongoMatch.GUI.mdp
new file mode 100644
index 0000000..582d83b
--- /dev/null
+++ b/LongoMatch.GUI/LongoMatch.GUI.mdp
@@ -0,0 +1,157 @@
+<Project name="LongoMatch.GUI" fileversion="2.0" DefaultNamespace="LongoMatch" language="C#" clr-version="Net_2_0" targetFramework="3.5" ctype="DotNetProject">
+ <Deployment.LinuxDeployData />
+ <MonoDevelop.Autotools.MakefileInfo RelativeMakefileName="../CesarPlayer/Makefile.am" RelativeConfigureInPath="../">
+ <BuildFilesVar Name="FILES" />
+ <DeployFilesVar />
+ <ResourcesVar Name="RESOURCES" />
+ <OthersVar />
+ <GacRefVar Name="REFERENCES" />
+ <AsmRefVar Name="REFERENCES" />
+ <ProjectRefVar Name="REFERENCES" />
+ </MonoDevelop.Autotools.MakefileInfo>
+ <Configurations active="Release">
+ <Configuration name="Debug" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Gui" assemblyKeyFile="/home/andoni/Proyectos/longomatch/LongoMatch/." />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="True" unsafecodeallowed="False" generateoverflowchecks="True" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ <Configuration name="Release" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Gui" assemblyKeyFile="/home/andoni/Proyectos/LongoMatch/LongoMatch.GUI/." />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
+ <CodeGeneration compiler="Mcs" warninglevel="3" optimize="True" unsafecodeallowed="False" generateoverflowchecks="True" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ </Configurations>
+ <Contents>
+ <File subtype="Directory" buildaction="Compile" name="Gui" />
+ <File subtype="Code" buildaction="Compile" name="Gui/MainWindow.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TransparentDrawingArea.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Gui/Dialog" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EditPlayerDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EditCategoryDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EntryDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/NewProjectDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/OpenProjectDialog.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Gui/Component" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/ProjectDetailsWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/ButtonsWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/DrawingToolBox.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/NotesWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/FramesCaptureProgressDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/HotKeySelectorDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayerProperties.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Gui/TreeView" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayersTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayerPropertiesTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayListTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlaysTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/PlayersSelectionDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/SnapshotsDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/UpdateDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/Win32CalendarDialog.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Gui/Popup" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Popup/CalendarPopup.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Popup/MessagePopup.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TemplateEditorDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayersListTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/ProjectsManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayListWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/ProjectListWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TemplatesManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TemplatesEditorBase.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/CategoriesTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeLineWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeScale.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/VideoEditionProperties.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeReferenceWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoryProperties.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/PlaysListTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/DrawingWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/DrawingTool.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TaggerDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/TagsTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TagsTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/ProjectSelectionDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EndCaptureDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/BusyDialog.cs" />
+ <File subtype="Code" buildaction="EmbedAsResource" name="gtk-gui/gui.stetic" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/generated.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.MainWindow.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/ListTreeViewBase.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoriesScale.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/SubCategoriesTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/SubCategoryTagsEditor.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayersTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/StringTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TeamTaggerWidget.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoriesTemplateEditor.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/TeamTemplateEditor.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Component/RenderingStateBar.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/TreeView/RenderingJobsTreeView.cs" />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/RenderingJobsDialog.cs" />
+ <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs" />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Code" buildaction="Compile" name="Gui/Dialog/About.cs" />
+ </Contents>
+ <References>
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Cairo, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Gac" localcopy="True" refto="atk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="glib-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="pango-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.GUI.Multimedia" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Multimedia" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Core" />
+ </References>
+ <LanguageParameters ApplicationIcon="." CodePage="65001" ctype="CSharpProjectParameters" />
+</Project>
\ No newline at end of file
diff --git a/LongoMatch.GUI/Makefile.am b/LongoMatch.GUI/Makefile.am
new file mode 100644
index 0000000..17fff7f
--- /dev/null
+++ b/LongoMatch.GUI/Makefile.am
@@ -0,0 +1,125 @@
+ASSEMBLY = LongoMatch.GUI
+TARGET = library
+
+LINK = $(REF_DEP_LONGOMATCH_GUI)
+
+SOURCES = \
+ gtk-gui/generated.cs \
+ gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs \
+ gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs \
+ gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs \
+ gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs \
+ gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs \
+ gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs \
+ gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs \
+ gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs \
+ gtk-gui/LongoMatch.Gui.MainWindow.cs \
+ gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs \
+ gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs \
+ Gui/Component/ButtonsWidget.cs \
+ Gui/Component/CategoriesScale.cs \
+ Gui/Component/CategoriesTemplateEditor.cs \
+ Gui/Component/CategoryProperties.cs \
+ Gui/Component/DrawingToolBox.cs \
+ Gui/Component/DrawingWidget.cs \
+ Gui/Component/NotesWidget.cs \
+ Gui/Component/PlayerProperties.cs \
+ Gui/Component/PlayersListTreeWidget.cs \
+ Gui/Component/PlayersTaggerWidget.cs \
+ Gui/Component/PlayListWidget.cs \
+ Gui/Component/PlaysListTreeWidget.cs \
+ Gui/Component/ProjectDetailsWidget.cs \
+ Gui/Component/ProjectListWidget.cs \
+ Gui/Component/RenderingStateBar.cs \
+ Gui/Component/StringTaggerWidget.cs \
+ Gui/Component/TaggerWidget.cs \
+ Gui/Component/TagsTreeWidget.cs \
+ Gui/Component/TeamTaggerWidget.cs \
+ Gui/Component/TeamTemplateEditor.cs \
+ Gui/Component/TemplatesEditorBase.cs \
+ Gui/Component/TimeLineWidget.cs \
+ Gui/Component/TimeReferenceWidget.cs \
+ Gui/Component/TimeScale.cs \
+ Gui/Dialog/About.cs \
+ Gui/Dialog/BusyDialog.cs \
+ Gui/Dialog/DrawingTool.cs \
+ Gui/Dialog/EditCategoryDialog.cs \
+ Gui/Dialog/EditPlayerDialog.cs \
+ Gui/Dialog/EndCaptureDialog.cs \
+ Gui/Dialog/EntryDialog.cs \
+ Gui/Dialog/FramesCaptureProgressDialog.cs \
+ Gui/Dialog/HotKeySelectorDialog.cs \
+ Gui/Dialog/NewProjectDialog.cs \
+ Gui/Dialog/OpenProjectDialog.cs \
+ Gui/Dialog/PlayersSelectionDialog.cs \
+ Gui/Dialog/ProjectSelectionDialog.cs \
+ Gui/Dialog/ProjectsManager.cs \
+ Gui/Dialog/RenderingJobsDialog.cs \
+ Gui/Dialog/SnapshotsDialog.cs \
+ Gui/Dialog/SubCategoryTagsEditor.cs \
+ Gui/Dialog/TaggerDialog.cs \
+ Gui/Dialog/TemplateEditorDialog.cs \
+ Gui/Dialog/TemplatesManager.cs \
+ Gui/Dialog/UpdateDialog.cs \
+ Gui/Dialog/VideoEditionProperties.cs \
+ Gui/Dialog/Win32CalendarDialog.cs \
+ Gui/MainWindow.cs \
+ Gui/Popup/CalendarPopup.cs \
+ Gui/Popup/MessagePopup.cs \
+ Gui/TransparentDrawingArea.cs \
+ Gui/TreeView/CategoriesTreeView.cs \
+ Gui/TreeView/ListTreeViewBase.cs \
+ Gui/TreeView/PlayerPropertiesTreeView.cs \
+ Gui/TreeView/PlayersTreeView.cs \
+ Gui/TreeView/PlayListTreeView.cs \
+ Gui/TreeView/PlaysTreeView.cs \
+ Gui/TreeView/RenderingJobsTreeView.cs \
+ Gui/TreeView/SubCategoriesTreeView.cs \
+ Gui/TreeView/TagsTreeView.cs
+
+RESOURCES = \
+ $(top_srcdir)/images/longomatch.png\
+ $(top_srcdir)/images/stock_draw-line-45.png\
+ $(top_srcdir)/images/stock_draw-circle-unfilled.png\
+ $(top_srcdir)/images/stock_draw-line-ends-with-arrow.png\
+ $(top_srcdir)/images/stock_draw-rectangle-unfilled.png\
+ $(top_srcdir)/images/stock_draw-freeform-line.png\
+ $(top_srcdir)/images/camera-video.png\
+ $(top_srcdir)/images/video.png \
+ gtk-gui/objects.xml \
+ gtk-gui/gui.stetic
+
+include $(top_srcdir)/build/build.mk
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs
similarity index 98%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs
index a467a89..16e9996 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs
@@ -176,7 +176,6 @@ namespace LongoMatch.Gui.Component
this.Child.ShowAll ();
}
this.Show ();
- this.playlisttreeview1.DragEnd += new global::Gtk.DragEndHandler (this.OnPlaylisttreeview1DragEnd);
this.newbutton.Clicked += new global::System.EventHandler (this.OnNewbuttonClicked);
this.openbutton.Clicked += new global::System.EventHandler (this.OnOpenbuttonClicked);
this.savebutton.Clicked += new global::System.EventHandler (this.OnSavebuttonClicked);
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.MainWindow.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.MainWindow.cs
similarity index 71%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.MainWindow.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.MainWindow.cs
index 374a93a..ec0cd18 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.MainWindow.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.MainWindow.cs
@@ -10,7 +10,7 @@ namespace LongoMatch.Gui
private global::Gtk.Action NewPojectAction;
- private global::Gtk.Action OpenProjectAction;
+ private global::Gtk.Action openAction;
private global::Gtk.Action QuitAction;
@@ -64,19 +64,19 @@ namespace LongoMatch.Gui
private global::Gtk.Notebook notebook1;
- private global::LongoMatch.Gui.Component.PlaysListTreeWidget treewidget1;
+ private global::LongoMatch.Gui.Component.PlaysListTreeWidget playsList;
private global::Gtk.Label playslabel;
- private global::LongoMatch.Gui.Component.PlayersListTreeWidget localplayerslisttreewidget;
+ private global::LongoMatch.Gui.Component.PlayersListTreeWidget localPlayersList;
private global::Gtk.Label localteamlabel;
- private global::LongoMatch.Gui.Component.PlayersListTreeWidget visitorplayerslisttreewidget;
+ private global::LongoMatch.Gui.Component.PlayersListTreeWidget visitorPlayersList;
private global::Gtk.Label visitorteamlabel;
- private global::LongoMatch.Gui.Component.TagsTreeWidget tagstreewidget1;
+ private global::LongoMatch.Gui.Component.TagsTreeWidget tagsList;
private global::Gtk.Label tagslabel;
@@ -88,19 +88,19 @@ namespace LongoMatch.Gui
private global::LongoMatch.Gui.Component.DrawingToolBox drawingtoolbox1;
- private global::LongoMatch.Gui.PlayerBin playerbin1;
+ private global::LongoMatch.Gui.PlayerBin player;
- private global::LongoMatch.Gui.CapturerBin capturerBin;
+ private global::LongoMatch.Gui.CapturerBin capturer;
- private global::LongoMatch.Gui.Component.TimeLineWidget timelinewidget1;
+ private global::LongoMatch.Gui.Component.TimeLineWidget timeline;
- private global::LongoMatch.Gui.Component.ButtonsWidget buttonswidget1;
+ private global::LongoMatch.Gui.Component.ButtonsWidget buttonswidget;
private global::Gtk.VBox rightvbox;
- private global::LongoMatch.Gui.Component.NotesWidget noteswidget1;
+ private global::LongoMatch.Gui.Component.NotesWidget notes;
- private global::LongoMatch.Gui.Component.PlayListWidget playlistwidget2;
+ private global::LongoMatch.Gui.Component.PlayListWidget playlist;
private global::Gtk.Statusbar statusbar1;
@@ -118,9 +118,9 @@ namespace LongoMatch.Gui
this.NewPojectAction = new global::Gtk.Action ("NewPojectAction", global::Mono.Unix.Catalog.GetString ("_New Project"), null, "gtk-new");
this.NewPojectAction.ShortLabel = global::Mono.Unix.Catalog.GetString ("_New Project");
w1.Add (this.NewPojectAction, null);
- this.OpenProjectAction = new global::Gtk.Action ("OpenProjectAction", global::Mono.Unix.Catalog.GetString ("_Open Project"), null, "gtk-open");
- this.OpenProjectAction.ShortLabel = global::Mono.Unix.Catalog.GetString ("_Open Project");
- w1.Add (this.OpenProjectAction, null);
+ this.openAction = new global::Gtk.Action ("openAction", global::Mono.Unix.Catalog.GetString ("_Open Project"), null, "gtk-open");
+ this.openAction.ShortLabel = global::Mono.Unix.Catalog.GetString ("_Open Project");
+ w1.Add (this.openAction, null);
this.QuitAction = new global::Gtk.Action ("QuitAction", global::Mono.Unix.Catalog.GetString ("_Quit"), null, "gtk-quit");
this.QuitAction.ShortLabel = global::Mono.Unix.Catalog.GetString ("_Quit");
w1.Add (this.QuitAction, null);
@@ -208,7 +208,7 @@ namespace LongoMatch.Gui
this.menubox.Name = "menubox";
this.menubox.Spacing = 6;
// Container child menubox.Gtk.Box+BoxChild
- this.UIManager.AddUiFromString ("<ui><menubar name='menubar1'><menu name='FileAction' action='FileAction'><menuitem name='NewPojectAction' action='NewPojectAction'/><menuitem name='OpenProjectAction' action='OpenProjectAction'/><menuitem name='SaveProjectAction' action='SaveProjectAction'/><menuitem name='CloseProjectAction' action='CloseProjectAction'/><separator/><menuitem name='ImportProjectAction' action='ImportProjectAction'/><separator/><menuitem name='QuitAction' action='QuitAction'/></menu><menu name='ToolsAction' action='ToolsAction'><menuitem name='ProjectsManagerAction' action='ProjectsManagerAction'/><menuitem name='CategoriesTemplatesManagerAction' action='CategoriesTemplatesManagerAction'/><menuitem name='TeamsTemplatesManagerAction' action='TeamsTemplatesManagerAction'/><menuitem name='ExportProjectToCSVFileAction' action='ExportProjectToCSVFileAction'/></menu><menu name='ViewAction' action='ViewAction'><menuitem name='FullScreenAction' action='FullScreenAc
tion'/><menuitem name='HideAllWidgetsAction' action='HideAllWidgetsAction'/><separator/><menuitem name='PlaylistAction' action='PlaylistAction'/><separator/><menuitem name='TaggingViewAction' action='TaggingViewAction'/><menuitem name='ManualTaggingViewAction' action='ManualTaggingViewAction'/><menuitem name='TimelineViewAction' action='TimelineViewAction'/></menu><menu name='HelpAction' action='HelpAction'><menuitem name='AboutAction' action='AboutAction'/><menuitem name='HelpAction1' action='HelpAction1'/></menu></menubar></ui>");
+ this.UIManager.AddUiFromString ("<ui><menubar name='menubar1'><menu name='FileAction' action='FileAction'><menuitem name='NewPojectAction' action='NewPojectAction'/><menuitem name='openAction' action='openAction'/><menuitem name='SaveProjectAction' action='SaveProjectAction'/><menuitem name='CloseProjectAction' action='CloseProjectAction'/><separator/><menuitem name='ImportProjectAction' action='ImportProjectAction'/><separator/><menuitem name='QuitAction' action='QuitAction'/></menu><menu name='ToolsAction' action='ToolsAction'><menuitem name='ProjectsManagerAction' action='ProjectsManagerAction'/><menuitem name='CategoriesTemplatesManagerAction' action='CategoriesTemplatesManagerAction'/><menuitem name='TeamsTemplatesManagerAction' action='TeamsTemplatesManagerAction'/><menuitem name='ExportProjectToCSVFileAction' action='ExportProjectToCSVFileAction'/></menu><menu name='ViewAction' action='ViewAction'><menuitem name='FullScreenAction' action='FullScreenAction'/><menuit
em name='HideAllWidgetsAction' action='HideAllWidgetsAction'/><separator/><menuitem name='PlaylistAction' action='PlaylistAction'/><separator/><menuitem name='TaggingViewAction' action='TaggingViewAction'/><menuitem name='ManualTaggingViewAction' action='ManualTaggingViewAction'/><menuitem name='TimelineViewAction' action='TimelineViewAction'/></menu><menu name='HelpAction' action='HelpAction'><menuitem name='AboutAction' action='AboutAction'/><menuitem name='HelpAction1' action='HelpAction1'/></menu></menubar></ui>");
this.menubar1 = ((global::Gtk.MenuBar)(this.UIManager.GetWidget ("/menubar1")));
this.menubar1.Name = "menubar1";
this.menubox.Add (this.menubar1);
@@ -237,55 +237,55 @@ namespace LongoMatch.Gui
this.notebook1.CurrentPage = 3;
this.notebook1.TabPos = ((global::Gtk.PositionType)(3));
// Container child notebook1.Gtk.Notebook+NotebookChild
- this.treewidget1 = new global::LongoMatch.Gui.Component.PlaysListTreeWidget ();
- this.treewidget1.Events = ((global::Gdk.EventMask)(256));
- this.treewidget1.Name = "treewidget1";
- this.notebook1.Add (this.treewidget1);
+ this.playsList = new global::LongoMatch.Gui.Component.PlaysListTreeWidget ();
+ this.playsList.Events = ((global::Gdk.EventMask)(256));
+ this.playsList.Name = "playsList";
+ this.notebook1.Add (this.playsList);
// Notebook tab
this.playslabel = new global::Gtk.Label ();
this.playslabel.Name = "playslabel";
this.playslabel.LabelProp = global::Mono.Unix.Catalog.GetString ("Plays");
- this.notebook1.SetTabLabel (this.treewidget1, this.playslabel);
+ this.notebook1.SetTabLabel (this.playsList, this.playslabel);
this.playslabel.ShowAll ();
// Container child notebook1.Gtk.Notebook+NotebookChild
- this.localplayerslisttreewidget = new global::LongoMatch.Gui.Component.PlayersListTreeWidget ();
- this.localplayerslisttreewidget.Events = ((global::Gdk.EventMask)(256));
- this.localplayerslisttreewidget.Name = "localplayerslisttreewidget";
- this.notebook1.Add (this.localplayerslisttreewidget);
- global::Gtk.Notebook.NotebookChild w5 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.localplayerslisttreewidget]));
+ this.localPlayersList = new global::LongoMatch.Gui.Component.PlayersListTreeWidget ();
+ this.localPlayersList.Events = ((global::Gdk.EventMask)(256));
+ this.localPlayersList.Name = "localPlayersList";
+ this.notebook1.Add (this.localPlayersList);
+ global::Gtk.Notebook.NotebookChild w5 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.localPlayersList]));
w5.Position = 1;
// Notebook tab
this.localteamlabel = new global::Gtk.Label ();
this.localteamlabel.Name = "localteamlabel";
this.localteamlabel.LabelProp = global::Mono.Unix.Catalog.GetString ("Local Team");
- this.notebook1.SetTabLabel (this.localplayerslisttreewidget, this.localteamlabel);
+ this.notebook1.SetTabLabel (this.localPlayersList, this.localteamlabel);
this.localteamlabel.ShowAll ();
// Container child notebook1.Gtk.Notebook+NotebookChild
- this.visitorplayerslisttreewidget = new global::LongoMatch.Gui.Component.PlayersListTreeWidget ();
- this.visitorplayerslisttreewidget.Events = ((global::Gdk.EventMask)(256));
- this.visitorplayerslisttreewidget.Name = "visitorplayerslisttreewidget";
- this.notebook1.Add (this.visitorplayerslisttreewidget);
- global::Gtk.Notebook.NotebookChild w6 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.visitorplayerslisttreewidget]));
+ this.visitorPlayersList = new global::LongoMatch.Gui.Component.PlayersListTreeWidget ();
+ this.visitorPlayersList.Events = ((global::Gdk.EventMask)(256));
+ this.visitorPlayersList.Name = "visitorPlayersList";
+ this.notebook1.Add (this.visitorPlayersList);
+ global::Gtk.Notebook.NotebookChild w6 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.visitorPlayersList]));
w6.Position = 2;
// Notebook tab
this.visitorteamlabel = new global::Gtk.Label ();
this.visitorteamlabel.Name = "visitorteamlabel";
this.visitorteamlabel.LabelProp = global::Mono.Unix.Catalog.GetString ("Visitor Team");
- this.notebook1.SetTabLabel (this.visitorplayerslisttreewidget, this.visitorteamlabel);
+ this.notebook1.SetTabLabel (this.visitorPlayersList, this.visitorteamlabel);
this.visitorteamlabel.ShowAll ();
// Container child notebook1.Gtk.Notebook+NotebookChild
- this.tagstreewidget1 = new global::LongoMatch.Gui.Component.TagsTreeWidget ();
- this.tagstreewidget1.Sensitive = false;
- this.tagstreewidget1.Events = ((global::Gdk.EventMask)(256));
- this.tagstreewidget1.Name = "tagstreewidget1";
- this.notebook1.Add (this.tagstreewidget1);
- global::Gtk.Notebook.NotebookChild w7 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.tagstreewidget1]));
+ this.tagsList = new global::LongoMatch.Gui.Component.TagsTreeWidget ();
+ this.tagsList.Sensitive = false;
+ this.tagsList.Events = ((global::Gdk.EventMask)(256));
+ this.tagsList.Name = "tagsList";
+ this.notebook1.Add (this.tagsList);
+ global::Gtk.Notebook.NotebookChild w7 = ((global::Gtk.Notebook.NotebookChild)(this.notebook1[this.tagsList]));
w7.Position = 3;
// Notebook tab
this.tagslabel = new global::Gtk.Label ();
this.tagslabel.Name = "tagslabel";
this.tagslabel.LabelProp = global::Mono.Unix.Catalog.GetString ("Tags");
- this.notebook1.SetTabLabel (this.tagstreewidget1, this.tagslabel);
+ this.notebook1.SetTabLabel (this.tagsList, this.tagslabel);
this.tagslabel.ShowAll ();
this.leftbox.Add (this.notebook1);
global::Gtk.Box.BoxChild w8 = ((global::Gtk.Box.BoxChild)(this.leftbox[this.notebook1]));
@@ -316,40 +316,40 @@ namespace LongoMatch.Gui
w10.Expand = false;
w10.Fill = false;
// Container child videowidgetsbox.Gtk.Box+BoxChild
- this.playerbin1 = new global::LongoMatch.Gui.PlayerBin ();
- this.playerbin1.Events = ((global::Gdk.EventMask)(256));
- this.playerbin1.Name = "playerbin1";
- this.playerbin1.Rate = 1f;
- this.playerbin1.ExpandLogo = true;
- this.videowidgetsbox.Add (this.playerbin1);
- global::Gtk.Box.BoxChild w11 = ((global::Gtk.Box.BoxChild)(this.videowidgetsbox[this.playerbin1]));
+ this.player = new global::LongoMatch.Gui.PlayerBin ();
+ this.player.Events = ((global::Gdk.EventMask)(256));
+ this.player.Name = "player";
+ this.player.Rate = 1f;
+ this.player.ExpandLogo = true;
+ this.videowidgetsbox.Add (this.player);
+ global::Gtk.Box.BoxChild w11 = ((global::Gtk.Box.BoxChild)(this.videowidgetsbox[this.player]));
w11.Position = 1;
// Container child videowidgetsbox.Gtk.Box+BoxChild
- this.capturerBin = new global::LongoMatch.Gui.CapturerBin ();
- this.capturerBin.Events = ((global::Gdk.EventMask)(256));
- this.capturerBin.Name = "capturerBin";
- this.videowidgetsbox.Add (this.capturerBin);
- global::Gtk.Box.BoxChild w12 = ((global::Gtk.Box.BoxChild)(this.videowidgetsbox[this.capturerBin]));
+ this.capturer = new global::LongoMatch.Gui.CapturerBin ();
+ this.capturer.Events = ((global::Gdk.EventMask)(256));
+ this.capturer.Name = "capturer";
+ this.videowidgetsbox.Add (this.capturer);
+ global::Gtk.Box.BoxChild w12 = ((global::Gtk.Box.BoxChild)(this.videowidgetsbox[this.capturer]));
w12.Position = 2;
this.vbox5.Add (this.videowidgetsbox);
global::Gtk.Box.BoxChild w13 = ((global::Gtk.Box.BoxChild)(this.vbox5[this.videowidgetsbox]));
w13.Position = 0;
// Container child vbox5.Gtk.Box+BoxChild
- this.timelinewidget1 = new global::LongoMatch.Gui.Component.TimeLineWidget ();
- this.timelinewidget1.HeightRequest = 200;
- this.timelinewidget1.Events = ((global::Gdk.EventMask)(256));
- this.timelinewidget1.Name = "timelinewidget1";
- this.timelinewidget1.CurrentFrame = ((uint)(0));
- this.vbox5.Add (this.timelinewidget1);
- global::Gtk.Box.BoxChild w14 = ((global::Gtk.Box.BoxChild)(this.vbox5[this.timelinewidget1]));
+ this.timeline = new global::LongoMatch.Gui.Component.TimeLineWidget ();
+ this.timeline.HeightRequest = 200;
+ this.timeline.Events = ((global::Gdk.EventMask)(256));
+ this.timeline.Name = "timeline";
+ this.timeline.CurrentFrame = ((uint)(0));
+ this.vbox5.Add (this.timeline);
+ global::Gtk.Box.BoxChild w14 = ((global::Gtk.Box.BoxChild)(this.vbox5[this.timeline]));
w14.Position = 1;
w14.Expand = false;
// Container child vbox5.Gtk.Box+BoxChild
- this.buttonswidget1 = new global::LongoMatch.Gui.Component.ButtonsWidget ();
- this.buttonswidget1.Events = ((global::Gdk.EventMask)(256));
- this.buttonswidget1.Name = "buttonswidget1";
- this.vbox5.Add (this.buttonswidget1);
- global::Gtk.Box.BoxChild w15 = ((global::Gtk.Box.BoxChild)(this.vbox5[this.buttonswidget1]));
+ this.buttonswidget = new global::LongoMatch.Gui.Component.ButtonsWidget ();
+ this.buttonswidget.Events = ((global::Gdk.EventMask)(256));
+ this.buttonswidget.Name = "buttonswidget";
+ this.vbox5.Add (this.buttonswidget);
+ global::Gtk.Box.BoxChild w15 = ((global::Gtk.Box.BoxChild)(this.vbox5[this.buttonswidget]));
w15.Position = 2;
w15.Expand = false;
this.hpaned1.Add (this.vbox5);
@@ -362,19 +362,19 @@ namespace LongoMatch.Gui
this.rightvbox.Name = "rightvbox";
this.rightvbox.Spacing = 6;
// Container child rightvbox.Gtk.Box+BoxChild
- this.noteswidget1 = new global::LongoMatch.Gui.Component.NotesWidget ();
- this.noteswidget1.Events = ((global::Gdk.EventMask)(256));
- this.noteswidget1.Name = "noteswidget1";
- this.rightvbox.Add (this.noteswidget1);
- global::Gtk.Box.BoxChild w17 = ((global::Gtk.Box.BoxChild)(this.rightvbox[this.noteswidget1]));
+ this.notes = new global::LongoMatch.Gui.Component.NotesWidget ();
+ this.notes.Events = ((global::Gdk.EventMask)(256));
+ this.notes.Name = "notes";
+ this.rightvbox.Add (this.notes);
+ global::Gtk.Box.BoxChild w17 = ((global::Gtk.Box.BoxChild)(this.rightvbox[this.notes]));
w17.Position = 0;
// Container child rightvbox.Gtk.Box+BoxChild
- this.playlistwidget2 = new global::LongoMatch.Gui.Component.PlayListWidget ();
- this.playlistwidget2.WidthRequest = 100;
- this.playlistwidget2.Events = ((global::Gdk.EventMask)(256));
- this.playlistwidget2.Name = "playlistwidget2";
- this.rightvbox.Add (this.playlistwidget2);
- global::Gtk.Box.BoxChild w18 = ((global::Gtk.Box.BoxChild)(this.rightvbox[this.playlistwidget2]));
+ this.playlist = new global::LongoMatch.Gui.Component.PlayListWidget ();
+ this.playlist.WidthRequest = 100;
+ this.playlist.Events = ((global::Gdk.EventMask)(256));
+ this.playlist.Name = "playlist";
+ this.rightvbox.Add (this.playlist);
+ global::Gtk.Box.BoxChild w18 = ((global::Gtk.Box.BoxChild)(this.rightvbox[this.playlist]));
w18.Position = 1;
this.hpaned1.Add (this.rightvbox);
global::Gtk.Paned.PanedChild w19 = ((global::Gtk.Paned.PanedChild)(this.hpaned1[this.rightvbox]));
@@ -414,35 +414,27 @@ namespace LongoMatch.Gui
this.DefaultHeight = 853;
this.leftbox.Hide ();
this.drawingtoolbox1.Hide ();
- this.timelinewidget1.Hide ();
- this.buttonswidget1.Hide ();
- this.noteswidget1.Hide ();
- this.playlistwidget2.Hide ();
+ this.timeline.Hide ();
+ this.buttonswidget.Hide ();
+ this.notes.Hide ();
+ this.playlist.Hide ();
this.rightvbox.Hide ();
this.renderingstatebar1.Hide ();
this.Show ();
this.NewPojectAction.Activated += new global::System.EventHandler (this.OnNewActivated);
- this.OpenProjectAction.Activated += new global::System.EventHandler (this.OnOpenActivated);
- this.QuitAction.Activated += new global::System.EventHandler (this.OnQuitActivated);
- this.CloseProjectAction.Activated += new global::System.EventHandler (this.OnCloseActivated);
- this.ProjectsManagerAction.Activated += new global::System.EventHandler (this.OnDatabaseManagerActivated);
- this.CategoriesTemplatesManagerAction.Activated += new global::System.EventHandler (this.OnSectionsTemplatesManagerActivated);
+ this.openAction.Activated += new global::System.EventHandler (this.OnOpenActivated);
this.FullScreenAction.Toggled += new global::System.EventHandler (this.OnFullScreenActionToggled);
this.PlaylistAction.Toggled += new global::System.EventHandler (this.OnPlaylistActionToggled);
this.TaggingViewAction.Toggled += new global::System.EventHandler (this.OnViewToggled);
- this.SaveProjectAction.Activated += new global::System.EventHandler (this.OnSaveProjectActionActivated);
this.AboutAction.Activated += new global::System.EventHandler (this.OnAboutActionActivated);
- this.ExportProjectToCSVFileAction.Activated += new global::System.EventHandler (this.OnExportProjectToCSVFileActionActivated);
- this.TeamsTemplatesManagerAction.Activated += new global::System.EventHandler (this.OnTeamsTemplatesManagerActionActivated);
this.HideAllWidgetsAction.Toggled += new global::System.EventHandler (this.OnHideAllWidgetsActionToggled);
this.HelpAction1.Activated += new global::System.EventHandler (this.OnHelpAction1Activated);
this.DrawingToolAction.Toggled += new global::System.EventHandler (this.OnDrawingToolActionToggled);
- this.ImportProjectAction.Activated += new global::System.EventHandler (this.OnImportProjectActionActivated);
this.ManualTaggingViewAction.Toggled += new global::System.EventHandler (this.OnViewToggled);
- this.treewidget1.TimeNodeSelected += new global::LongoMatch.Handlers.TimeNodeSelectedHandler (this.OnTimeNodeSelected);
- this.playerbin1.Error += new global::LongoMatch.Video.Common.ErrorHandler (this.OnPlayerbin1Error);
- this.playerbin1.SegmentClosedEvent += new global::LongoMatch.Video.Common.SegmentClosedHandler (this.OnSegmentClosedEvent);
- this.capturerBin.Error += new global::LongoMatch.Video.Common.ErrorHandler (this.OnCapturerBinError);
+ this.playsList.TimeNodeSelected += new global::LongoMatch.Handlers.PlaySelectedHandler (this.OnTimeNodeSelected);
+ this.player.Error += new global::LongoMatch.Video.Common.ErrorHandler (this.OnPlayerbin1Error);
+ this.player.SegmentClosedEvent += new global::LongoMatch.Video.Common.SegmentClosedHandler (this.OnSegmentClosedEvent);
+ this.capturer.Error += new global::LongoMatch.Video.Common.ErrorHandler (this.OnCapturerBinError);
}
}
}
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs
similarity index 100%
rename from LongoMatch/gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs
rename to LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs
diff --git a/LongoMatch/gtk-gui/generated.cs b/LongoMatch.GUI/gtk-gui/generated.cs
similarity index 100%
rename from LongoMatch/gtk-gui/generated.cs
rename to LongoMatch.GUI/gtk-gui/generated.cs
diff --git a/LongoMatch/gtk-gui/gui.stetic b/LongoMatch.GUI/gtk-gui/gui.stetic
similarity index 99%
rename from LongoMatch/gtk-gui/gui.stetic
rename to LongoMatch.GUI/gtk-gui/gui.stetic
index 6fa8b38..b517c3d 100644
--- a/LongoMatch/gtk-gui/gui.stetic
+++ b/LongoMatch.GUI/gtk-gui/gui.stetic
@@ -5,8 +5,10 @@
<target-gtk-version>2.12</target-gtk-version>
</configuration>
<import>
- <widget-library name="../../bin/CesarPlayer.dll" />
- <widget-library name="../../bin/LongoMatch.exe" internal="true" />
+ <widget-library name="../../bin/a.dll" />
+ <widget-library name="../../bin/LongoMatch.Multimedia.dll" />
+ <widget-library name="../../bin/LongoMatch.Core.dll" />
+ <widget-library name="../../bin/LongoMatch.Gui.dll" internal="true" />
</import>
<icon-factory>
<icon-set id="longomatch">
@@ -1578,7 +1580,7 @@
<property name="StockId">gtk-new</property>
<signal name="Activated" handler="OnNewActivated" />
</action>
- <action id="OpenProjectAction">
+ <action id="openAction">
<property name="Type">Action</property>
<property name="Label" translatable="yes">_Open Project</property>
<property name="ShortLabel" translatable="yes">_Open Project</property>
@@ -1590,7 +1592,6 @@
<property name="Label" translatable="yes">_Quit</property>
<property name="ShortLabel" translatable="yes">_Quit</property>
<property name="StockId">gtk-quit</property>
- <signal name="Activated" handler="OnQuitActivated" />
</action>
<action id="CloseProjectAction">
<property name="Type">Action</property>
@@ -1598,7 +1599,6 @@
<property name="Sensitive">False</property>
<property name="ShortLabel" translatable="yes">_Close Project</property>
<property name="StockId">gtk-close</property>
- <signal name="Activated" handler="OnCloseActivated" />
</action>
<action id="ToolsAction">
<property name="Type">Action</property>
@@ -1609,13 +1609,11 @@
<property name="Type">Action</property>
<property name="Label" translatable="yes">Projects Manager</property>
<property name="ShortLabel" translatable="yes">Database Manager</property>
- <signal name="Activated" handler="OnDatabaseManagerActivated" />
</action>
<action id="CategoriesTemplatesManagerAction">
<property name="Type">Action</property>
<property name="Label" translatable="yes">Categories Templates Manager</property>
<property name="ShortLabel" translatable="yes">Templates Manager</property>
- <signal name="Activated" handler="OnSectionsTemplatesManagerActivated" />
</action>
<action id="ViewAction">
<property name="Type">Action</property>
@@ -1671,7 +1669,6 @@
<property name="Sensitive">False</property>
<property name="ShortLabel" translatable="yes">_Save Project</property>
<property name="StockId">gtk-save</property>
- <signal name="Activated" handler="OnSaveProjectActionActivated" />
</action>
<action id="HelpAction">
<property name="Type">Action</property>
@@ -1691,13 +1688,11 @@
<property name="Sensitive">False</property>
<property name="ShortLabel" translatable="yes">Export Project To CSV File</property>
<property name="Visible">False</property>
- <signal name="Activated" handler="OnExportProjectToCSVFileActionActivated" />
</action>
<action id="TeamsTemplatesManagerAction">
<property name="Type">Action</property>
<property name="Label" translatable="yes">Teams Templates Manager</property>
<property name="ShortLabel" translatable="yes">Teams Templates Manager</property>
- <signal name="Activated" handler="OnTeamsTemplatesManagerActionActivated" />
</action>
<action id="HideAllWidgetsAction">
<property name="Type">Toggle</property>
@@ -1730,7 +1725,6 @@
<property name="Label" translatable="yes">_Import Project</property>
<property name="ShortLabel" translatable="yes">_Import Project</property>
<property name="StockId">stock-import</property>
- <signal name="Activated" handler="OnImportProjectActionActivated" />
</action>
<action id="ManualTaggingViewAction">
<property name="Type">Radio</property>
@@ -1764,7 +1758,7 @@
<node name="menubar1" type="Menubar">
<node type="Menu" action="FileAction">
<node type="Menuitem" action="NewPojectAction" />
- <node type="Menuitem" action="OpenProjectAction" />
+ <node type="Menuitem" action="openAction" />
<node type="Menuitem" action="SaveProjectAction" />
<node type="Menuitem" action="CloseProjectAction" />
<node type="Separator" />
@@ -1826,7 +1820,7 @@
<property name="CurrentPage">3</property>
<property name="TabPos">Bottom</property>
<child>
- <widget class="LongoMatch.Gui.Component.PlaysListTreeWidget" id="treewidget1">
+ <widget class="LongoMatch.Gui.Component.PlaysListTreeWidget" id="playsList">
<property name="MemberName" />
<property name="Events">ButtonPressMask</property>
<signal name="TimeNodeSelected" handler="OnTimeNodeSelected" />
@@ -1842,7 +1836,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.PlayersListTreeWidget" id="localplayerslisttreewidget">
+ <widget class="LongoMatch.Gui.Component.PlayersListTreeWidget" id="localPlayersList">
<property name="MemberName" />
<property name="Events">ButtonPressMask</property>
</widget>
@@ -1860,7 +1854,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.PlayersListTreeWidget" id="visitorplayerslisttreewidget">
+ <widget class="LongoMatch.Gui.Component.PlayersListTreeWidget" id="visitorPlayersList">
<property name="MemberName" />
<property name="Events">ButtonPressMask</property>
</widget>
@@ -1878,7 +1872,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.TagsTreeWidget" id="tagstreewidget1">
+ <widget class="LongoMatch.Gui.Component.TagsTreeWidget" id="tagsList">
<property name="MemberName" />
<property name="Sensitive">False</property>
<property name="Events">ButtonPressMask</property>
@@ -1934,7 +1928,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.PlayerBin" id="playerbin1">
+ <widget class="LongoMatch.Gui.PlayerBin" id="player">
<property name="MemberName" />
<property name="Events">ButtonPressMask</property>
<property name="Rate">1</property>
@@ -1948,7 +1942,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.CapturerBin" id="capturerBin">
+ <widget class="LongoMatch.Gui.CapturerBin" id="capturer">
<property name="MemberName" />
<property name="Events">ButtonPressMask</property>
<signal name="Error" handler="OnCapturerBinError" />
@@ -1965,7 +1959,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.TimeLineWidget" id="timelinewidget1">
+ <widget class="LongoMatch.Gui.Component.TimeLineWidget" id="timeline">
<property name="MemberName" />
<property name="HeightRequest">200</property>
<property name="Visible">False</property>
@@ -1979,7 +1973,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.ButtonsWidget" id="buttonswidget1">
+ <widget class="LongoMatch.Gui.Component.ButtonsWidget" id="buttonswidget">
<property name="MemberName" />
<property name="Visible">False</property>
<property name="Events">ButtonPressMask</property>
@@ -2003,7 +1997,7 @@
<property name="Visible">False</property>
<property name="Spacing">6</property>
<child>
- <widget class="LongoMatch.Gui.Component.NotesWidget" id="noteswidget1">
+ <widget class="LongoMatch.Gui.Component.NotesWidget" id="notes">
<property name="MemberName" />
<property name="Visible">False</property>
<property name="Events">ButtonPressMask</property>
@@ -2014,7 +2008,7 @@
</packing>
</child>
<child>
- <widget class="LongoMatch.Gui.Component.PlayListWidget" id="playlistwidget2">
+ <widget class="LongoMatch.Gui.Component.PlayListWidget" id="playlist">
<property name="MemberName" />
<property name="WidthRequest">100</property>
<property name="Visible">False</property>
@@ -2672,7 +2666,6 @@ new one.</property>
<property name="MemberName" />
<property name="Sensitive">False</property>
<property name="CanFocus">True</property>
- <signal name="DragEnd" handler="OnPlaylisttreeview1DragEnd" />
</widget>
<packing>
<property name="Position">1</property>
diff --git a/LongoMatch/gtk-gui/objects.xml b/LongoMatch.GUI/gtk-gui/objects.xml
similarity index 97%
rename from LongoMatch/gtk-gui/objects.xml
rename to LongoMatch.GUI/gtk-gui/objects.xml
index b3149e1..66d7a6b 100644
--- a/LongoMatch/gtk-gui/objects.xml
+++ b/LongoMatch.GUI/gtk-gui/objects.xml
@@ -1,20 +1,4 @@
<objects attr-sync="on">
- <object type="LongoMatch.Gui.Component.NotesWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals>
- <itemgroup label="NotesWidget Signals">
- <signal name="TimeNodeChanged" />
- </itemgroup>
- </signals>
- </object>
- <object type="LongoMatch.Gui.Component.NotesWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals>
- <itemgroup label="NotesWidget Signals">
- <signal name="TimeNodeChanged" />
- </itemgroup>
- </signals>
- </object>
<object type="LongoMatch.Gui.Component.PlayerPropertiesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
<itemgroups />
<signals>
@@ -68,10 +52,6 @@
</itemgroups>
<signals />
</object>
- <object type="LongoMatch.Gui.Component.PlayerProperties" palette-category="General" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals />
- </object>
<object type="LongoMatch.Gui.Component.ProjectDetailsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups>
<itemgroup label="ProjectDetailsWidget Properties">
@@ -104,76 +84,50 @@
<itemgroups />
<signals />
</object>
- <object type="LongoMatch.Gui.Component.TagsTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+ <object type="LongoMatch.Gui.Component.TaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals />
+ </object>
+ <object type="LongoMatch.Gui.Component.TimeLineWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups>
- <itemgroup label="ListTreeViewBase Properties">
- <property name="Colors" />
+ <itemgroup label="TimeLineWidget Properties">
+ <property name="CurrentFrame" />
</itemgroup>
</itemgroups>
<signals>
- <itemgroup label="ListTreeViewBase Signals">
+ <itemgroup label="TimeLineWidget Signals">
<signal name="TimeNodeChanged" />
<signal name="TimeNodeSelected" />
<signal name="TimeNodeDeleted" />
- <signal name="PlayListNodeAdded" />
- <signal name="SnapshotSeriesEvent" />
- <signal name="TagPlay" />
- <signal name="NewRenderingJob" />
+ <signal name="NewMarkEvent" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.PlayersTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
- <itemgroups>
- <itemgroup label="ListTreeViewBase Properties">
- <property name="Colors" />
- </itemgroup>
- </itemgroups>
+ <object type="LongoMatch.Gui.SubCategoriesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+ <itemgroups />
<signals>
- <itemgroup label="ListTreeViewBase Signals">
- <signal name="TimeNodeChanged" />
- <signal name="TimeNodeSelected" />
- <signal name="TimeNodeDeleted" />
- <signal name="PlayListNodeAdded" />
- <signal name="SnapshotSeriesEvent" />
- <signal name="TagPlay" />
- <signal name="NewRenderingJob" />
+ <itemgroup label="SubCategoriesTreeView Signals">
+ <signal name="SubCategoriesDeleted" />
+ <signal name="SubCategorySelected" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.PlaysTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
- <itemgroups>
- <itemgroup label="ListTreeViewBase Properties">
- <property name="Colors" />
- </itemgroup>
- </itemgroups>
+ <object type="LongoMatch.Gui.Component.RenderingJobsTreeView" palette-category="General" allow-children="false" base-type="Gtk.TreeView">
+ <itemgroups />
<signals>
- <itemgroup label="ListTreeViewBase Signals">
- <signal name="TimeNodeChanged" />
- <signal name="TimeNodeSelected" />
- <signal name="TimeNodeDeleted" />
- <signal name="PlayListNodeAdded" />
- <signal name="SnapshotSeriesEvent" />
- <signal name="TagPlay" />
- <signal name="EditProperties" />
- <signal name="NewRenderingJob" />
- </itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.PlayListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.ButtonsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals>
- <itemgroup label="PlayListWidget Signals">
- <signal name="PlayListNodeSelected" />
- <signal name="ApplyCurrentRate" />
- <signal name="NewRenderingJob" />
+ <itemgroup label="ButtonsWidget Signals">
+ <signal name="NewMarkEvent" />
+ <signal name="NewMarkStartEvent" />
+ <signal name="NewMarkStopEvent" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.TaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals />
- </object>
- <object type="LongoMatch.Gui.Popup.TransparentDrawingArea" palette-category="General" allow-children="false" base-type="Gtk.Window">
+ <object type="LongoMatch.Gui.Component.PlayerProperties" palette-category="General" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals />
</object>
@@ -199,58 +153,89 @@
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.ButtonsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.CategoryProperties" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals>
- <itemgroup label="ButtonsWidget Signals">
- <signal name="NewMarkEvent" />
- <signal name="NewMarkStartEvent" />
- <signal name="NewMarkStopEvent" />
+ <itemgroup label="CategoryProperties Signals">
+ <signal name="HotKeyChanged" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.DrawingToolBox" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.PlayersTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals />
+ </object>
+ <object type="LongoMatch.Gui.Component.TagsTreeWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals>
- <itemgroup label="DrawingToolBox Signals">
- <signal name="LineWidthChanged" />
- <signal name="DrawToolChanged" />
- <signal name="ColorChanged" />
- <signal name="VisibilityChanged" />
- <signal name="ClearDrawing" />
- <signal name="TransparencyChanged" />
+ <itemgroup label="TagsTreeWidget Signals">
+ <signal name="TimeNodeSelected" />
+ <signal name="TimeNodeChanged" />
+ <signal name="PlayListNodeAdded" />
+ <signal name="SnapshotSeriesEvent" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.TimeLineWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.TeamTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals />
+ </object>
+ <object type="LongoMatch.Gui.Popup.TransparentDrawingArea" palette-category="General" allow-children="false" base-type="Gtk.Window">
+ <itemgroups />
+ <signals />
+ </object>
+ <object type="LongoMatch.Gui.Component.TagsTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
<itemgroups>
- <itemgroup label="TimeLineWidget Properties">
- <property name="CurrentFrame" />
+ <itemgroup label="ListTreeViewBase Properties">
+ <property name="Colors" />
</itemgroup>
</itemgroups>
<signals>
- <itemgroup label="TimeLineWidget Signals">
+ <itemgroup label="ListTreeViewBase Signals">
<signal name="TimeNodeChanged" />
<signal name="TimeNodeSelected" />
<signal name="TimeNodeDeleted" />
- <signal name="NewMarkEvent" />
+ <signal name="PlayListNodeAdded" />
+ <signal name="SnapshotSeriesEvent" />
+ <signal name="TagPlay" />
+ <signal name="NewRenderingJob" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.CategoryProperties" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
+ <object type="LongoMatch.Gui.Component.PlaysTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+ <itemgroups>
+ <itemgroup label="ListTreeViewBase Properties">
+ <property name="Colors" />
+ </itemgroup>
+ </itemgroups>
<signals>
- <itemgroup label="CategoryProperties Signals">
- <signal name="HotKeyChanged" />
+ <itemgroup label="PlaysTreeView Signals">
+ <signal name="EditProperties" />
+ <signal name="TimeNodeChanged" />
+ <signal name="TimeNodeSelected" />
+ <signal name="TimeNodeDeleted" />
+ <signal name="PlayListNodeAdded" />
+ <signal name="SnapshotSeriesEvent" />
+ <signal name="TagPlay" />
+ <signal name="NewRenderingJob" />
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.SubCategoriesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
- <itemgroups />
+ <object type="LongoMatch.Gui.Component.PlayersTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+ <itemgroups>
+ <itemgroup label="ListTreeViewBase Properties">
+ <property name="Colors" />
+ </itemgroup>
+ </itemgroups>
<signals>
- <itemgroup label="SubCategoriesTreeView Signals">
- <signal name="SubCategoriesDeleted" />
- <signal name="SubCategorySelected" />
+ <itemgroup label="ListTreeViewBase Signals">
+ <signal name="TimeNodeChanged" />
+ <signal name="TimeNodeSelected" />
+ <signal name="TimeNodeDeleted" />
+ <signal name="PlayListNodeAdded" />
+ <signal name="SnapshotSeriesEvent" />
+ <signal name="TagPlay" />
+ <signal name="NewRenderingJob" />
</itemgroup>
</signals>
</object>
@@ -263,29 +248,32 @@
</itemgroups>
<signals />
</object>
- <object type="LongoMatch.Gui.Component.PlayersTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals />
- </object>
- <object type="LongoMatch.Gui.Component.StringTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals />
- </object>
- <object type="LongoMatch.Gui.Component.TeamTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.NotesWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
- <signals />
+ <signals>
+ <itemgroup label="NotesWidget Signals">
+ <signal name="TimeNodeChanged" />
+ </itemgroup>
+ </signals>
</object>
- <object type="LongoMatch.Gui.Component.TagsTreeWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+ <object type="LongoMatch.Gui.Component.PlayListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals>
- <itemgroup label="TagsTreeWidget Signals">
- <signal name="TimeNodeSelected" />
- <signal name="TimeNodeChanged" />
- <signal name="PlayListNodeAdded" />
- <signal name="SnapshotSeriesEvent" />
+ <itemgroup label="PlayListWidget Signals">
+ <signal name="PlayListNodeSelected" />
+ <signal name="ApplyCurrentRate" />
+ <signal name="NewRenderingJob" />
+ <signal name="OpenPlaylistEvent" />
+ <signal name="NewPlaylistEvent" />
+ <signal name="SavePlaylistEvent" />
+ <signal name="RenderPlaylistEvent" />
</itemgroup>
</signals>
</object>
+ <object type="LongoMatch.Gui.Component.StringTaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals />
+ </object>
<object type="LongoMatch.Gui.Component.RenderingStateBar" palette-category="General" allow-children="false" base-type="Gtk.Bin">
<itemgroups>
<itemgroup label="RenderingStateBar Properties">
@@ -299,9 +287,17 @@
</itemgroup>
</signals>
</object>
- <object type="LongoMatch.Gui.Component.RenderingJobsTreeView" palette-category="General" allow-children="false" base-type="Gtk.TreeView">
+ <object type="LongoMatch.Gui.Component.DrawingToolBox" palette-category="General" allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals>
+ <itemgroup label="DrawingToolBox Signals">
+ <signal name="LineWidthChanged" />
+ <signal name="DrawToolChanged" />
+ <signal name="ColorChanged" />
+ <signal name="VisibilityChanged" />
+ <signal name="ClearDrawing" />
+ <signal name="TransparencyChanged" />
+ </itemgroup>
</signals>
</object>
</objects>
\ No newline at end of file
diff --git a/CesarPlayer/Capturer/FakeCapturer.cs b/LongoMatch.Multimedia/Capturer/FakeCapturer.cs
similarity index 97%
rename from CesarPlayer/Capturer/FakeCapturer.cs
rename to LongoMatch.Multimedia/Capturer/FakeCapturer.cs
index 2c142f4..8ad8563 100644
--- a/CesarPlayer/Capturer/FakeCapturer.cs
+++ b/LongoMatch.Multimedia/Capturer/FakeCapturer.cs
@@ -19,6 +19,8 @@
using System;
using Mono.Unix;
using GLib;
+using LongoMatch.Common;
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Common;
using Gdk;
diff --git a/CesarPlayer/Capturer/GstCameraCapturer.cs b/LongoMatch.Multimedia/Capturer/GstCameraCapturer.cs
similarity index 92%
rename from CesarPlayer/Capturer/GstCameraCapturer.cs
rename to LongoMatch.Multimedia/Capturer/GstCameraCapturer.cs
index 2ad735d..2e29521 100644
--- a/CesarPlayer/Capturer/GstCameraCapturer.cs
+++ b/LongoMatch.Multimedia/Capturer/GstCameraCapturer.cs
@@ -20,11 +20,17 @@ namespace LongoMatch.Video.Capturer {
using System;
using System.Collections;
+ using System.Collections.Generic;
using System.Runtime.InteropServices;
+ using Mono.Unix;
+
+ using LongoMatch.Common;
+ using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Common;
+
#region Autogenerated code
- public class GstCameraCapturer : Gtk.HBox, LongoMatch.Video.Capturer.ICapturer {
+ public class GstCameraCapturer : Gtk.HBox, ICapturer {
public event EllpasedTimeHandler EllapsedTime;
@@ -484,6 +490,36 @@ namespace LongoMatch.Video.Capturer {
LongoMatch.GtkSharp.Capturer.ObjectManager.Initialize();
}
#endregion
-
+
+ static public List<Device> ListVideoDevices() {
+ List<Device> devicesList = new List<Device>();
+
+ /* Generate the list of devices and add the gconf one at the bottom
+ * so that DV sources are always selected before, at least on Linux,
+ * since on Windows both raw an dv sources are listed from the same
+ * source element (dshowvideosrc) */
+ foreach(string devName in GstCameraCapturer.VideoDevices) {
+ string idProp;
+
+ if(Environment.OSVersion.Platform == PlatformID.Unix)
+ idProp = VideoConstants.DV1394SRC_PROP;
+ else
+ idProp = VideoConstants.DSHOWVIDEOSINK_PROP;
+
+ devicesList.Add(new Device {
+ ID = devName,
+ IDProperty = idProp,
+ DeviceType = DeviceType.DV
+ });
+ }
+ if(Environment.OSVersion.Platform == PlatformID.Unix) {
+ devicesList.Add(new Device {
+ ID = Catalog.GetString("Default device"),
+ IDProperty = "",
+ DeviceType = DeviceType.Video
+ });
+ }
+ return devicesList;
+ }
}
}
diff --git a/CesarPlayer/Capturer/LiveSourceTimer.cs b/LongoMatch.Multimedia/Capturer/LiveSourceTimer.cs
similarity index 100%
rename from CesarPlayer/Capturer/LiveSourceTimer.cs
rename to LongoMatch.Multimedia/Capturer/LiveSourceTimer.cs
diff --git a/CesarPlayer/Capturer/ObjectManager.cs b/LongoMatch.Multimedia/Capturer/ObjectManager.cs
similarity index 100%
rename from CesarPlayer/Capturer/ObjectManager.cs
rename to LongoMatch.Multimedia/Capturer/ObjectManager.cs
diff --git a/CesarPlayer/Common/Constants.cs b/LongoMatch.Multimedia/Common/Constants.cs
similarity index 97%
rename from CesarPlayer/Common/Constants.cs
rename to LongoMatch.Multimedia/Common/Constants.cs
index 057bfce..e8a6c0d 100644
--- a/CesarPlayer/Common/Constants.cs
+++ b/LongoMatch.Multimedia/Common/Constants.cs
@@ -21,7 +21,7 @@ using System;
namespace LongoMatch.Video.Common
{
- class Constants {
+ class VideoConstants {
public const string DV1394SRC_PROP = "guid";
public const string DSHOWVIDEOSINK_PROP = "device-name";
}
diff --git a/CesarPlayer/Common/Enum.cs b/LongoMatch.Multimedia/Common/Enum.cs
similarity index 85%
rename from CesarPlayer/Common/Enum.cs
rename to LongoMatch.Multimedia/Common/Enum.cs
index 0a60812..8e86481 100644
--- a/CesarPlayer/Common/Enum.cs
+++ b/LongoMatch.Multimedia/Common/Enum.cs
@@ -47,30 +47,6 @@ namespace LongoMatch.Video.Common
EmptyFile,
}
- public enum VideoEncoderType {
- Mpeg4,
- Xvid,
- Theora,
- H264,
- Mpeg2,
- VP8,
- }
-
- public enum AudioEncoderType {
- Mp3,
- Aac,
- Vorbis,
- }
-
- public enum VideoMuxerType {
- Avi,
- Mp4,
- Matroska,
- Ogg,
- MpegPS,
- WebM,
- }
-
public enum CapturerType {
Fake,
Live,
@@ -145,16 +121,5 @@ namespace LongoMatch.Video.Common
AudioChannels,
}
- public enum DeviceType {
- Video,
- Audio,
- DV
- }
-
- public enum CaptureSourceType {
- None,
- DV,
- Raw,
- DShow
- }
+
}
diff --git a/CesarPlayer/Common/Handlers.cs b/LongoMatch.Multimedia/Common/Handlers.cs
similarity index 99%
rename from CesarPlayer/Common/Handlers.cs
rename to LongoMatch.Multimedia/Common/Handlers.cs
index 59f9e41..64fb353 100644
--- a/CesarPlayer/Common/Handlers.cs
+++ b/LongoMatch.Multimedia/Common/Handlers.cs
@@ -30,7 +30,7 @@ namespace LongoMatch.Video.Common
public delegate void NextButtonClickedHandler();
public delegate void PrevButtonClickedHandler();
public delegate void ProgressHandler(float progress);
- public delegate void FramesProgressHandler(int actual, int total,Pixbuf frame);
+ public delegate void FramesProgressHandler(int actual, int total, Pixbuf frame);
public delegate void DrawFrameHandler(int time);
public delegate void EllpasedTimeHandler(int ellapsedTime);
diff --git a/CesarPlayer/Editor/EditorState.cs b/LongoMatch.Multimedia/Editor/EditorState.cs
similarity index 100%
rename from CesarPlayer/Editor/EditorState.cs
rename to LongoMatch.Multimedia/Editor/EditorState.cs
diff --git a/CesarPlayer/Editor/GstVideoSplitter.cs b/LongoMatch.Multimedia/Editor/GstVideoSplitter.cs
similarity index 99%
rename from CesarPlayer/Editor/GstVideoSplitter.cs
rename to LongoMatch.Multimedia/Editor/GstVideoSplitter.cs
index 7fffd06..1be6ac1 100644
--- a/CesarPlayer/Editor/GstVideoSplitter.cs
+++ b/LongoMatch.Multimedia/Editor/GstVideoSplitter.cs
@@ -23,6 +23,8 @@ namespace LongoMatch.Video.Editor {
using System;
using System.Collections;
using System.Runtime.InteropServices;
+ using LongoMatch.Common;
+ using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Common;
diff --git a/CesarPlayer/Editor/VideoSegment.cs b/LongoMatch.Multimedia/Editor/VideoSegment.cs
similarity index 100%
rename from CesarPlayer/Editor/VideoSegment.cs
rename to LongoMatch.Multimedia/Editor/VideoSegment.cs
diff --git a/CesarPlayer/Capturer/ICapturer.cs b/LongoMatch.Multimedia/Interfaces/ICapturer.cs
similarity index 95%
rename from CesarPlayer/Capturer/ICapturer.cs
rename to LongoMatch.Multimedia/Interfaces/ICapturer.cs
index a5ef4dd..62b4a9f 100644
--- a/CesarPlayer/Capturer/ICapturer.cs
+++ b/LongoMatch.Multimedia/Interfaces/ICapturer.cs
@@ -19,10 +19,11 @@
//
using System;
+using LongoMatch.Common;
using LongoMatch.Video.Common;
using Gdk;
-namespace LongoMatch.Video.Capturer
+namespace LongoMatch.Multimedia.Interfaces
{
diff --git a/CesarPlayer/Utils/IFramesCapturer.cs b/LongoMatch.Multimedia/Interfaces/IFramesCapturer.cs
similarity index 96%
rename from CesarPlayer/Utils/IFramesCapturer.cs
rename to LongoMatch.Multimedia/Interfaces/IFramesCapturer.cs
index be1b070..fe9c308 100644
--- a/CesarPlayer/Utils/IFramesCapturer.cs
+++ b/LongoMatch.Multimedia/Interfaces/IFramesCapturer.cs
@@ -21,7 +21,7 @@
using System;
using Gdk;
-namespace LongoMatch.Video.Utils
+namespace LongoMatch.Multimedia.Interfaces
{
diff --git a/CesarPlayer/Player/IPlayer.cs b/LongoMatch.Multimedia/Interfaces/IPlayer.cs
similarity index 98%
rename from CesarPlayer/Player/IPlayer.cs
rename to LongoMatch.Multimedia/Interfaces/IPlayer.cs
index f98a401..43b2ab6 100644
--- a/CesarPlayer/Player/IPlayer.cs
+++ b/LongoMatch.Multimedia/Interfaces/IPlayer.cs
@@ -24,8 +24,7 @@ using Gdk;
using LongoMatch.Video.Common;
-namespace LongoMatch.Video.Player
-
+namespace LongoMatch.Multimedia.Interfaces
{
public interface IPlayer
{
diff --git a/CesarPlayer/Editor/IVideoEditor.cs b/LongoMatch.Multimedia/Interfaces/IVideoEditor.cs
similarity index 94%
rename from CesarPlayer/Editor/IVideoEditor.cs
rename to LongoMatch.Multimedia/Interfaces/IVideoEditor.cs
index e421150..dc0e5f3 100644
--- a/CesarPlayer/Editor/IVideoEditor.cs
+++ b/LongoMatch.Multimedia/Interfaces/IVideoEditor.cs
@@ -20,12 +20,12 @@
using System;
using System.Collections.Generic;
+using LongoMatch.Common;
using LongoMatch.Video.Common;
-namespace LongoMatch.Video.Editor
+namespace LongoMatch.Multimedia.Interfaces
{
-
public interface IVideoEditor
{
event ProgressHandler Progress;
diff --git a/LongoMatch.Multimedia/LongoMatch.Multimedia.mdp b/LongoMatch.Multimedia/LongoMatch.Multimedia.mdp
new file mode 100644
index 0000000..2537b46
--- /dev/null
+++ b/LongoMatch.Multimedia/LongoMatch.Multimedia.mdp
@@ -0,0 +1,68 @@
+<Project name="LongoMatch.Multimedia" fileversion="2.0" DefaultNamespace="LongoMatch.Multimedia" language="C#" targetFramework="3.5" ctype="DotNetProject">
+ <Configurations active="Release">
+ <Configuration name="Debug" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Multimedia" />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="True" generateoverflowchecks="False" definesymbols="DEBUG" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ <Configuration name="Release" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Multimedia" />
+ <Build debugmode="False" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="True" generateoverflowchecks="False" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ </Configurations>
+ <Contents>
+ <File subtype="Code" buildaction="Compile" name="Player/GstPlayer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Player/ObjectManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Editor/EditorState.cs" />
+ <File subtype="Code" buildaction="Compile" name="Editor/GstVideoSplitter.cs" />
+ <File subtype="Code" buildaction="Compile" name="Editor/VideoSegment.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Constants.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Enum.cs" />
+ <File subtype="Code" buildaction="Compile" name="Common/Handlers.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Capturer" />
+ <File subtype="Code" buildaction="Compile" name="Capturer/ObjectManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Capturer/FakeCapturer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Capturer/GstCameraCapturer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Capturer/LiveSourceTimer.cs" />
+ <File subtype="Code" buildaction="Compile" name="MultimediaFactory.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Utils" />
+ <File subtype="Code" buildaction="Compile" name="Utils/TimeString.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/FramesCapturer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/IMetadataReader.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/PreviewMediaFile.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/MpegRemuxer.cs" />
+ <File subtype="Directory" buildaction="Compile" name="Utils" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Utils" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Common" />
+ <File subtype="Directory" buildaction="Compile" name="Utils" />
+ <File subtype="Directory" buildaction="Compile" name="Player" />
+ <File subtype="Directory" buildaction="Compile" name="Editor" />
+ <File subtype="Directory" buildaction="Compile" name="Capturer" />
+ <File subtype="Directory" buildaction="Compile" name="Utils" />
+ <File subtype="Directory" buildaction="Compile" name="Interfaces" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/ICapturer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IFramesCapturer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IPlayer.cs" />
+ <File subtype="Code" buildaction="Compile" name="Interfaces/IVideoEditor.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/VideoDevice.cs" />
+ <File subtype="Code" buildaction="Compile" name="Utils/GStreamer.cs" />
+ </Contents>
+ <References>
+ <ProjectReference type="Project" localcopy="True" refto="libcesarplayer" />
+ <ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="glib-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Core" />
+ <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ </References>
+</Project>
\ No newline at end of file
diff --git a/LongoMatch.Multimedia/Makefile.am b/LongoMatch.Multimedia/Makefile.am
new file mode 100644
index 0000000..80ff949
--- /dev/null
+++ b/LongoMatch.Multimedia/Makefile.am
@@ -0,0 +1,33 @@
+ASSEMBLY = LongoMatch.Multimedia
+TARGET = library
+
+LINK = $(REF_DEP_LONGOMATCH_MULTIMEDIA)
+
+SOURCES = \
+ Capturer/GstCameraCapturer.cs \
+ Capturer/FakeCapturer.cs \
+ Capturer/LiveSourceTimer.cs \
+ Capturer/ObjectManager.cs \
+ Common/Enum.cs \
+ Common/Constants.cs \
+ Common/Handlers.cs \
+ Editor/EditorState.cs \
+ Editor/VideoSegment.cs \
+ Editor/GstVideoSplitter.cs \
+ Interfaces/IFramesCapturer.cs \
+ Interfaces/ICapturer.cs \
+ Interfaces/IVideoEditor.cs \
+ Interfaces/IPlayer.cs \
+ MultimediaFactory.cs \
+ Player/GstPlayer.cs \
+ Player/ObjectManager.cs \
+ Utils/FramesCapturer.cs \
+ Utils/GStreamer.cs \
+ Utils/IMetadataReader.cs \
+ Utils/MpegRemuxer.cs \
+ Utils/PreviewMediaFile.cs \
+ Utils/TimeString.cs \
+ Utils/VideoDevice.cs
+
+
+include $(top_srcdir)/build/build.mk
diff --git a/CesarPlayer/MultimediaFactory.cs b/LongoMatch.Multimedia/MultimediaFactory.cs
similarity index 91%
rename from CesarPlayer/MultimediaFactory.cs
rename to LongoMatch.Multimedia/MultimediaFactory.cs
index 613c1b5..9b34c69 100644
--- a/CesarPlayer/MultimediaFactory.cs
+++ b/LongoMatch.Multimedia/MultimediaFactory.cs
@@ -19,6 +19,9 @@
//
using System;
+using System.Runtime.InteropServices;
+
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Capturer;
using LongoMatch.Video.Player;
using LongoMatch.Video.Editor;
@@ -104,5 +107,11 @@ namespace LongoMatch.Video
return new FakeCapturer();
}
}
+
+ [DllImport("libcesarplayer.dll")]
+ static extern void gst_init (int argc, string argv);
+ public static void InitBackend() {
+ gst_init(0, "");
+ }
}
}
\ No newline at end of file
diff --git a/CesarPlayer/Player/GstPlayer.cs b/LongoMatch.Multimedia/Player/GstPlayer.cs
similarity index 99%
rename from CesarPlayer/Player/GstPlayer.cs
rename to LongoMatch.Multimedia/Player/GstPlayer.cs
index d4d2ead..2774461 100644
--- a/CesarPlayer/Player/GstPlayer.cs
+++ b/LongoMatch.Multimedia/Player/GstPlayer.cs
@@ -21,6 +21,7 @@ namespace LongoMatch.Video.Player {
using System;
using System.Collections;
using System.Runtime.InteropServices;
+ using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Common;
using LongoMatch.Video.Utils;
diff --git a/CesarPlayer/Player/ObjectManager.cs b/LongoMatch.Multimedia/Player/ObjectManager.cs
similarity index 100%
rename from CesarPlayer/Player/ObjectManager.cs
rename to LongoMatch.Multimedia/Player/ObjectManager.cs
diff --git a/CesarPlayer/Utils/FramesCapturer.cs b/LongoMatch.Multimedia/Utils/FramesCapturer.cs
similarity index 98%
rename from CesarPlayer/Utils/FramesCapturer.cs
rename to LongoMatch.Multimedia/Utils/FramesCapturer.cs
index e918993..47018b4 100644
--- a/CesarPlayer/Utils/FramesCapturer.cs
+++ b/LongoMatch.Multimedia/Utils/FramesCapturer.cs
@@ -24,6 +24,7 @@ using LongoMatch.Video;
using Gdk;
using Gtk;
using System.Threading;
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video.Common;
namespace LongoMatch.Video.Utils
diff --git a/LongoMatch/Common/GStreamer.cs b/LongoMatch.Multimedia/Utils/GStreamer.cs
similarity index 75%
rename from LongoMatch/Common/GStreamer.cs
rename to LongoMatch.Multimedia/Utils/GStreamer.cs
index 999ea3f..bcb00b2 100644
--- a/LongoMatch/Common/GStreamer.cs
+++ b/LongoMatch.Multimedia/Utils/GStreamer.cs
@@ -19,16 +19,16 @@ using System;
using System.IO;
using System.Runtime.InteropServices;
using Gtk;
-using LongoMatch.Gui;
+using LongoMatch.Video;
+using Mono.Unix;
+using LongoMatch.Common;
-namespace LongoMatch.Common
+namespace LongoMatch.Multimedia.Utils
{
public class GStreamer
{
[DllImport("libgstreamer-0.10.dll") /* willfully unmapped */ ]
- static extern void gst_init (int argc, string argv);
- [DllImport("libgstreamer-0.10.dll") /* willfully unmapped */ ]
static extern IntPtr gst_registry_get_default ();
[DllImport("libgstreamer-0.10.dll") /* willfully unmapped */ ]
static extern IntPtr gst_registry_lookup_feature (IntPtr raw, string name);
@@ -39,8 +39,10 @@ namespace LongoMatch.Common
private const string REGISTRY_PATH = "registry.bin";
public static void Init() {
- SetUpEnvironment ();
- gst_init (0, "");
+ Log.Information("Initializing GStreamer.");
+ SetUpEnvironment();
+ MultimediaFactory.InitBackend();
+ Log.Information("GStreamer initialized successfully.");
}
public static bool CheckInstallation () {
@@ -69,11 +71,11 @@ namespace LongoMatch.Common
/* Use a custom path for the registry in Windows */
Environment.SetEnvironmentVariable("GST_REGISTRY", registryPath);
- Environment.SetEnvironmentVariable("GST_PLUGIN_PATH",MainClass.RelativeToPrefix("lib\\gstreamer-0.10"));
+ Environment.SetEnvironmentVariable("GST_PLUGIN_PATH", Config.RelativeToPrefix("lib\\gstreamer-0.10"));
}
private static string GetGstDirectory () {
- return Path.Combine (MainClass.HomeDir(), GST_DIRECTORY);
+ return Path.Combine (Config.HomeDir(), GST_DIRECTORY);
}
private static string GetRegistryPath() {
@@ -105,10 +107,14 @@ namespace LongoMatch.Common
private static void HandleInstallationError () {
File.Delete(GetRegistryPath());
-
- MessagePopup.PopupMessage(null, MessageType.Error, "An error has been detected in the current " +
- "installation.\n Try restarting " + Constants.SOFTWARE_NAME + " and contact with the " +
- "development team if the problem persists.");
+ MessageDialog md = new MessageDialog(null, DialogFlags.Modal,
+ MessageType.Error, ButtonsType.Ok,
+ Catalog.GetString("An error has been detected in the current " +
+ "installation.") + "\n" +
+ Catalog.GetString(String.Format ("Try restarting {0} and contact with" +
+ "the development team if the problem persists.", Constants.SOFTWARE_NAME)));
+ md.Run();
+ md.Destroy();
}
}
}
diff --git a/CesarPlayer/Utils/IMetadataReader.cs b/LongoMatch.Multimedia/Utils/IMetadataReader.cs
similarity index 100%
rename from CesarPlayer/Utils/IMetadataReader.cs
rename to LongoMatch.Multimedia/Utils/IMetadataReader.cs
diff --git a/CesarPlayer/Utils/MpegRemuxer.cs b/LongoMatch.Multimedia/Utils/MpegRemuxer.cs
similarity index 100%
rename from CesarPlayer/Utils/MpegRemuxer.cs
rename to LongoMatch.Multimedia/Utils/MpegRemuxer.cs
diff --git a/CesarPlayer/Utils/PreviewMediaFile.cs b/LongoMatch.Multimedia/Utils/PreviewMediaFile.cs
similarity index 66%
rename from CesarPlayer/Utils/PreviewMediaFile.cs
rename to LongoMatch.Multimedia/Utils/PreviewMediaFile.cs
index f334842..6015449 100644
--- a/CesarPlayer/Utils/PreviewMediaFile.cs
+++ b/LongoMatch.Multimedia/Utils/PreviewMediaFile.cs
@@ -17,6 +17,8 @@
//
using System;
+using LongoMatch.Multimedia.Interfaces;
+using LongoMatch.Store;
using LongoMatch.Video;
using LongoMatch.Video.Common;
using LongoMatch.Video.Player;
@@ -27,46 +29,13 @@ namespace LongoMatch.Video.Utils
{
[Serializable]
- public class PreviewMediaFile:MediaFile
+ public class PreviewMediaFile
{
-
- private byte[] thumbnailBuf;
-
const int THUMBNAIL_MAX_HEIGHT=72;
const int THUMBNAIL_MAX_WIDTH=96;
- public PreviewMediaFile() {}
-
- public PreviewMediaFile(string filePath,
- long length,
- ushort fps,
- bool hasAudio,
- bool hasVideo,
- string VideoEncoderType,
- string AudioEncoderType,
- uint videoWidth,
- uint videoHeight,
- Pixbuf preview):base(filePath,length,fps,hasAudio,hasVideo,VideoEncoderType,AudioEncoderType,videoWidth,videoHeight)
- {
- this.Preview=preview;
- }
-
- public Pixbuf Preview {
- get {
- if(thumbnailBuf != null)
- return new Pixbuf(thumbnailBuf);
- else return null;
- }
- set {
- if(value != null) {
- thumbnailBuf = value.SaveToBuffer("png");
- value.Dispose();
- }
- else thumbnailBuf = null;
- }
- }
-
- public new static PreviewMediaFile GetMediaFile(string filePath) {
+ /* FIXME: hackish as hell! */
+ public static MediaFile DiscoverFile(string filePath) {
int duration=0;
bool hasVideo;
bool hasAudio;
@@ -105,12 +74,11 @@ namespace LongoMatch.Video.Utils
width = (int) reader.GetMetadata(MetadataType.DimensionY);
reader.Close();
reader.Dispose();
-
- return new PreviewMediaFile(filePath,duration*1000,
- (ushort)fps,hasAudio,
- hasVideo,VideoEncoderType,
- AudioEncoderType,(uint)height,
- (uint)width,preview);
+ return new LongoMatch.Store.MediaFile(filePath,duration*1000,
+ (ushort)fps,hasAudio,
+ hasVideo,VideoEncoderType,
+ AudioEncoderType,(uint)height,
+ (uint)width,preview);
}
catch(GLib.GException ex) {
throw new Exception(Catalog.GetString("Invalid video file:")+"\n"+ex.Message);
diff --git a/CesarPlayer/Utils/TimeString.cs b/LongoMatch.Multimedia/Utils/TimeString.cs
similarity index 100%
rename from CesarPlayer/Utils/TimeString.cs
rename to LongoMatch.Multimedia/Utils/TimeString.cs
diff --git a/CesarPlayer/Utils/Device.cs b/LongoMatch.Multimedia/Utils/VideoDevice.cs
similarity index 56%
rename from CesarPlayer/Utils/Device.cs
rename to LongoMatch.Multimedia/Utils/VideoDevice.cs
index 63efda2..e6ada1c 100644
--- a/CesarPlayer/Utils/Device.cs
+++ b/LongoMatch.Multimedia/Utils/VideoDevice.cs
@@ -1,92 +1,62 @@
-//
-// Copyright (C) 2010 Andoni Morales Alastruey
-//
+//
+// Copyright (C) 2011 Andoni Morales Alastruey
+//
// This program 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.
-//
+//
// 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
// 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, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
-//
-
+//
using System;
using System.Collections.Generic;
-using LongoMatch.Video.Capturer;
-using LongoMatch.Video.Common;
using Mono.Unix;
-namespace LongoMatch.Video.Utils
-{
-
+using LongoMatch.Common;
+using LongoMatch.Video.Common;
+using LongoMatch.Video.Capturer;
- public class Device
+namespace LongoMatch.Multimedia.Utils
+{
+ public class VideoDevice
{
- public Device() {
-
- }
-
- /// <summary>
- /// Device Type among Video, Audio or DV (for dv cameras)
- /// </summary>
- public DeviceType DeviceType {
- get;
- set;
- }
-
- /// <summary>
- /// Device id, can be a human friendly name (for DirectShow devices),
- /// the de device name (/dev/video0) or the GUID (dv1394src)
- /// </summary>
- public string ID {
- get;
- set;
- }
-
- /// <summary>
- /// The name of the gstreamer element property used to set the device
- /// </summary>
-
- public string IDProperty {
- get;
- set;
- }
-
- static public List<Device> ListVideoDevices() {
+
+ static public List<Device> ListVideoDevices (){
List<Device> devicesList = new List<Device>();
-
+
/* Generate the list of devices and add the gconf one at the bottom
- * so that DV sources are always selected before, at least on Linux,
+ * so that DV sources are always selected before, at least on Linux,
* since on Windows both raw an dv sources are listed from the same
* source element (dshowvideosrc) */
- foreach(string devName in GstCameraCapturer.VideoDevices) {
+ foreach (string devName in GstCameraCapturer.VideoDevices){
string idProp;
-
- if(Environment.OSVersion.Platform == PlatformID.Unix)
- idProp = Constants.DV1394SRC_PROP;
- else
- idProp = Constants.DSHOWVIDEOSINK_PROP;
-
+
+ if (Environment.OSVersion.Platform == PlatformID.Unix)
+ idProp = VideoConstants.DV1394SRC_PROP;
+ else
+ idProp = VideoConstants.DSHOWVIDEOSINK_PROP;
+
devicesList.Add(new Device {
ID = devName,
IDProperty = idProp,
- DeviceType = DeviceType.DV
- });
+ DeviceType = DeviceType.DV});
}
- if(Environment.OSVersion.Platform == PlatformID.Unix) {
+ if (Environment.OSVersion.Platform == PlatformID.Unix){
devicesList.Add(new Device {
ID = Catalog.GetString("Default device"),
IDProperty = "",
- DeviceType = DeviceType.Video
- });
- }
+ DeviceType = DeviceType.Video});
+ }
return devicesList;
}
+
}
}
+
diff --git a/LongoMatch.Services/LongoMatch.Services.mdp b/LongoMatch.Services/LongoMatch.Services.mdp
new file mode 100644
index 0000000..2faf6a8
--- /dev/null
+++ b/LongoMatch.Services/LongoMatch.Services.mdp
@@ -0,0 +1,39 @@
+<Project name="LongoMatch.Services" fileversion="2.0" DefaultNamespace="LongoMatch.Services" language="C#" targetFramework="3.5" ctype="DotNetProject">
+ <Configurations active="Release">
+ <Configuration name="Debug" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Services" />
+ <Build debugmode="True" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" definesymbols="DEBUG" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ <Configuration name="Release" ctype="DotNetProjectConfiguration">
+ <Output directory="../bin" assembly="LongoMatch.Services" />
+ <Build debugmode="False" target="Library" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ </Configuration>
+ </Configurations>
+ <Contents>
+ <File subtype="Directory" buildaction="Compile" name="." />
+ <File subtype="Code" buildaction="Compile" name="Services/DataBase.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/TemplatesService.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/RenderingJobsManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/Core.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/HotKeysManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/EventsManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/VideoDrawingsManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/PlaylistManager.cs" />
+ <File subtype="Code" buildaction="Compile" name="Services/ProjectsManager.cs" />
+ </Contents>
+ <References>
+ <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Core" />
+ <ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.GUI" />
+ <ProjectReference type="Gac" localcopy="True" refto="Db4objects.Db4o, Version=7.4.121.14026, Culture=neutral, PublicKeyToken=6199cd4f203aa8eb" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Multimedia" />
+ <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.GUI.Multimedia" />
+ </References>
+</Project>
\ No newline at end of file
diff --git a/LongoMatch.Services/Makefile.am b/LongoMatch.Services/Makefile.am
new file mode 100644
index 0000000..3579540
--- /dev/null
+++ b/LongoMatch.Services/Makefile.am
@@ -0,0 +1,17 @@
+ASSEMBLY = LongoMatch.Services
+TARGET = library
+
+LINK = $(REF_DEP_LONGOMATCH_SERVICES)
+
+SOURCES = \
+ Services/PlaylistManager.cs \
+ Services/VideoDrawingsManager.cs \
+ Services/ProjectsManager.cs \
+ Services/TemplatesService.cs \
+ Services/EventsManager.cs \
+ Services/Core.cs \
+ Services/HotKeysManager.cs \
+ Services/DataBase.cs \
+ Services/RenderingJobsManager.cs
+
+include $(top_srcdir)/build/build.mk
diff --git a/LongoMatch.Services/Services/Core.cs b/LongoMatch.Services/Services/Core.cs
new file mode 100644
index 0000000..efb81ca
--- /dev/null
+++ b/LongoMatch.Services/Services/Core.cs
@@ -0,0 +1,167 @@
+//
+// Copyright (C) 2011 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+using System;
+using System.IO;
+using Gtk;
+using Mono.Unix;
+
+using LongoMatch.Gui;
+using LongoMatch.DB;
+using LongoMatch.Common;
+
+namespace LongoMatch.Services
+{
+ public class Core
+ {
+ static DataBase db;
+ static TemplatesService ts;
+
+ public static void Init(MainWindow mainWindow)
+ {
+ Log.Debugging = Debugging;
+ Log.Information("Starting " + Constants.SOFTWARE_NAME);
+
+ /* Init internationalization support */
+ Catalog.Init(Constants.SOFTWARE_NAME.ToLower(),Config.RelativeToPrefix("share/locale"));
+
+ /* Init Gtk */
+ Application.Init();
+
+ SetupBaseDir();
+
+ /* Check default folders */
+ CheckDirs();
+
+ StartServices(mainWindow);
+ BindEvents(mainWindow);
+ }
+
+ public static void StartServices(MainWindow mainWindow){
+ EventsManager eManager;
+ HotKeysManager hkManager;
+ RenderingJobsManager videoRenderer;
+ ProjectsManager projectsManager;
+
+ /* Start TemplatesService */
+ ts = new TemplatesService(Config.configDirectory);
+
+ /* Start DB services */
+ db = new DataBase(Path.Combine(Config.DBDir(),Constants.DB_FILE));
+
+ /* Start the events manager */
+ eManager = new EventsManager(mainWindow);
+
+ /* Start the hotkeys manager */
+ hkManager = new HotKeysManager();
+ hkManager.newMarkEvent += eManager.OnNewTag;
+ mainWindow.KeyPressEvent += hkManager.KeyListener;
+
+ /* Start the rendering jobs manager */
+ videoRenderer = new RenderingJobsManager(mainWindow.RenderingStateBar);
+ mainWindow.NewJobEvent += (job) => {videoRenderer.AddJob(job);};
+
+ projectsManager = new ProjectsManager(mainWindow);
+
+ /*
+ OnProjectChange => hkManager.Categories=project.Categories;
+
+ */
+ }
+
+ public static void BindEvents(MainWindow mainWindow) {
+ /* Connect player events */
+ /* FIXME:
+ player.Prev += OnPrev;
+ player.Next += OnNext;
+ player.Tick += OnTick;
+ player.SegmentClosedEvent += OnSegmentClosedEvent;
+ player.DrawFrame += OnDrawFrame;*/
+ }
+
+ public static void CheckDirs() {
+ if(!System.IO.Directory.Exists(Config.HomeDir()))
+ System.IO.Directory.CreateDirectory(Config.HomeDir());
+ if(!System.IO.Directory.Exists(Config.TemplatesDir()))
+ System.IO.Directory.CreateDirectory(Config.TemplatesDir());
+ if(!System.IO.Directory.Exists(Config.SnapshotsDir()))
+ System.IO.Directory.CreateDirectory(Config.SnapshotsDir());
+ if(!System.IO.Directory.Exists(Config.PlayListDir()))
+ System.IO.Directory.CreateDirectory(Config.PlayListDir());
+ if(!System.IO.Directory.Exists(Config.DBDir()))
+ System.IO.Directory.CreateDirectory(Config.DBDir());
+ if(!System.IO.Directory.Exists(Config.VideosDir()))
+ System.IO.Directory.CreateDirectory(Config.VideosDir());
+ if(!System.IO.Directory.Exists(Config.TempVideosDir()))
+ System.IO.Directory.CreateDirectory(Config.TempVideosDir());
+ }
+
+ public static DataBase DB {
+ get {
+ return db;
+ }
+ }
+
+ public static TemplatesService TemplatesService {
+ get {
+ return ts;
+ }
+ }
+
+ private static void SetupBaseDir() {
+ string home;
+
+ if (Environment.OSVersion.Platform == PlatformID.Win32NT) {
+ Config.baseDirectory = System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory,"../");
+ }
+ else
+ Config.baseDirectory = System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory,"../../");
+
+ /* Check for the magic file PORTABLE to check if it's a portable version
+ * and the config goes in the same folder as the binaries */
+ if (File.Exists(System.IO.Path.Combine(Config.baseDirectory, Constants.PORTABLE_FILE)))
+ home = Config.baseDirectory;
+ else
+ home = System.Environment.GetFolderPath(Environment.SpecialFolder.Personal);
+
+ Config.homeDirectory = System.IO.Path.Combine(home,Constants.SOFTWARE_NAME);
+ if (Environment.OSVersion.Platform == PlatformID.Win32NT)
+ Config.configDirectory = Config.homeDirectory;
+ else
+ Config.configDirectory = System.IO.Path.Combine(home,".longomatch");
+ }
+
+ private static bool? debugging = null;
+ public static bool Debugging {
+ get {
+ if(debugging == null) {
+ debugging = EnvironmentIsSet("LGM_DEBUG");
+ }
+ return debugging.Value;
+ }
+ set {
+ debugging = value;
+ Log.Debugging = Debugging;
+ }
+ }
+
+ public static bool EnvironmentIsSet(string env)
+ {
+ return !String.IsNullOrEmpty(Environment.GetEnvironmentVariable(env));
+ }
+ }
+}
diff --git a/LongoMatch/Services/DataBase.cs b/LongoMatch.Services/Services/DataBase.cs
similarity index 98%
rename from LongoMatch/Services/DataBase.cs
rename to LongoMatch.Services/Services/DataBase.cs
index a26803a..ee71a7a 100644
--- a/LongoMatch/Services/DataBase.cs
+++ b/LongoMatch.Services/Services/DataBase.cs
@@ -20,17 +20,14 @@
using System;
using System.Collections.Generic;
-using System.Linq;
using System.IO;
using Db4objects.Db4o;
using Db4objects.Db4o.Query;
using Gtk;
using LongoMatch.Common;
-using LongoMatch.Gui;
+using LongoMatch.Interfaces;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
-using LongoMatch.Video.Utils;
-using Mono.Unix;
namespace LongoMatch.DB
{
@@ -41,7 +38,7 @@ namespace LongoMatch.DB
/// Projects are uniquely indentified by their filename, assuming that you can't
/// create two projects for the same video file.
/// </summary>
- public sealed class DataBase
+ public sealed class DataBase: IDatabase
{
// File path of the database
private string file;
@@ -366,7 +363,7 @@ namespace LongoMatch.DB
if (lastBackup.Date + maxDaysWithoutBackup >= now)
return;
- backupFilepath = Path.Combine(MainClass.DBDir(), backupFilename);
+ backupFilepath = Path.Combine(Config.DBDir(), backupFilename);
if (File.Exists(backupFilepath))
File.Delete(backupFilepath);
diff --git a/LongoMatch.Services/Services/EventsManager.cs b/LongoMatch.Services/Services/EventsManager.cs
new file mode 100644
index 0000000..93ad2c2
--- /dev/null
+++ b/LongoMatch.Services/Services/EventsManager.cs
@@ -0,0 +1,314 @@
+// EventsManager.cs
+//
+// Copyright (C2007-2009 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+//Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+//
+
+using System.Collections.Generic;
+using Gdk;
+using Gtk;
+using LongoMatch.Common;
+using LongoMatch.Gui;
+using LongoMatch.Gui.Component;
+using LongoMatch.Gui.Dialog;
+using LongoMatch.Handlers;
+using LongoMatch.Interfaces;
+using LongoMatch.Store;
+using LongoMatch.Video.Common;
+using LongoMatch.Video.Editor;
+using LongoMatch.Video.Utils;
+using LongoMatch.Multimedia.Interfaces;
+using Mono.Unix;
+
+namespace LongoMatch.Services
+{
+
+
+ public class EventsManager
+ {
+
+ private FramesSeriesCapturer fsc;
+ private FramesCaptureProgressDialog fcpd;
+ private VideoDrawingsManager drawingManager;
+
+ /* Current play loaded. null if no play is loaded */
+ TimeNode selectedTimeNode=null;
+ /* current project in use */
+ Project openedProject;
+ ProjectType projectType;
+ Time startTime;
+
+ MainWindow mainWindow;
+ PlayerBin player;
+ CapturerBin capturer;
+
+ public EventsManager(MainWindow mainWindow)
+ {
+ this.mainWindow = mainWindow;
+ this.player = mainWindow.Player;
+ this.capturer = mainWindow.Capturer;
+ this.drawingManager = new VideoDrawingsManager(player);
+ ConnectSignals();
+ }
+
+ public Project OpenedProject {
+ set {
+ openedProject = value;
+ }
+ }
+
+ public ProjectType OpenedProjectType {
+ set {
+ projectType = value;
+ }
+ }
+
+ private void ConnectSignals() {
+ /* Adding Handlers for each event */
+
+ /* Connect tagging related events */
+ mainWindow.NewTagEvent += OnNewTag;
+ mainWindow.NewTagStartEvent += OnNewPlayStart;
+ mainWindow.NewTagStopEvent += OnNewPlayStop;
+ mainWindow.NewTagAtFrameEvent += OnNewTagAtFrame;
+ mainWindow.TimeNodeChanged += OnTimeNodeChanged;
+ mainWindow.PlaysDeletedEvent += OnPlaysDeleted;;
+ mainWindow.PlaySelectedEvent += OnPlaySelected;;
+
+ /* Connect playlist events */
+ mainWindow.PlayListNodeSelectedEvent += (tn) => {selectedTimeNode = tn;};
+ /* Connect tags events */
+ mainWindow.TagPlayEvent += OnTagPlay;
+
+ /* Connect SnapshotSeries events */
+ mainWindow.SnapshotSeriesEvent += OnSnapshotSeries;
+
+ /* Connect player events */
+ player.Prev += OnPrev;
+ player.SegmentClosedEvent += OnSegmentClosedEvent;
+ player.DrawFrame += OnDrawFrame;
+ }
+
+ private void ProcessNewTag(Category category,Time pos) {
+ Time length, startTime, stopTime, start, stop, fStart, fStop;
+
+ if(player == null || openedProject == null)
+ return;
+
+ /* Get the default lead and lag time for the category */
+ startTime = category.Start;
+ stopTime = category.Stop;
+ /* Calculate boundaries of the segment */
+ start = pos - startTime;
+ stop = pos + stopTime;
+ fStart = (start < new Time {MSeconds =0}) ? new Time {MSeconds = 0} : start;
+
+ if(projectType == ProjectType.FakeCaptureProject ||
+ projectType == ProjectType.CaptureProject) {
+ fStop = stop;
+ } else {
+ length = new Time {MSeconds = (int)player.StreamLength};
+ fStop = (stop > length) ? length: stop;
+ }
+ AddNewPlay(fStart, fStop, category);
+ }
+
+ private void AddNewPlay(Time start, Time stop, Category category) {
+ Pixbuf miniature;
+
+ /* Get the current frame and get a thumbnail from it */
+ if(projectType == ProjectType.CaptureProject) {
+ if(!capturer.Capturing) {
+ MessagePopup.PopupMessage(capturer, MessageType.Info,
+ Catalog.GetString("You can't create a new play if the capturer "+
+ "is not recording."));
+ return;
+ }
+ miniature = capturer.CurrentMiniatureFrame;
+ }
+ else if(projectType == ProjectType.FileProject)
+ miniature = player.CurrentMiniatureFrame;
+ else
+ miniature = null;
+
+ /* Add the new created play to the project and update the GUI*/
+ var play = openedProject.AddPlay(category, start, stop,miniature);
+ mainWindow.AddPlay(play);
+ /* Tag subcategories of the new play */
+ LaunchPlayTagger(play);
+ }
+
+ protected virtual void OnNewTagAtFrame(Category category, int frame) {
+ Time pos = new Time { MSeconds = frame*1000/openedProject.Description.File.Fps};
+ player.CloseActualSegment();
+ player.SeekTo((long)pos.MSeconds, true);
+ ProcessNewTag(category,pos);
+ }
+
+ public virtual void OnNewTag(Category category) {
+ Time pos;
+
+ if(projectType == ProjectType.FakeCaptureProject ||
+ projectType == ProjectType.CaptureProject) {
+ pos = new Time { MSeconds = (int)capturer.CurrentTime};
+ } else {
+ pos = new Time {MSeconds = (int)player.CurrentTime};
+ }
+ ProcessNewTag(category,pos);
+ }
+
+ public virtual void OnNewPlayStart() {
+ startTime = new Time {MSeconds = (int)player.CurrentTime};
+ }
+
+ public virtual void OnNewPlayStop(Category category) {
+ int diff;
+ Time stopTime = new Time {MSeconds = (int)player.CurrentTime};
+
+ diff = stopTime.MSeconds - startTime.MSeconds;
+
+ if(diff < 0) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Warning,
+ Catalog.GetString("The stop time is smaller than the start time. "+
+ "The play will not be added."));
+ return;
+ }
+ if(diff < 500) {
+ int correction = 500 - diff;
+ if(startTime.MSeconds - correction > 0)
+ startTime = startTime - correction;
+ else
+ stopTime = stopTime + correction;
+ }
+ AddNewPlay(startTime, stopTime, category);
+ }
+
+ private void LaunchPlayTagger(Play play) {
+ TaggerDialog tg = new TaggerDialog(play.Category, play.Tags, play.Players, play.Teams,
+ openedProject.LocalTeamTemplate, openedProject.VisitorTeamTemplate);
+ tg.TransientFor = mainWindow as Gtk.Window;
+ tg.Run();
+ tg.Destroy();
+ }
+
+ protected virtual void OnPlaySelected(Play play)
+ {
+ selectedTimeNode = play;
+ player.SetStartStop(play.Start.MSeconds,play.Stop.MSeconds);
+ drawingManager.Play=play;
+ mainWindow.UpdateSelectedPlay(play);
+ }
+
+ protected virtual void OnTimeNodeChanged(TimeNode tNode, object val)
+ {
+ /* FIXME: Tricky, create a new handler for categories */
+ if(tNode is Play && val is Time) {
+ if(tNode != selectedTimeNode)
+ OnPlaySelected((Play)tNode);
+ Time pos = (Time)val;
+ if(pos == tNode.Start) {
+ player.UpdateSegmentStartTime(pos.MSeconds);
+ }
+ else {
+ player.UpdateSegmentStopTime(pos.MSeconds);
+ }
+ }
+ else if(tNode is Category) {
+ mainWindow.UpdateCategories(openedProject.Categories);
+ }
+ }
+
+ protected virtual void OnPlaysDeleted(List<Play> plays)
+ {
+ mainWindow.DeletePlays(plays);
+ openedProject.RemovePlays(plays);
+
+ if(projectType == ProjectType.FileProject) {
+ player.CloseActualSegment();
+ Core.DB.UpdateProject(openedProject);
+ }
+ }
+
+ protected virtual void OnSegmentClosedEvent()
+ {
+ selectedTimeNode = null;
+ }
+
+ protected virtual void OnSnapshotSeries(Play tNode) {
+ SnapshotsDialog sd;
+ uint interval;
+ string seriesName;
+ string outDir;
+
+ player.Pause();
+
+ sd= new SnapshotsDialog();
+ sd.TransientFor= mainWindow as Gtk.Window;
+ sd.Play = tNode.Name;
+
+ if(sd.Run() == (int)ResponseType.Ok) {
+ sd.Destroy();
+ interval = sd.Interval;
+ seriesName = sd.SeriesName;
+ outDir = System.IO.Path.Combine(Config.SnapshotsDir(),seriesName);
+ fsc = new FramesSeriesCapturer(openedProject.Description.File.FilePath,
+ tNode.Start.MSeconds,tNode.Stop.MSeconds,
+ interval,outDir);
+ fcpd = new FramesCaptureProgressDialog(fsc);
+ fcpd.TransientFor = mainWindow as Gtk.Window;
+ fcpd.Run();
+ fcpd.Destroy();
+ }
+ else
+ sd.Destroy();
+ }
+
+ protected virtual void OnPrev()
+ {
+ if(selectedTimeNode is Play)
+ player.SeekInSegment(selectedTimeNode.Start.MSeconds);
+ else if(selectedTimeNode == null)
+ player.SeekTo(0,false);
+ }
+
+ protected virtual void OnTimeline2PositionChanged(Time pos)
+ {
+ player.SeekInSegment(pos.MSeconds);
+ }
+
+ protected virtual void OnDrawFrame(int time) {
+ Pixbuf pixbuf=null;
+ DrawingTool dialog = new DrawingTool();
+
+ player.Pause();
+ pixbuf = player.CurrentFrame;
+
+ dialog.Image = pixbuf;
+ dialog.TransientFor = (Gtk.Window)player.Toplevel;
+ if(selectedTimeNode != null)
+ dialog.SetPlay((selectedTimeNode as Play),
+ time);
+ pixbuf.Dispose();
+ dialog.Run();
+ dialog.Destroy();
+ }
+
+ protected virtual void OnTagPlay(Play play) {
+ LaunchPlayTagger(play);
+ }
+ }
+}
diff --git a/LongoMatch/Handlers/HotKeysManager.cs b/LongoMatch.Services/Services/HotKeysManager.cs
similarity index 94%
rename from LongoMatch/Handlers/HotKeysManager.cs
rename to LongoMatch.Services/Services/HotKeysManager.cs
index 2a57cf5..7d6228a 100644
--- a/LongoMatch/Handlers/HotKeysManager.cs
+++ b/LongoMatch.Services/Services/HotKeysManager.cs
@@ -23,15 +23,16 @@ using Gdk;
using Gtk;
using LongoMatch.Store;
using LongoMatch.Store.Templates;
+using LongoMatch.Handlers;
-namespace LongoMatch.Handlers
+namespace LongoMatch.Services
{
public class HotKeysManager
{
private Dictionary<HotKey, Category> dic;
- public event NewMarkEventHandler newMarkEvent;
+ public event NewTagHandler newMarkEvent;
public HotKeysManager()
{
diff --git a/LongoMatch.Services/Services/PlaylistManager.cs b/LongoMatch.Services/Services/PlaylistManager.cs
new file mode 100644
index 0000000..f86c5fe
--- /dev/null
+++ b/LongoMatch.Services/Services/PlaylistManager.cs
@@ -0,0 +1,219 @@
+//
+// Copyright (C) 2011 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+using System;
+using Gtk;
+
+using LongoMatch.Gui.Component;
+using LongoMatch.Gui;
+using LongoMatch.Interfaces;
+using LongoMatch.Store;
+using LongoMatch.Common;
+using Mono.Unix;
+
+
+namespace LongoMatch.Services
+{
+ public class PlaylistManager
+ {
+ IPlaylistWidget playlistWidget;
+ IPlayList playlist;
+ PlayerBin player;
+ /* FIXME */
+ Project openedProject;
+ TimeNode selectedTimeNode;
+
+ bool clockStarted;
+ uint timeout;
+
+ public PlaylistManager (MainWindow mainWindow)
+ {
+ playlistWidget = mainWindow.Playlist;
+ player = mainWindow.Player;
+ BindEvents(mainWindow, mainWindow.Player);
+ }
+
+ public void Stop() {
+ StopClock();
+ }
+
+ public void Load(string filePath) {
+ try {
+ playlist = PlayList.Load(filePath);
+ playlistWidget.Load(playlist);
+ } catch (Exception e){
+ Log.Exception (e);
+ MessagePopup.PopupMessage(playlistWidget as Gtk.Widget ,MessageType.Error,
+ Catalog.GetString("The file you are trying to load is not a playlist or it's not compatible with the current version"));
+ }
+ }
+
+ private void BindEvents(MainWindow mainWindow, PlayerBin player) {
+ /* Track loaded element */
+ mainWindow.PlaySelectedEvent += (p) => {selectedTimeNode = p;};
+ player.SegmentClosedEvent += () => {selectedTimeNode = null;};
+
+ /* Handle New/Open/Save playlist */
+ mainWindow.OpenPlaylistEvent += OnOpenPlaylist;
+ mainWindow.NewPlaylistEvent += OnNewPlaylist;
+ mainWindow.SavePlaylistEvent += OnSavePlaylist;
+
+ /* Handle Add/Select/Rate events from other widgets */
+ mainWindow.PlayListNodeAddedEvent += OnPlayListNodeAdded;
+ mainWindow.PlayListNodeSelectedEvent += LoadPlaylistPlay;
+ mainWindow.ApplyRateEvent += (p) => {p.Rate = player.Rate;};
+
+ /* Handle Next/Prev from the player */
+ player.Next += () => {Next();};
+ player.Prev += () => {
+ if(selectedTimeNode is PlayListPlay)
+ Prev();
+ };
+ }
+
+ private void Add(PlayListPlay plNode) {
+ playlist.Add(plNode);
+ playlistWidget.Add(plNode);
+ }
+
+ private void LoadPlaylistPlay(PlayListPlay play)
+ {
+ StartClock();
+ player.SetPlayListElement(play.MediaFile.FilePath, play.Start.MSeconds,
+ play.Stop.MSeconds, play.Rate, playlist.HasNext());
+ selectedTimeNode = play;
+ }
+
+ private bool Next() {
+ if(openedProject != null) {
+ MessagePopup.PopupMessage(playlistWidget as Gtk.Widget, MessageType.Error,
+ Catalog.GetString("Please, close the opened project to play the playlist."));
+ Stop();
+ return false;
+ }
+
+ if (!playlist.HasNext()) {
+ Stop();
+ return false;
+ }
+
+ var plNode = playlist.Next();
+ playlistWidget.SetActivePlay(plNode, playlist.GetCurrentIndex());
+
+ if (!plNode.Valid)
+ return Next();
+
+ LoadPlaylistPlay(plNode);
+ return true;
+ }
+
+ private void Prev() {
+ /* Select the previous element if we haven't played 500ms */
+ if ((player.AccurateCurrentTime - selectedTimeNode.Start.MSeconds) < 500) {
+ if (playlist.HasPrev()) {
+ var play = playlist.Prev();
+ playlistWidget.SetActivePlay(selectedTimeNode as PlayListPlay,
+ playlist.GetCurrentIndex());
+ LoadPlaylistPlay(play);
+ }
+ } else {
+ /* Seek to the beginning of the segment */
+ player.SeekTo(selectedTimeNode.Start.MSeconds,true);
+ player.Rate = selectedTimeNode.Rate;
+ }
+ }
+
+ private void StartClock() {
+ if(player!=null && !clockStarted) {
+ timeout = GLib.Timeout.Add(20,CheckStopTime);
+ clockStarted=true;
+ }
+ }
+
+ private void StopClock() {
+ if(clockStarted) {
+ GLib.Source.Remove(timeout);
+ clockStarted = false;
+ }
+ }
+
+ private bool CheckStopTime() {
+ if(player.AccurateCurrentTime >= selectedTimeNode.Stop.MSeconds-200)
+ Next();
+ return true;
+ }
+
+ private FileFilter FileFilter {
+ get {
+ FileFilter filter = new FileFilter();
+ filter.Name = Catalog.GetString("LongoMatch playlist");
+ filter.AddPattern("*" + Constants.PLAYLIST_EXT);
+ return filter;
+ }
+ }
+
+ protected virtual void OnPlayListNodeAdded(Play play)
+ {
+ Add(new PlayListPlay {
+ MediaFile = openedProject.Description.File,
+ Drawings = play.Drawings,
+ Start = play.Start,
+ Stop = play.Stop,
+ Name = play.Name,
+ Rate = 1.0f,
+ });
+ }
+
+ protected virtual void OnSavePlaylist()
+ {
+ if(playlist != null) {
+ playlist.Save();
+ }
+ }
+
+ protected virtual void OnOpenPlaylist()
+ {
+ FileChooserDialog fChooser = new FileChooserDialog(Catalog.GetString("Open playlist"),
+ (Gtk.Window)(playlistWidget as Gtk.Widget).Toplevel,
+ FileChooserAction.Open,
+ "gtk-cancel",ResponseType.Cancel,
+ "gtk-open",ResponseType.Accept);
+ fChooser.SetCurrentFolder(Config.PlayListDir());
+ fChooser.AddFilter(FileFilter);
+ fChooser.DoOverwriteConfirmation = true;
+ if(fChooser.Run() == (int)ResponseType.Accept)
+ Load(fChooser.Filename);
+ fChooser.Destroy();
+ }
+
+ protected virtual void OnNewPlaylist()
+ {
+ FileChooserDialog fChooser = new FileChooserDialog(Catalog.GetString("New playlist"),
+ (Gtk.Window)(playlistWidget as Gtk.Widget).Toplevel,
+ FileChooserAction.Save,
+ "gtk-cancel",ResponseType.Cancel,
+ "gtk-save",ResponseType.Accept);
+ fChooser.SetCurrentFolder(Config.PlayListDir());
+ fChooser.AddFilter(FileFilter);
+
+ if(fChooser.Run() == (int)ResponseType.Accept)
+ Load(fChooser.Filename);
+ fChooser.Destroy();
+ }
+ }
+}
+
diff --git a/LongoMatch.Services/Services/ProjectsManager.cs b/LongoMatch.Services/Services/ProjectsManager.cs
new file mode 100644
index 0000000..abdd74c
--- /dev/null
+++ b/LongoMatch.Services/Services/ProjectsManager.cs
@@ -0,0 +1,505 @@
+//
+// Copyright (C) 2010 Andoni Morales Alastruey
+//
+// This program 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.
+//
+// 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
+// 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, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+
+using System;
+using System.Collections.Generic;
+using System.IO;
+using Gtk;
+using Mono.Unix;
+
+using LongoMatch.Common;
+using LongoMatch.Gui;
+using LongoMatch.Gui.Dialog;
+using LongoMatch.Store;
+using LongoMatch.Store.Templates;
+using LongoMatch.Video;
+using LongoMatch.Video.Utils;
+using LongoMatch.Multimedia.Interfaces;
+using LongoMatch.Video.Common;
+using LongoMatch.Multimedia.Utils;
+
+namespace LongoMatch.Services
+{
+
+
+ public class ProjectsManager
+ {
+ Project openedProject;
+ MainWindow mainWindow;
+
+ public ProjectsManager(MainWindow mainWindow) {
+ this.mainWindow = mainWindow;
+ }
+
+ public Project OpenedProject {
+ set {
+ openedProject = value;
+ /* FIXME: Emit ProjectChanged */
+ }
+ get {
+ return openedProject;
+ }
+ }
+ public ProjectType OpenedProjectType {
+ set;
+ get;
+ }
+
+ public CapturerBin Capturer {
+ set;
+ get;
+ }
+
+ public PlayerBin Player {
+ get;
+ set;
+ }
+
+ public void SaveCaptureProject(Project project) {
+ MessageDialog md;
+ string filePath = project.Description.File.FilePath;
+
+ Log.Debug ("Saving capture project: " + project);
+ md = new MessageDialog(mainWindow as Gtk.Window, DialogFlags.Modal,
+ MessageType.Info, ButtonsType.None,
+ Catalog.GetString("Loading newly created project..."));
+ md.Show();
+
+ /* scan the new file to build a new PreviewMediaFile with all the metadata */
+ try {
+ Log.Debug("Reloading saved file: " + filePath);
+ project.Description.File = PreviewMediaFile.DiscoverFile(filePath);
+ Core.DB.AddProject(project);
+ } catch(Exception ex) {
+ Log.Exception(ex);
+ Log.Debug ("Backing up project to file");
+ string projectFile = filePath + "-" + DateTime.Now;
+ projectFile = projectFile.Replace("-", "_").Replace(" ", "_").Replace(":", "_");
+ Project.Export(OpenedProject, projectFile);
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error,
+ Catalog.GetString("An error occured saving the project:\n")+ex.Message+ "\n\n"+
+ Catalog.GetString("The video file and a backup of the project has been "+
+ "saved. Try to import it later:\n")+
+ filePath+"\n"+projectFile);
+ }
+ /* we need to set the opened project to null to avoid calling again CloseOpendProject() */
+ /* FIXME: */
+ //project = null;
+ SetProject(project, ProjectType.FileProject, new CaptureSettings());
+ md.Destroy();
+ }
+
+ public void SaveFakeLiveProject(Project project) {
+ int response;
+ MessageDialog md;
+ FileFilter filter;
+ FileChooserDialog fChooser;
+
+ Log.Debug("Saving fake live project " + project);
+ md = new MessageDialog(mainWindow, DialogFlags.Modal, MessageType.Info, ButtonsType.Ok,
+ Catalog.GetString("The project will be saved to a file. " +
+ "You can insert it later into the database using the "+
+ "\"Import project\" function once you copied the video file " +
+ "to your computer"));
+ response = md.Run();
+ md.Destroy();
+ if(response == (int)ResponseType.Cancel)
+ return;
+
+ fChooser = new FileChooserDialog(Catalog.GetString("Save Project"),
+ mainWindow, FileChooserAction.Save,
+ "gtk-cancel",ResponseType.Cancel,
+ "gtk-save",ResponseType.Accept);
+ fChooser.SetCurrentFolder(Config.HomeDir());
+ filter = new FileFilter();
+ filter.Name = Constants.PROJECT_NAME;
+ filter.AddPattern("*.lpr");
+ fChooser.AddFilter(filter);
+ if(fChooser.Run() == (int)ResponseType.Accept) {
+ Project.Export(project, fChooser.Filename);
+ MessagePopup.PopupMessage(mainWindow, MessageType.Info,
+ Catalog.GetString("Project saved successfully."));
+ }
+ fChooser.Destroy();
+ }
+
+ public void ImportProject() {
+ Project project;
+ bool isFake, exists;
+ int res;
+ string fileName;
+ FileFilter filter;
+ NewProjectDialog npd;
+ FileChooserDialog fChooser;
+
+ Log.Debug("Importing project");
+ /* Show a file chooser dialog to select the file to import */
+ fChooser = new FileChooserDialog(Catalog.GetString("Import Project"),
+ mainWindow,
+ FileChooserAction.Open,
+ "gtk-cancel",ResponseType.Cancel,
+ "gtk-open",ResponseType.Accept);
+ fChooser.SetCurrentFolder(Config.HomeDir());
+ filter = new FileFilter();
+ filter.Name = Constants.PROJECT_NAME;
+ filter.AddPattern("*.lpr");
+ fChooser.AddFilter(filter);
+
+
+ res = fChooser.Run();
+ fileName = fChooser.Filename;
+ fChooser.Destroy();
+ /* return if the user cancelled */
+ if(res != (int)ResponseType.Accept)
+ return;
+
+ /* try to import the project and show a message error is the file
+ * is not a valid project */
+ try {
+ project = Project.Import(fileName);
+ }
+ catch(Exception ex) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error,
+ Catalog.GetString("Error importing project:")+
+ "\n"+ex.Message);
+ Log.Exception(ex);
+ return;
+ }
+
+ isFake = (project.Description.File.FilePath == Constants.FAKE_PROJECT);
+
+ /* If it's a fake live project prompt for a video file and
+ * create a new PreviewMediaFile for this project */
+ if(isFake) {
+ Log.Debug ("Importing fake live project");
+ project.Description.File = null;
+ npd = new NewProjectDialog();
+ npd.TransientFor = mainWindow;
+ npd.Use = ProjectType.EditProject;
+ npd.Project = project;
+ int response = npd.Run();
+ while(true) {
+ if(response != (int)ResponseType.Ok) {
+ npd.Destroy();
+ return;
+ } else if(npd.Project == null) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Info,
+ Catalog.GetString("Please, select a video file."));
+ response=npd.Run();
+ } else {
+ project = npd.Project;
+ npd.Destroy();
+ break;
+ }
+ }
+ }
+
+ /* If the project exists ask if we want to overwrite it */
+ if(Core.DB.Exists(project)) {
+ MessageDialog md = new MessageDialog(mainWindow,
+ DialogFlags.Modal,
+ MessageType.Question,
+ Gtk.ButtonsType.YesNo,
+ Catalog.GetString("A project already exists for the file:")+
+ project.Description.File.FilePath+ "\n" +
+ Catalog.GetString("Do you want to overwrite it?"));
+ md.Icon = Gtk.IconTheme.Default.LoadIcon("longomatch", 48, 0);
+ res = md.Run();
+ md.Destroy();
+ if(res != (int)ResponseType.Yes)
+ return;
+ exists = true;
+ } else
+ exists = false;
+
+ if(isFake)
+ CreateThumbnails(project);
+ if(exists)
+ Core.DB.UpdateProject(project);
+ else
+ Core.DB.AddProject(project);
+
+
+ MessagePopup.PopupMessage(mainWindow, MessageType.Info,
+ Catalog.GetString("Project successfully imported."));
+ }
+
+ public void CreateNewProject(out Project project, out ProjectType projectType,
+ out CaptureSettings captureSettings) {
+ ProjectSelectionDialog psd;
+ NewProjectDialog npd;
+ List<Device> devices = null;
+ int response;
+
+ Log.Debug("Creating new project");
+ /* The out parameters must be set before leaving the method */
+ project = null;
+ projectType = ProjectType.None;
+ captureSettings = new CaptureSettings();
+
+ /* Show the project selection dialog */
+ psd = new ProjectSelectionDialog();
+ psd.TransientFor = mainWindow;
+ response = psd.Run();
+ psd.Destroy();
+ if(response != (int)ResponseType.Ok)
+ return;
+ projectType = psd.ProjectType;
+
+ if(projectType == ProjectType.CaptureProject) {
+ devices = VideoDevice.ListVideoDevices();
+ if(devices.Count == 0) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error,
+ Catalog.GetString("No capture devices were found."));
+ return;
+ }
+ }
+
+ /* Show the new project dialog and wait to get a valid project
+ * or quit if the user cancel it.*/
+ npd = new NewProjectDialog();
+ npd.TransientFor = mainWindow;
+ npd.Use = projectType;
+ if(projectType == ProjectType.CaptureProject)
+ npd.Devices = devices;
+ response = npd.Run();
+ while(true) {
+ /* User cancelled: quit */
+ if(response != (int)ResponseType.Ok) {
+ npd.Destroy();
+ return;
+ }
+ /* No file chosen: display the dialog again */
+ if(npd.Project == null)
+ MessagePopup.PopupMessage(mainWindow, MessageType.Info,
+ Catalog.GetString("Please, select a video file."));
+ /* If a project with the same file path exists show a warning */
+ else if(Core.DB.Exists(npd.Project))
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error,
+ Catalog.GetString("This file is already used in another Project.")+"\n"+
+ Catalog.GetString("Select a different one to continue."));
+
+ else {
+ /* We are now ready to create the new project */
+ project = npd.Project;
+ if(projectType == ProjectType.CaptureProject)
+ captureSettings = npd.CaptureSettings;
+ npd.Destroy();
+ break;
+ }
+ response = npd.Run();
+ }
+ if(projectType == ProjectType.FileProject)
+ /* We can safelly add the project since we already checked if
+ * it can can added */
+ Core.DB.AddProject(project);
+ }
+
+ public bool SetProject(Project project, ProjectType projectType, CaptureSettings props)
+ {
+ if(OpenedProject != null)
+ CloseOpenedProject(true);
+
+ if(projectType == ProjectType.FileProject) {
+ // Check if the file associated to the project exists
+ if(!File.Exists(project.Description.File.FilePath)) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Warning,
+ Catalog.GetString("The file associated to this project doesn't exist.") + "\n"
+ + Catalog.GetString("If the location of the file has changed try to edit it with the database manager."));
+ CloseOpenedProject(true);
+ return false;
+ }
+ try {
+ Player.Open(project.Description.File.FilePath);
+ }
+ catch(GLib.GException ex) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error,
+ Catalog.GetString("An error occurred opening this project:") + "\n" + ex.Message);
+ CloseOpenedProject(true);
+ return false;
+ }
+
+ } else {
+ if(projectType == ProjectType.CaptureProject) {
+ Capturer.CaptureProperties = props;
+ try {
+ Capturer.Type = CapturerType.Live;
+ } catch(Exception ex) {
+ MessagePopup.PopupMessage(mainWindow, MessageType.Error, ex.Message);
+ CloseOpenedProject(false);
+ return false;
+ }
+ } else
+ Capturer.Type = CapturerType.Fake;
+ Capturer.Run();
+ }
+
+ OpenedProject = project;
+ OpenedProjectType = projectType;
+ mainWindow.SetProject(project, projectType, props);
+ return true;
+
+ }
+
+ /*
+ public static void ExportToCSV(Project project) {
+ FileChooserDialog fChooser;
+ FileFilter filter;
+ string outputFile;
+ CSVExport export;
+
+ fChooser = new FileChooserDialog(Catalog.GetString("Select Export File"),
+ window,
+ FileChooserAction.Save,
+ "gtk-cancel",ResponseType.Cancel,
+ "gtk-save",ResponseType.Accept);
+ fChooser.SetCurrentFolder(MainClass.HomeDir());
+ fChooser.DoOverwriteConfirmation = true;
+ filter = new FileFilter();
+ filter.Name = "CSV File";
+ filter.AddPattern("*.csv");
+ fChooser.AddFilter(filter);
+ if(fChooser.Run() == (int)ResponseType.Accept) {
+ outputFile=fChooser.Filename;
+ outputFile = System.IO.Path.ChangeExtension(outputFile,"csv");
+ export = new CSVExport(project, outputFile);
+ export.WriteToFile();
+ }
+ fChooser.Destroy();
+ }*/
+
+ public void CreateThumbnails(Project project) {
+ MultimediaFactory factory;
+ IFramesCapturer capturer;
+ BusyDialog dialog;
+
+ dialog = new BusyDialog();
+ dialog.TransientFor = mainWindow;
+ dialog.Message = Catalog.GetString("Creating video thumbnails. This can take a while.");
+ dialog.Show();
+ dialog.Pulse();
+
+ /* Create all the thumbnails */
+ factory = new MultimediaFactory();
+ capturer = factory.getFramesCapturer();
+ capturer.Open(project.Description.File.FilePath);
+ foreach(Play play in project.AllPlays()) {
+ try {
+ capturer.SeekTime(play.Start.MSeconds + ((play.Stop - play.Start).MSeconds/2),
+ true);
+ play.Miniature = capturer.GetCurrentFrame(Constants.THUMBNAIL_MAX_WIDTH,
+ Constants.THUMBNAIL_MAX_HEIGHT);
+ dialog.Pulse();
+
+ } catch (Exception ex) {
+ Log.Exception(ex);
+ }
+ }
+ capturer.Dispose();
+ dialog.Destroy();
+ }
+
+ private void CloseOpenedProject(bool save) {
+ if (save)
+ SaveProject(OpenedProject, OpenedProjectType);
+
+ if(OpenedProjectType != ProjectType.FileProject)
+ Capturer.Close();
+ else
+ Player.Close();
+
+ if(OpenedProject != null)
+ OpenedProject.Clear();
+ OpenedProject = null;
+ OpenedProjectType = ProjectType.None;
+ }
+
+ protected virtual void SaveProject(Project project, ProjectType projectType) {
+ if (project == null)
+ return;
+
+ if(projectType == ProjectType.FileProject) {
+ try {
+ Core.DB.UpdateProject(openedProject);
+ } catch(Exception e) {
+ Log.Exception(e);
+ }
+ } else if (projectType == ProjectType.FakeCaptureProject) {
+ SaveFakeLiveProject(project);
+ } else if (projectType == ProjectType.CaptureProject) {
+ SaveCaptureProject(project);
+ }
+ }
+
+ protected virtual void OnNewProject() {
+ Project project;
+ ProjectType projectType;
+ CaptureSettings captureSettings;
+
+ CreateNewProject(out project, out projectType, out captureSettings);
+ if(project != null)
+ SetProject(project, projectType, captureSettings);
+ }
+
+ protected void OnOpenProject() {
+ ProjectDescription project=null;
+ OpenProjectDialog opd = new OpenProjectDialog();
+
+ opd.TransientFor = mainWindow;
+ if(opd.Run() == (int)ResponseType.Ok)
+ project = opd.SelectedProject;
+ opd.Destroy();
+ if(project != null)
+ SetProject(Core.DB.GetProject(project.UUID), ProjectType.FileProject, new CaptureSettings());
+ }
+
+ protected void OnImportProject() {
+ ImportProject();
+ }
+
+ protected void ExportProject() {
+ /* FIXME:
+ * ExportToCSV(this, openedProject);
+ * */
+ }
+
+ protected virtual void OnSectionsTemplatesManagerActivated(object sender, System.EventArgs e)
+ {
+ var tManager = new TemplatesManager<Categories, Category>(Core.TemplatesService.CategoriesTemplateProvider,
+ Core.TemplatesService.GetTemplateEditor<Categories, Category>());
+ tManager.TransientFor = mainWindow;
+ tManager.Show();
+ }
+
+ protected virtual void OnTeamsTemplatesManagerActionActivated(object sender, System.EventArgs e)
+ {
+ var tManager = new TemplatesManager<TeamTemplate, Player>(Core.TemplatesService.TeamTemplateProvider,
+ Core.TemplatesService.GetTemplateEditor<TeamTemplate, Player>());
+ tManager.TransientFor = mainWindow;
+ tManager.Show();
+ }
+
+ protected virtual void OnDatabaseManagerActivated(object sender, System.EventArgs e)
+ {
+ Gui.Dialog.ProjectsManager pm = new Gui.Dialog.ProjectsManager(openedProject, Core.DB);
+ pm.TransientFor = mainWindow;
+ pm.Show();
+ }
+
+ }
+}
diff --git a/LongoMatch/Services/JobsManager/RenderingJobsManager.cs b/LongoMatch.Services/Services/RenderingJobsManager.cs
similarity index 83%
rename from LongoMatch/Services/JobsManager/RenderingJobsManager.cs
rename to LongoMatch.Services/Services/RenderingJobsManager.cs
index 3f019b9..d483c95 100644
--- a/LongoMatch/Services/JobsManager/RenderingJobsManager.cs
+++ b/LongoMatch.Services/Services/RenderingJobsManager.cs
@@ -21,15 +21,18 @@ using Gtk;
using Mono.Unix;
using LongoMatch.Common;
-using LongoMatch.Gui;
+using LongoMatch.Interfaces;
using LongoMatch.Gui.Component;
-using LongoMatch.Store;
+using LongoMatch.Multimedia.Interfaces;
using LongoMatch.Video;
+using LongoMatch.Store;
using LongoMatch.Video.Editor;
+using LongoMatch.Gui;
+using LongoMatch.Gui.Dialog;
-namespace LongoMatch.Services.JobsManager
+namespace LongoMatch.Services
{
- public class RenderingJobsManager
+ public class RenderingJobsManager: IRenderingJobsManager
{
/* List of pending jobs */
List<Job> jobs, pendingJobs;
@@ -44,9 +47,8 @@ namespace LongoMatch.Services.JobsManager
pendingJobs = new List<Job>();
factory = new MultimediaFactory();
this.stateBar = stateBar;
- stateBar.Cancel += delegate(object sender, EventArgs e) {
- CancelCurrentJob();
- };
+ stateBar.Cancel += (sender, e) => CancelCurrentJob();
+ stateBar.ManageJobs += (sender, e) => ManageJobs();
}
public TreeStore Model {
@@ -122,6 +124,33 @@ namespace LongoMatch.Services.JobsManager
CancelJob(currentJob);
}
+ protected void ManageJobs() {
+ RenderingJobsDialog dialog = new RenderingJobsDialog(this);
+ dialog.TransientFor = (stateBar.Toplevel as Gtk.Window);
+ dialog.Run();
+ dialog.Destroy();
+ }
+
+ public static Job ConfigureRenderingJob (PlayList playlist, Gtk.Widget parent)
+ {
+ VideoEditionProperties vep;
+ Job job = null;
+ int response;
+
+ vep = new VideoEditionProperties();
+ vep.TransientFor = (Gtk.Window)parent.Toplevel;
+ response = vep.Run();
+ while(response == (int)ResponseType.Ok && vep.EncodingSettings.OutputFile == "") {
+ MessagePopup.PopupMessage(parent, MessageType.Warning,
+ Catalog.GetString("Please, select a video file."));
+ response=vep.Run();
+ }
+ if(response ==(int)ResponseType.Ok)
+ job = new Job(playlist, vep.EncodingSettings, vep.EnableAudio, vep.TitleOverlay);
+ vep.Destroy();
+ return job;
+ }
+
private void LoadJob(Job job) {
foreach(PlayListPlay segment in job.Playlist) {
if(segment.Valid)
diff --git a/LongoMatch/Services/TemplatesService.cs b/LongoMatch.Services/Services/TemplatesService.cs
similarity index 98%
rename from LongoMatch/Services/TemplatesService.cs
rename to LongoMatch.Services/Services/TemplatesService.cs
index 1280851..3cd2c3c 100644
--- a/LongoMatch/Services/TemplatesService.cs
+++ b/LongoMatch.Services/Services/TemplatesService.cs
@@ -31,7 +31,7 @@ using LongoMatch.Store.Templates;
namespace LongoMatch.Services
{
- public class TemplatesService
+ public class TemplatesService: ITemplatesService
{
private Dictionary<Type, ITemplateProvider> dict;
private List<PlayerSubCategory> playerSubcatList;
@@ -97,9 +97,9 @@ namespace LongoMatch.Services
public ITemplateWidget<T, U> GetTemplateEditor<T, U>() where T: ITemplate<U>{
if (typeof(T) == typeof(Categories))
- return (ITemplateWidget<T, U>) new CategoriesTemplateEditorWidget ();
+ return (ITemplateWidget<T, U>) new CategoriesTemplateEditorWidget (CategoriesTemplateProvider);
if (typeof(T) == typeof(TeamTemplate))
- return (ITemplateWidget<T, U>) new TeamTemplateEditorWidget();
+ return (ITemplateWidget<T, U>) new TeamTemplateEditorWidget(TeamTemplateProvider);
return null;
}
diff --git a/LongoMatch/Handlers/VideoDrawingsManager.cs b/LongoMatch.Services/Services/VideoDrawingsManager.cs
similarity index 93%
rename from LongoMatch/Handlers/VideoDrawingsManager.cs
rename to LongoMatch.Services/Services/VideoDrawingsManager.cs
index 78497d1..87da99b 100644
--- a/LongoMatch/Handlers/VideoDrawingsManager.cs
+++ b/LongoMatch.Services/Services/VideoDrawingsManager.cs
@@ -22,21 +22,19 @@ using Gdk;
using LongoMatch.Store;
using LongoMatch.Gui;
using LongoMatch.Video.Common;
+using LongoMatch.Multimedia.Interfaces;
-
-
-
-namespace LongoMatch.Handlers
+namespace LongoMatch.Services
{
public class VideoDrawingsManager
{
- private PlayerBin player;
- private uint timeout;
- private bool inKeyFrame;
- private bool canStop;
- private Play loadedPlay;
+ PlayerBin player;
+ uint timeout;
+ bool inKeyFrame;
+ bool canStop;
+ Play loadedPlay;
public VideoDrawingsManager(PlayerBin player)
{
@@ -114,7 +112,7 @@ namespace LongoMatch.Handlers
private void ResetPlayerWindow() {
player.LogoMode = false;
player.DrawingMode = false;
- player.SetLogo(System.IO.Path.Combine(MainClass.ImagesDir(),"background.png"));
+ player.SetLogo(System.IO.Path.Combine(Config.ImagesDir(),"background.png"));
}
private bool CheckStopTime() {
diff --git a/LongoMatch.mds b/LongoMatch.mds
index cff7f01..da88d06 100644
--- a/LongoMatch.mds
+++ b/LongoMatch.mds
@@ -18,28 +18,40 @@
</Policies>
<Configurations active="Release">
<Configuration name="Debug" ctype="CombineConfiguration">
- <Entry build="True" name="LongoMatch" configuration="Debug" />
+ <Entry build="True" name="LongoMatch.GUI" configuration="Debug" />
<Entry build="True" name="libcesarplayer" configuration="Debug" />
- <Entry build="True" name="CesarPlayer" configuration="Debug" />
- <Entry build="True" name="Translations" configuration="Debug" />
+ <Entry build="True" name="LongoMatch.GUI.Multimedia" configuration="Debug" />
+ <Entry build="True" name="LongoMatch.Core" configuration="Debug" />
+ <Entry build="True" name="LongoMatch" configuration="Debug" />
+ <Entry build="True" name="LongoMatch.Multimedia" configuration="Debug" />
+ <Entry build="True" name="LongoMatch.Services" configuration="Debug" />
</Configuration>
<Configuration name="Release" ctype="CombineConfiguration">
- <Entry build="True" name="LongoMatch" configuration="Release" />
+ <Entry build="True" name="LongoMatch.GUI" configuration="Release" />
<Entry build="True" name="libcesarplayer" configuration="Release" />
- <Entry build="True" name="CesarPlayer" configuration="Release" />
- <Entry build="True" name="Translations" configuration="Release" />
+ <Entry build="True" name="LongoMatch.GUI.Multimedia" configuration="Release" />
+ <Entry build="True" name="LongoMatch.Core" configuration="Release" />
+ <Entry build="True" name="LongoMatch" configuration="Release" />
+ <Entry build="True" name="LongoMatch.Multimedia" configuration="Release" />
+ <Entry build="True" name="LongoMatch.Services" configuration="Release" />
</Configuration>
</Configurations>
<StartMode startupentry="LongoMatch" single="True">
- <Execute type="None" entry="LongoMatch" />
+ <Execute type="None" entry="LongoMatch.GUI" />
<Execute type="None" entry="libcesarplayer" />
- <Execute type="None" entry="CesarPlayer" />
- <Execute type="None" entry="Translations" />
+ <Execute type="None" entry="LongoMatch.GUI.Multimedia" />
+ <Execute type="None" entry="LongoMatch.Core" />
+ <Execute type="None" entry="LongoMatch" />
+ <Execute type="None" entry="LongoMatch.Multimedia" />
+ <Execute type="None" entry="LongoMatch.Services" />
</StartMode>
<Entries>
- <Entry filename="LongoMatch/LongoMatch.mdp" />
+ <Entry filename="LongoMatch.GUI/LongoMatch.GUI.mdp" />
<Entry filename="libcesarplayer/liblongomatch.mdp" />
- <Entry filename="CesarPlayer/CesarPlayer.mdp" />
- <Entry filename="po/Translations.mdse" />
+ <Entry filename="CesarPlayer/LongoMatch.GUI.Multimedia.mdp" />
+ <Entry filename="LongoMatch.Core/LongoMatch.Core.mdp" />
+ <Entry filename="LongoMatch/LongoMatch.mdp" />
+ <Entry filename="LongoMatch.Multimedia/LongoMatch.Multimedia.mdp" />
+ <Entry filename="LongoMatch.Services/LongoMatch.Services.mdp" />
</Entries>
</Combine>
\ No newline at end of file
diff --git a/LongoMatch/LongoMatch.mdp b/LongoMatch/LongoMatch.mdp
index 2f858ce..c5b8450 100644
--- a/LongoMatch/LongoMatch.mdp
+++ b/LongoMatch/LongoMatch.mdp
@@ -1,221 +1,30 @@
-<Project name="LongoMatch" fileversion="2.0" DefaultNamespace="LongoMatch" language="C#" clr-version="Net_2_0" targetFramework="3.5" ctype="DotNetProject">
- <Deployment.LinuxDeployData />
- <MonoDevelop.Autotools.MakefileInfo RelativeMakefileName="../CesarPlayer/Makefile.am" RelativeConfigureInPath="../">
- <BuildFilesVar Name="FILES" />
- <DeployFilesVar />
- <ResourcesVar Name="RESOURCES" />
- <OthersVar />
- <GacRefVar Name="REFERENCES" />
- <AsmRefVar Name="REFERENCES" />
- <ProjectRefVar Name="REFERENCES" />
- </MonoDevelop.Autotools.MakefileInfo>
+<Project name="LongoMatch" fileversion="2.0" DefaultNamespace="LongoMatch" language="C#" targetFramework="3.5" ctype="DotNetProject">
<Configurations active="Release">
<Configuration name="Debug" ctype="DotNetProjectConfiguration">
- <Output directory="../bin" assembly="LongoMatch.exe" assemblyKeyFile="/home/andoni/Proyectos/longomatch/LongoMatch/." />
- <Build debugmode="True" target="WinExe" />
- <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
- <CodeGeneration compiler="Mcs" warninglevel="4" optimize="True" unsafecodeallowed="False" generateoverflowchecks="True" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
+ <Output directory="../bin" assembly="LongoMatch" />
+ <Build debugmode="True" target="Exe" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" definesymbols="DEBUG" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
</Configuration>
<Configuration name="Release" ctype="DotNetProjectConfiguration">
- <Output directory="../bin" assembly="LongoMatch.exe" assemblyKeyFile="/home/andoni/Proyectos/LongoMatch/LongoMatch/." />
- <Build debugmode="True" target="WinExe" />
- <Execution consolepause="True" runwithwarnings="True" runtime="MsNet" clr-version="Net_2_0" />
- <CodeGeneration compiler="Mcs" warninglevel="3" optimize="True" unsafecodeallowed="False" generateoverflowchecks="True" generatexmldocumentation="False" additionalargs="-win32icon:images/minilogo.ico" ctype="CSharpCompilerParameters" />
+ <Output directory="../bin" assembly="LongoMatch" />
+ <Build debugmode="False" target="Exe" />
+ <Execution consolepause="False" runwithwarnings="True" runtime="MsNet" />
+ <CodeGeneration compiler="Mcs" warninglevel="4" optimize="False" unsafecodeallowed="False" generateoverflowchecks="False" generatexmldocumentation="False" ctype="CSharpCompilerParameters" />
</Configuration>
</Configurations>
<Contents>
- <File subtype="Code" name="longomatch.desktop" DeployService.Deploy="True" DeployService.TargetDirectoryId="Linux.DesktopApplications" buildaction="FileCopy" />
<File subtype="Code" buildaction="Compile" name="AssemblyInfo.cs" />
<File subtype="Code" buildaction="Compile" name="Main.cs" />
- <File subtype="Directory" buildaction="Compile" name="Gui" />
- <File subtype="Code" buildaction="Compile" name="Gui/MainWindow.cs" />
- <File subtype="Directory" buildaction="Compile" name="Handlers" />
- <File subtype="Code" buildaction="Compile" name="Handlers/Handlers.cs" />
- <File subtype="Directory" buildaction="Compile" name="IO" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/longomatch.png" DeployService.RelativeDeployPath="images/longomatch.png" DeployService.TargetDirectoryId="CommonApplicationDataRoot" />
- <File subtype="Directory" buildaction="Compile" name="images" />
- <File subtype="Code" name="images/background.png" DeployService.Deploy="True" DeployService.RelativeDeployPath="images/background.png" DeployService.TargetDirectoryId="CommonApplicationDataRoot" buildaction="FileCopy" />
- <File subtype="Directory" buildaction="Compile" name="Playlist" />
- <File subtype="Code" buildaction="Compile" name="Playlist/IPlayList.cs" />
- <File subtype="Code" buildaction="Compile" name="Playlist/PlayList.cs" />
- <File subtype="Directory" buildaction="Compile" name="Updates" />
- <File subtype="Code" buildaction="Compile" name="Updates/Updater.cs" />
- <File subtype="Code" buildaction="Compile" name="Updates/XmlUpdateParser.cs" />
- <File subtype="Code" buildaction="Compile" name="IO/CSVExport.cs" />
- <File subtype="Code" buildaction="Compile" name="Handlers/EventsManager.cs" />
- <File subtype="Code" buildaction="Compile" name="Handlers/HotKeysManager.cs" />
- <File subtype="Code" buildaction="Nothing" name="images/logo_48x48.png" DeployService.RelativeDeployPath="icons/hicolor/48x48/longomatch.png" DeployService.TargetDirectoryId="CommonApplicationDataRoot" />
- <File subtype="Code" buildaction="Compile" name="Gui/TransparentDrawingArea.cs" />
- <File subtype="Code" buildaction="Compile" name="Handlers/DrawingManager.cs" />
- <File subtype="Directory" buildaction="Compile" name="Gui/Dialog" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EditPlayerDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EditCategoryDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EntryDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/NewProjectDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/OpenProjectDialog.cs" />
- <File subtype="Directory" buildaction="Compile" name="Gui/Component" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/ProjectDetailsWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/ButtonsWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/DrawingToolBox.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/NotesWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/FramesCaptureProgressDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/HotKeySelectorDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayerProperties.cs" />
- <File subtype="Directory" buildaction="Compile" name="Gui/TreeView" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayersTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayerPropertiesTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlayListTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/PlaysTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/PlayersSelectionDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/SnapshotsDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/UpdateDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/Win32CalendarDialog.cs" />
- <File subtype="Directory" buildaction="Compile" name="Gui/Popup" />
- <File subtype="Code" buildaction="Compile" name="Gui/Popup/CalendarPopup.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Popup/MessagePopup.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TemplateEditorDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayersListTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/ProjectsManager.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayListWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/ProjectListWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TemplatesManager.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TemplatesEditorBase.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/CategoriesTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeLineWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeScale.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/VideoEditionProperties.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TimeReferenceWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoryProperties.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/PlaysListTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/DrawingWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/DrawingTool.cs" />
- <File subtype="Code" buildaction="Compile" name="Handlers/VideoDrawingsManager.cs" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/stock_draw-circle-unfilled.png" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/stock_draw-freeform-line.png" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/stock_draw-line-45.png" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/stock_draw-line-ends-with-arrow.png" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/stock_draw-rectangle-unfilled.png" />
- <File subtype="Code" buildaction="Compile" name="Common/Enums.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/TaggerDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/TagsTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TagsTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/Constants.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/ProjectSelectionDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/EndCaptureDialog.cs" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/camera-video.png" />
- <File subtype="Code" buildaction="EmbedAsResource" name="images/video.png" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/BusyDialog.cs" />
- <File subtype="Code" buildaction="EmbedAsResource" name="gtk-gui/gui.stetic" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/generated.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.MainWindow.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/ListTreeViewBase.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoriesScale.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/Cairo.cs" />
- <File subtype="Code" buildaction="Compile" name="IO/XMLReader.cs" />
- <File subtype="Directory" buildaction="Compile" name="Store" />
- <File subtype="Code" buildaction="Compile" name="Store/Project.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/ProjectDescription.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Category.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Drawing.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/HotKey.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/PixbufTimeNode.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Play.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Player.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/PlayListPlay.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Tag.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Time.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/TimeNode.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Templates/TeamTemplate.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/SerializableObject.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/SubCategory.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Templates/SubCategoryTemplate.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Templates/CategoriesTemplate.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/Log.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/ConsoleCrayon.cs" />
- <File subtype="Directory" buildaction="Compile" name="Services" />
- <File subtype="Code" buildaction="Compile" name="Services/TemplatesService.cs" />
- <File subtype="Code" buildaction="Compile" name="Interfaces/ITemplates.cs" />
- <File subtype="Code" buildaction="Compile" name="Interfaces/ISubCategory.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/SubCategoriesTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/Cloner.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/ProjectUtils.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/SubCategoryTagsEditor.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/PlayersTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/StringTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/GStreamer.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs" />
- <File subtype="Code" buildaction="Compile" name="Services/DataBase.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/TagStore.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TeamTaggerWidget.cs" />
- <File subtype="Code" buildaction="Compile" name="Interfaces/ITag.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/Images.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/CategoriesTemplateEditor.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/TeamTemplateEditor.cs" />
- <File subtype="Directory" buildaction="Compile" name="Services/JobsManager" />
- <File subtype="Code" buildaction="Compile" name="Services/JobsManager/RenderingJobsManager.cs" />
- <File subtype="Directory" buildaction="Compile" name="Services" />
- <File subtype="Code" buildaction="Compile" name="Services/JobsManager/Job.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Component/RenderingStateBar.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/RenderingJobsTreeView.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/Dialog/RenderingJobsDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs" />
- <File subtype="Code" buildaction="Compile" name="Common/GuiUtils.cs" />
+ <File subtype="Code" name="longomatch.desktop" DeployService.Deploy="True" DeployService.TargetDirectoryId="Linux.DesktopApplications" buildaction="FileCopy" />
</Contents>
<References>
- <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
- <ProjectReference type="Gac" localcopy="True" refto="System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
- <ProjectReference type="Gac" localcopy="True" refto="Mono.Cairo, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
- <ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
- <ProjectReference type="Project" localcopy="True" refto="CesarPlayer" />
- <ProjectReference type="Gac" localcopy="True" refto="atk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
- <ProjectReference type="Gac" localcopy="True" refto="gdk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
<ProjectReference type="Gac" localcopy="True" refto="glib-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
<ProjectReference type="Gac" localcopy="True" refto="gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
- <ProjectReference type="Gac" localcopy="True" refto="pango-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
- <ProjectReference type="Gac" localcopy="True" refto="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
- <ProjectReference type="Gac" localcopy="True" refto="Db4objects.Db4o, Version=7.4.121.14026, Culture=neutral, PublicKeyToken=6199cd4f203aa8eb" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Services" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.GUI" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Core" />
+ <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
+ <ProjectReference type="Project" localcopy="True" refto="LongoMatch.Multimedia" />
</References>
- <LanguageParameters StartupObject="LongoMatch.MainClass" ApplicationIcon="." CodePage="65001" ctype="CSharpProjectParameters" />
</Project>
\ No newline at end of file
diff --git a/LongoMatch/Main.cs b/LongoMatch/Main.cs
index 3599269..3c06f8c 100644
--- a/LongoMatch/Main.cs
+++ b/LongoMatch/Main.cs
@@ -22,14 +22,12 @@
using System;
using System.IO;
using Gtk;
-using LongoMatch.Common;
-using LongoMatch.DB;
+using Mono.Unix;
+
using LongoMatch.Gui;
-using LongoMatch.IO;
-using LongoMatch.Store.Templates;
using LongoMatch.Services;
-using LongoMatch.Services.JobsManager;
-using Mono.Unix;
+using LongoMatch.Common;
+using LongoMatch.Multimedia.Utils;
namespace LongoMatch
@@ -37,175 +35,23 @@ namespace LongoMatch
class MainClass
{
- private static DataBase db;
- public static TemplatesService ts;
- private static string baseDirectory;
- private static string homeDirectory;
- private static string configDirectory;
- private const string WIN32_CONFIG_FILE = "longomatch.conf";
-
+
public static void Main(string[] args)
{
- SetupBaseDir();
-
- Log.Debugging = Debugging;
- Log.Information("Starting " + Constants.SOFTWARE_NAME);
-
- //Iniciamos la internalizaciÃn
- Catalog.Init(Constants.SOFTWARE_NAME.ToLower(),RelativeToPrefix("share/locale"));
-
- //Iniciamos la aplicaciÃn
- Application.Init();
-
GLib.ExceptionManager.UnhandledException += new GLib.UnhandledExceptionHandler(OnException);
GStreamer.Init();
- if (! GStreamer.CheckInstallation())
+ if (!GStreamer.CheckInstallation())
return;
- //Comprobamos los archivos de inicio
- CheckDirs();
-
- ts = new TemplatesService(configDirectory);
-
- //Iniciamos la base de datos
- db = new DataBase(Path.Combine(DBDir(),Constants.DB_FILE));
-
- //Check for previous database
- CheckOldFiles();
-
- try {
+ //try {
MainWindow win = new MainWindow();
win.Show();
+ Core.Init(win);
Application.Run();
- } catch(Exception ex) {
- ProcessExecutionError(ex);
- }
- }
-
- public static string RelativeToPrefix(string relativePath) {
- return System.IO.Path.Combine(baseDirectory, relativePath);
- }
-
- public static string HomeDir() {
- return homeDirectory;
- }
-
- public static string PlayListDir() {
- return System.IO.Path.Combine(homeDirectory, "playlists");
- }
-
- public static string SnapshotsDir() {
- return System.IO.Path.Combine(homeDirectory, "snapshots");
- }
-
- public static string TemplatesDir() {
- return System.IO.Path.Combine(configDirectory, "templates");
- }
-
- public static string VideosDir() {
- return System.IO.Path.Combine(homeDirectory, "videos");
- }
-
- public static string TempVideosDir() {
- return System.IO.Path.Combine(configDirectory, "temp");
- }
-
- public static string ImagesDir() {
- return RelativeToPrefix("share/longomatch/images");
- }
-
- public static string DBDir() {
- return System.IO.Path.Combine(configDirectory, "db");
- }
-
- public static void CheckDirs() {
- if(!System.IO.Directory.Exists(homeDirectory))
- System.IO.Directory.CreateDirectory(homeDirectory);
- if(!System.IO.Directory.Exists(TemplatesDir()))
- System.IO.Directory.CreateDirectory(TemplatesDir());
- if(!System.IO.Directory.Exists(SnapshotsDir()))
- System.IO.Directory.CreateDirectory(SnapshotsDir());
- if(!System.IO.Directory.Exists(PlayListDir()))
- System.IO.Directory.CreateDirectory(PlayListDir());
- if(!System.IO.Directory.Exists(DBDir()))
- System.IO.Directory.CreateDirectory(DBDir());
- if(!System.IO.Directory.Exists(VideosDir()))
- System.IO.Directory.CreateDirectory(VideosDir());
- if(!System.IO.Directory.Exists(TempVideosDir()))
- System.IO.Directory.CreateDirectory(TempVideosDir());
- }
-
-
- public static void CheckOldFiles() {
- string oldDBFile= System.IO.Path.Combine(homeDirectory, "db/db.yap");
- //We supose that if the conversion as already be done successfully,
- //old DB file has been renamed to db.yap.bak
- if(File.Exists(oldDBFile)) {
- MessageDialog md = new MessageDialog(null,
- DialogFlags.Modal,
- MessageType.Question,
- Gtk.ButtonsType.YesNo,
- Catalog.GetString("Some elements from the previous version (database, templates and/or playlists) have been found.")+"\n"+
- Catalog.GetString("Do you want to import them?"));
- md.Icon=Stetic.IconLoader.LoadIcon(md, "longomatch", Gtk.IconSize.Dialog);
- if(md.Run()==(int)ResponseType.Yes) {
- md.Destroy();
- //Migrator migrator = new Migrator(homeDirectory);
- //migrator.Run();
- //migrator.Destroy();
- }
- else
- md.Destroy();
- }
- }
-
- public static DataBase DB {
- get {
- return db;
- }
- }
-
- private static void SetupBaseDir() {
- string home;
-
- if (Environment.OSVersion.Platform == PlatformID.Win32NT) {
- baseDirectory = System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory,"../");
- }
- else
- baseDirectory = System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory,"../../");
-
- /* Check for the magic file PORTABLE to check if it's a portable version
- * and the config goes in the same folder as the binaries */
- if (File.Exists(System.IO.Path.Combine(baseDirectory, Constants.PORTABLE_FILE)))
- home = baseDirectory;
- else
- home = System.Environment.GetFolderPath(Environment.SpecialFolder.Personal);
-
- homeDirectory = System.IO.Path.Combine(home,Constants.SOFTWARE_NAME);
- if (Environment.OSVersion.Platform == PlatformID.Win32NT)
- configDirectory = homeDirectory;
- else
- configDirectory = System.IO.Path.Combine(home,".longomatch");
- }
-
- private static bool? debugging = null;
- public static bool Debugging {
- get {
- if(debugging == null) {
- debugging = EnvironmentIsSet("LGM_DEBUG");
- }
- return debugging.Value;
- }
- set {
- debugging = value;
- Log.Debugging = Debugging;
- }
- }
-
- public static bool EnvironmentIsSet(string env)
- {
- return !String.IsNullOrEmpty(Environment.GetEnvironmentVariable(env));
+ //} catch(Exception ex) {
+ // ProcessExecutionError(ex);
+ //}
}
private static void OnException(GLib.UnhandledExceptionArgs args) {
@@ -219,7 +65,7 @@ namespace LongoMatch
logFile = logFile.Replace("/","-");
logFile = logFile.Replace(" ","-");
logFile = logFile.Replace(":","-");
- logFile = System.IO.Path.Combine(HomeDir(),logFile);
+ logFile = System.IO.Path.Combine(Config.HomeDir(),logFile);
if(ex.InnerException != null)
message = String.Format("{0}\n{1}\n{2}\n{3}\n{4}",ex.Message,ex.InnerException.Message,ex.Source,ex.StackTrace,ex.InnerException.StackTrace);
diff --git a/LongoMatch/Makefile.am b/LongoMatch/Makefile.am
index 621e80c..98b0212 100644
--- a/LongoMatch/Makefile.am
+++ b/LongoMatch/Makefile.am
@@ -2,177 +2,24 @@ ASSEMBLY = LongoMatch
TARGET = exe
LINK = $(REF_DEP_LONGOMATCH)
-
SOURCES = \
AssemblyInfo.cs \
- Common/Cairo.cs \
- Common/Cloner.cs \
- Common/ConsoleCrayon.cs \
- Common/Constants.cs \
- Common/Enums.cs \
- Common/GStreamer.cs \
- Common/GuiUtils.cs \
- Common/Images.cs \
- Common/Log.cs \
- Common/ProjectUtils.cs \
- Common/SerializableObject.cs \
- gtk-gui/generated.cs \
- gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs \
- gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs \
- gtk-gui/LongoMatch.Gui.Component.DrawingWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.NotesWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs \
- gtk-gui/LongoMatch.Gui.Component.PlayersListTreeWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.PlayersTaggerWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.PlayListWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.PlaysListTreeWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.ProjectDetailsWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs \
- gtk-gui/LongoMatch.Gui.Component.StringTaggerWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.TaggerWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.TagsTreeWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.TeamTaggerWidget.cs \
- gtk-gui/LongoMatch.Gui.Component.TemplatesEditorBase.cs \
- gtk-gui/LongoMatch.Gui.Component.TimeLineWidget.cs \
- gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs \
- gtk-gui/LongoMatch.Gui.Dialog.EditCategoryDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.EntryDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.FramesCaptureProgressDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.HotKeySelectorDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.NewProjectDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.OpenProjectDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.PlayersSelectionDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.ProjectSelectionDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.ProjectsManager.cs \
- gtk-gui/LongoMatch.Gui.Dialog.RenderingJobsDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.SnapshotsDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.SubCategoryTagsEditor.cs \
- gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs \
- gtk-gui/LongoMatch.Gui.Dialog.UpdateDialog.cs \
- gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs \
- gtk-gui/LongoMatch.Gui.Dialog.Win32CalendarDialog.cs \
- gtk-gui/LongoMatch.Gui.MainWindow.cs \
- gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs \
- gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs \
- Gui/Component/ButtonsWidget.cs \
- Gui/Component/CategoriesScale.cs \
- Gui/Component/CategoriesTemplateEditor.cs \
- Gui/Component/CategoryProperties.cs \
- Gui/Component/DrawingToolBox.cs \
- Gui/Component/DrawingWidget.cs \
- Gui/Component/NotesWidget.cs \
- Gui/Component/RenderingStateBar.cs \
- Gui/Component/PlayerProperties.cs \
- Gui/Component/PlayersListTreeWidget.cs \
- Gui/Component/PlayersTaggerWidget.cs \
- Gui/Component/PlayListWidget.cs \
- Gui/Component/PlaysListTreeWidget.cs \
- Gui/Component/ProjectDetailsWidget.cs \
- Gui/Component/ProjectListWidget.cs \
- Gui/Component/StringTaggerWidget.cs \
- Gui/Component/TaggerWidget.cs \
- Gui/Component/TagsTreeWidget.cs \
- Gui/Component/TeamTaggerWidget.cs \
- Gui/Component/TeamTemplateEditor.cs \
- Gui/Component/TemplatesEditorBase.cs \
- Gui/Component/TimeLineWidget.cs \
- Gui/Component/TimeReferenceWidget.cs \
- Gui/Component/TimeScale.cs \
- Gui/Dialog/BusyDialog.cs \
- Gui/Dialog/DrawingTool.cs \
- Gui/Dialog/EditCategoryDialog.cs \
- Gui/Dialog/EditPlayerDialog.cs \
- Gui/Dialog/EndCaptureDialog.cs \
- Gui/Dialog/EntryDialog.cs \
- Gui/Dialog/FramesCaptureProgressDialog.cs \
- Gui/Dialog/HotKeySelectorDialog.cs \
- Gui/Dialog/NewProjectDialog.cs \
- Gui/Dialog/OpenProjectDialog.cs \
- Gui/Dialog/PlayersSelectionDialog.cs \
- Gui/Dialog/ProjectSelectionDialog.cs \
- Gui/Dialog/ProjectsManager.cs \
- Gui/Dialog/RenderingJobsDialog.cs \
- Gui/Dialog/SnapshotsDialog.cs \
- Gui/Dialog/SubCategoryTagsEditor.cs \
- Gui/Dialog/TaggerDialog.cs \
- Gui/Dialog/TemplateEditorDialog.cs \
- Gui/Dialog/TemplatesManager.cs \
- Gui/Dialog/UpdateDialog.cs \
- Gui/Dialog/VideoEditionProperties.cs \
- Gui/Dialog/Win32CalendarDialog.cs \
- Gui/MainWindow.cs \
- Gui/Popup/CalendarPopup.cs \
- Gui/Popup/MessagePopup.cs \
- Gui/TransparentDrawingArea.cs \
- Gui/TreeView/CategoriesTreeView.cs \
- Gui/TreeView/ListTreeViewBase.cs \
- Gui/TreeView/PlayerPropertiesTreeView.cs \
- Gui/TreeView/PlayersTreeView.cs \
- Gui/TreeView/PlayListTreeView.cs \
- Gui/TreeView/PlaysTreeView.cs \
- Gui/TreeView/RenderingJobsTreeView.cs \
- Gui/TreeView/SubCategoriesTreeView.cs \
- Gui/TreeView/TagsTreeView.cs \
- Handlers/DrawingManager.cs \
- Handlers/EventsManager.cs \
- Handlers/Handlers.cs \
- Handlers/HotKeysManager.cs \
- Handlers/VideoDrawingsManager.cs \
- Interfaces/ISubCategory.cs \
- Interfaces/ITag.cs \
- Interfaces/ITemplates.cs \
- IO/CSVExport.cs \
- IO/XMLReader.cs \
- Main.cs \
- Playlist/IPlayList.cs \
- Playlist/PlayList.cs \
- Services/DataBase.cs \
- Services/JobsManager/Job.cs \
- Services/JobsManager/RenderingJobsManager.cs \
- Services/TemplatesService.cs \
- Store/Category.cs \
- Store/Drawing.cs \
- Store/HotKey.cs \
- Store/PixbufTimeNode.cs \
- Store/Play.cs \
- Store/Player.cs \
- Store/PlayListPlay.cs \
- Store/Project.cs \
- Store/ProjectDescription.cs \
- Store/SubCategory.cs \
- Store/Tag.cs \
- Store/TagStore.cs \
- Store/Templates/CategoriesTemplate.cs \
- Store/Templates/SubCategoryTemplate.cs \
- Store/Templates/TeamTemplate.cs \
- Store/Templates/Template.cs \
- Store/Time.cs \
- Store/TimeNode.cs \
- Updates/Updater.cs \
- Updates/XmlUpdateParser.cs
+ Main.cs
-IMAGES = images/longomatch.png \
- images/background.png
+IMAGES = $(top_srcdir)/images/longomatch.png \
+ $(top_srcdir)/images/background.png
-LOGO = images/logo_48x48.png
+LOGO = $(top_srcdir)/images/logo_48x48.png
RESOURCES = \
- gtk-gui/gui.stetic\
- images/longomatch.png\
- images/stock_draw-line-45.png\
- images/stock_draw-circle-unfilled.png\
- images/stock_draw-line-ends-with-arrow.png\
- images/stock_draw-rectangle-unfilled.png\
- images/stock_draw-freeform-line.png\
- images/camera-video.png\
- images/video.png
+ $(top_srcdir)/images/longomatch.png\
+ $(top_srcdir)/images/stock_draw-line-45.png\
+ $(top_srcdir)/images/stock_draw-circle-unfilled.png\
+ $(top_srcdir)/images/stock_draw-line-ends-with-arrow.png\
+ $(top_srcdir)/images/stock_draw-rectangle-unfilled.png\
+ $(top_srcdir)/images/stock_draw-freeform-line.png\
+ $(top_srcdir)/images/camera-video.png\
+ $(top_srcdir)/images/video.png
bin_SCRIPTS = longomatch
diff --git a/Makefile.am b/Makefile.am
index 181b7ee..6768733 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2,7 +2,16 @@ EXTRA_DIST =\
expansions.m4 \
env.in
-SUBDIRS = build libcesarplayer CesarPlayer LongoMatch po
+SUBDIRS = \
+ build \
+ libcesarplayer \
+ LongoMatch.Core \
+ LongoMatch.Multimedia \
+ LongoMatch.GUI.Multimedia \
+ LongoMatch.GUI \
+ LongoMatch.Services \
+ LongoMatch \
+ po
DISTCLEANFILES = intltool-extract\
intltool-merge\
diff --git a/build/build.environment.mk b/build/build.environment.mk
index 89a1386..ea84591 100644
--- a/build/build.environment.mk
+++ b/build/build.environment.mk
@@ -14,11 +14,51 @@ LINK_GLIB = $(GLIBSHARP_LIBS)
LINK_GTK = $(GTKSHARP_LIBS)
LINK_GCONF = $(GCONFSHARP_LIBS)
LINK_DB40 = $(DB4O_LIBS)
-LINK_CESARPLAYER = -r:$(DIR_BIN)/CesarPlayer.dll
+LINK_LONGOMATCH_CORE = -r:$(DIR_BIN)/LongoMatch.Core.dll
+LINK_LONGOMATCH_MULTIMEDIA = -r:$(DIR_BIN)/LongoMatch.Multimedia.dll
+LINK_LONGOMATCH_GUI_MULTIMEDIA = -r:$(DIR_BIN)/LongoMatch.GUI.Multimedia.dll
+LINK_LONGOMATCH_GUI = -r:$(DIR_BIN)/LongoMatch.GUI.dll
+LINK_LONGOMATCH_SERVICES = -r:$(DIR_BIN)/LongoMatch.Services.dll
-REF_DEP_CESARPLAYER = $(LINK_GLIB) \
- $(LINK_GTK) \
- $(LINK_MONO_POSIX)
+REF_DEP_LONGOMATCH_CORE = \
+ $(LINK_MONO_POSIX) \
+ $(LINK_GLIB) \
+ $(LINK_GTK) \
+ $(LINK_CAIRO)
+
+REF_DEP_LONGOMATCH_MULTIMEDIA = \
+ $(LINK_MONO_POSIX) \
+ $(LINK_GLIB) \
+ $(LINK_GTK) \
+ $(LINK_LONGOMATCH_CORE)
+
+REF_DEP_LONGOMATCH_GUI_MULTIMEDIA = \
+ $(LINK_MONO_POSIX) \
+ $(LINK_GLIB) \
+ $(LINK_GTK) \
+ $(LINK_CAIRO) \
+ $(LINK_LONGOMATCH_CORE) \
+ $(LINK_LONGOMATCH_MULTIMEDIA)
+
+REF_DEP_LONGOMATCH_GUI = \
+ $(LINK_MONO_POSIX) \
+ $(LINK_GLIB) \
+ $(LINK_GTK) \
+ $(LINK_CAIRO) \
+ $(LINK_LONGOMATCH_CORE) \
+ $(LINK_LONGOMATCH_MULTIMEDIA) \
+ $(LINK_LONGOMATCH_GUI_MULTIMEDIA)
+
+REF_DEP_LONGOMATCH_SERVICES = \
+ $(LINK_MONO_POSIX) \
+ $(LINK_DB40) \
+ $(LINK_GLIB) \
+ $(LINK_GTK) \
+ $(LINK_CAIRO) \
+ $(LINK_LONGOMATCH_CORE) \
+ $(LINK_LONGOMATCH_MULTIMEDIA) \
+ $(LINK_LONGOMATCH_GUI) \
+ $(LINK_LONGOMATCH_GUI_MULTIMEDIA)
REF_DEP_LONGOMATCH = \
$(LINK_MONO_POSIX) \
@@ -26,7 +66,11 @@ REF_DEP_LONGOMATCH = \
$(LINK_GLIB) \
$(LINK_GTK) \
$(LINK_CAIRO) \
- $(LINK_CESARPLAYER)
+ $(LINK_LONGOMATCH_CORE) \
+ $(LINK_LONGOMATCH_MULTIMEDIA) \
+ $(LINK_LONGOMATCH_SERVICES) \
+ $(LINK_LONGOMATCH_GUI)
+
DIR_BIN = $(top_builddir)/bin
diff --git a/configure.ac b/configure.ac
index aa3cf20..cd269ee 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
dnl Warning: This is an automatically generated file, do not edit!
dnl Process this file with autoconf to produce a configure script.
AC_PREREQ([2.54])
-AC_INIT([LongoMatch], [0.17.1])
+AC_INIT([LongoMatch], [0.17.2])
AM_INIT_AUTOMAKE([foreign])
AM_MAINTAINER_MODE
@@ -98,11 +98,11 @@ build/m4/shave/shave-libtool
libcesarplayer/Makefile
-CesarPlayer/Makefile
-CesarPlayer/cesarplayer.pc
-CesarPlayer/CesarPlayer.dll.config
-CesarPlayer/AssemblyInfo.cs
-
+LongoMatch.Core/Makefile
+LongoMatch.Multimedia/Makefile
+LongoMatch.GUI.Multimedia/Makefile
+LongoMatch.GUI/Makefile
+LongoMatch.Services/Makefile
LongoMatch/Makefile
LongoMatch/longomatch
LongoMatch/longomatch.desktop.in
diff --git a/LongoMatch/images/background.png b/images/background.png
similarity index 100%
rename from LongoMatch/images/background.png
rename to images/background.png
diff --git a/LongoMatch/images/background.svg b/images/background.svg
similarity index 100%
rename from LongoMatch/images/background.svg
rename to images/background.svg
diff --git a/LongoMatch/images/camera-video.png b/images/camera-video.png
similarity index 100%
rename from LongoMatch/images/camera-video.png
rename to images/camera-video.png
diff --git a/LongoMatch/images/logo.svg b/images/logo.svg
similarity index 100%
rename from LongoMatch/images/logo.svg
rename to images/logo.svg
diff --git a/LongoMatch/images/logo_48x48.png b/images/logo_48x48.png
similarity index 100%
rename from LongoMatch/images/logo_48x48.png
rename to images/logo_48x48.png
diff --git a/LongoMatch/images/longomatch.png b/images/longomatch.png
similarity index 100%
rename from LongoMatch/images/longomatch.png
rename to images/longomatch.png
diff --git a/LongoMatch/images/minilogo.ico b/images/minilogo.ico
similarity index 100%
rename from LongoMatch/images/minilogo.ico
rename to images/minilogo.ico
diff --git a/LongoMatch/images/minilogo.png b/images/minilogo.png
similarity index 100%
rename from LongoMatch/images/minilogo.png
rename to images/minilogo.png
diff --git a/LongoMatch/images/minilogo.rc b/images/minilogo.rc
similarity index 100%
rename from LongoMatch/images/minilogo.rc
rename to images/minilogo.rc
diff --git a/LongoMatch/images/resource.h b/images/resource.h
similarity index 100%
rename from LongoMatch/images/resource.h
rename to images/resource.h
diff --git a/LongoMatch/images/stock_draw-circle-unfilled.png b/images/stock_draw-circle-unfilled.png
similarity index 100%
rename from LongoMatch/images/stock_draw-circle-unfilled.png
rename to images/stock_draw-circle-unfilled.png
diff --git a/LongoMatch/images/stock_draw-freeform-line.png b/images/stock_draw-freeform-line.png
similarity index 100%
rename from LongoMatch/images/stock_draw-freeform-line.png
rename to images/stock_draw-freeform-line.png
diff --git a/LongoMatch/images/stock_draw-line-45.png b/images/stock_draw-line-45.png
similarity index 100%
rename from LongoMatch/images/stock_draw-line-45.png
rename to images/stock_draw-line-45.png
diff --git a/LongoMatch/images/stock_draw-line-ends-with-arrow.png b/images/stock_draw-line-ends-with-arrow.png
similarity index 100%
rename from LongoMatch/images/stock_draw-line-ends-with-arrow.png
rename to images/stock_draw-line-ends-with-arrow.png
diff --git a/LongoMatch/images/stock_draw-rectangle-unfilled.png b/images/stock_draw-rectangle-unfilled.png
similarity index 100%
rename from LongoMatch/images/stock_draw-rectangle-unfilled.png
rename to images/stock_draw-rectangle-unfilled.png
diff --git a/LongoMatch/images/video.png b/images/video.png
similarity index 100%
rename from LongoMatch/images/video.png
rename to images/video.png
diff --git a/libcesarplayer/video-utils.c b/libcesarplayer/video-utils.c
index ef8d619..9053db8 100644
--- a/libcesarplayer/video-utils.c
+++ b/libcesarplayer/video-utils.c
@@ -5,6 +5,7 @@
#include <glib/gi18n.h>
#include <libintl.h>
+#include <gst/gst.h>
#include <gdk/gdk.h>
#include <stdlib.h>
#include <unistd.h>
@@ -234,3 +235,9 @@ totem_ratio_fits_screen (GdkWindow * video_window, int video_width,
return TRUE;
}
+
+void
+init_backend (int argc, char **argv)
+{
+ gst_init(&argc, &argv);
+}
diff --git a/libcesarplayer/video-utils.h b/libcesarplayer/video-utils.h
index db17113..0fc074c 100644
--- a/libcesarplayer/video-utils.h
+++ b/libcesarplayer/video-utils.h
@@ -2,6 +2,12 @@
#include <gdk/gdk.h>
#include <gtk/gtk.h>
+#ifdef WIN32
+#define EXPORT __declspec (dllexport)
+#else
+#define EXPORT
+#endif
+
#define TOTEM_OBJECT_HAS_SIGNAL(obj, name) (g_signal_lookup (name, g_type_from_name (G_OBJECT_TYPE_NAME (obj))) != 0)
void totem_gdk_window_set_invisible_cursor (GdkWindow * window);
@@ -17,3 +23,5 @@ void totem_widget_set_preferred_size (GtkWidget * widget, gint width,
gint height);
gboolean totem_ratio_fits_screen (GdkWindow * window, int video_width,
int video_height, gfloat ratio);
+
+EXPORT void init_backend (int argc, char **argv);
diff --git a/po/Translations.mdse b/po/Translations.mdse
index 841ddda..02571ff 100644
--- a/po/Translations.mdse
+++ b/po/Translations.mdse
@@ -3,11 +3,11 @@
<Configuration name="Release" ctype="TranslationProjectConfiguration" />
<Configuration name="Debug" ctype="TranslationProjectConfiguration" />
</Configurations>
- <projectInformations>
- <TranslationProjectInformation projectName="libcesarplayer" isIncluded="False" />
- </projectInformations>
<translations>
<Translation isoCode="es" />
<Translation isoCode="fr" />
</translations>
+ <projectInformations>
+ <TranslationProjectInformation projectName="libcesarplayer" isIncluded="False" />
+ </projectInformations>
</CombineEntry>
\ No newline at end of file
diff --git a/tools/deb-pkg.sh b/tools/deb-pkg.sh
index 5128cb1..fbf87e1 100755
--- a/tools/deb-pkg.sh
+++ b/tools/deb-pkg.sh
@@ -38,6 +38,6 @@ echo "Create changelog dch --create --empty -v $PKG_VERSION~$DEB_RELEASE --pack
dch --create -v $PKG_VERSION~$DEB_RELEASE --package $PKG_NAME --distribution $DIST
dpkg-buildpackage -S
cd $BUILD_DIR
-dput my-ppa $PKG_NAME\_$PKG_VERSION~$DEB_RELEASE\_source.changes
+dput ppa:ylatuya/longomatch-dev $PKG_NAME\_$PKG_VERSION~$DEB_RELEASE\_source.changes
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]