[longomatch] Fix description with fake live projects
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Fix description with fake live projects
- Date: Mon, 7 Jul 2014 11:31:24 +0000 (UTC)
commit 73e2da163633d144bb5c54a4e6a7278aa0d6c927
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Sun Jun 22 13:58:44 2014 +0200
Fix description with fake live projects
LongoMatch.Core/Store/MediaFile.cs | 20 ++++++++++++--------
1 files changed, 12 insertions(+), 8 deletions(-)
---
diff --git a/LongoMatch.Core/Store/MediaFile.cs b/LongoMatch.Core/Store/MediaFile.cs
index 5dc7734..3d2d4b1 100644
--- a/LongoMatch.Core/Store/MediaFile.cs
+++ b/LongoMatch.Core/Store/MediaFile.cs
@@ -122,14 +122,18 @@ namespace LongoMatch.Store
[JsonIgnore]
public string Description {
get {
- string desc = String.Format ("<b>File path</b>: {0}\n", FilePath);
- desc += String.Format ("<b>Format</b>: {0}x{1} @ {2}fps\n", VideoWidth,
- VideoHeight, Fps);
- desc += String.Format ("<b>Duration</b>: {0}\n", Duration.ToSecondsString ());
- desc += String.Format ("<b>Video Codec</b>: {0}\n", VideoCodec);
- desc += String.Format ("<b>Audio Codec</b>: {0}\n", AudioCodec);
- desc += String.Format ("<b>Container</b>: {0}\n", Container);
- return desc;
+ if (FilePath == Constants.FAKE_PROJECT) {
+ return Catalog.GetString ("No video file associated");
+ } else {
+ string desc = String.Format ("<b>File path</b>: {0}\n", FilePath);
+ desc += String.Format ("<b>Format</b>: {0}x{1} @ {2}fps\n",
VideoWidth,
+ VideoHeight, Fps);
+ desc += String.Format ("<b>Duration</b>: {0}\n",
Duration.ToSecondsString ());
+ desc += String.Format ("<b>Video Codec</b>: {0}\n", VideoCodec);
+ desc += String.Format ("<b>Audio Codec</b>: {0}\n", AudioCodec);
+ desc += String.Format ("<b>Container</b>: {0}\n", Container);
+ return desc;
+ }
}
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]