From: Bellai Ádám Date: Thu, 19 Oct 2017 12:50:54 +0000 (+0000) Subject: git-tfs-id: [http://tfs.userrendszerhaz.hu:8080/tfs/DefaultCollection]$/MediaCube... X-Git-Url: http://git.useribm.hu/?a=commitdiff_plain;h=ea2d45aca150cccc286fba15ca4ec8ade0d6e882;p=mediacube.git git-tfs-id: [tfs.userrendszerhaz.hu:8080/tfs/DefaultCollection]$/MediaCube;C30651 --- diff --git a/client/DxPlay/DxPlayer.cs b/client/DxPlay/DxPlayer.cs index ab20783a..9b310caa 100644 --- a/client/DxPlay/DxPlayer.cs +++ b/client/DxPlay/DxPlayer.cs @@ -11,6 +11,7 @@ using Microsoft.Win32.SafeHandles; using System.ComponentModel; using System.Drawing.Imaging; using System.Drawing.Drawing2D; +using System.Collections.Generic; namespace DxPlay { internal class DxPlayer : ISampleGrabberCB, IDisposable { @@ -27,6 +28,8 @@ namespace DxPlay { Exiting } + public Dictionary stateHunStringValues = new Dictionary(); + public MediaDescription MediaDescription { get; internal set; } public Timecode CurrentTC { get; internal set; } public GraphState State { get; internal set; } @@ -72,6 +75,7 @@ namespace DxPlay { // Play an avi file into a window. Allow for snapshots. // (Control to show video in, Avi file to play public DxPlayer(Control hWin, MediaDescription mediaDesc) { + FillTheHunStringvalues(); State = GraphState.Stopped; try { int hr; @@ -118,6 +122,13 @@ namespace DxPlay { } } + private void FillTheHunStringvalues() { + stateHunStringValues.Add(GraphState.Exiting, StringResource.KILEPES); + stateHunStringValues.Add(GraphState.Paused, StringResource.SZUNETELTETETT); + stateHunStringValues.Add(GraphState.Playing, StringResource.LEJATSZAS); + stateHunStringValues.Add(GraphState.Stopped, StringResource.MEGALLITVA); + } + private void TcWorker_DoWork(object sender, DoWorkEventArgs e) { while (!e.Cancel) { UpdateTC(); diff --git a/client/DxPlay/PlayerForm.Designer.cs b/client/DxPlay/PlayerForm.Designer.cs index 68d25308..7dfe2840 100644 --- a/client/DxPlay/PlayerForm.Designer.cs +++ b/client/DxPlay/PlayerForm.Designer.cs @@ -103,9 +103,9 @@ namespace DxPlay { // btnStop // this.btnStop.Image = global::DxPlay.Properties.Resources.Stop; - this.btnStop.Location = new System.Drawing.Point(66, 4); + this.btnStop.Location = new System.Drawing.Point(89, 3); this.btnStop.Name = "btnStop"; - this.btnStop.Size = new System.Drawing.Size(61, 25); + this.btnStop.Size = new System.Drawing.Size(80, 25); this.btnStop.TabIndex = 16; this.btnStop.Text = "Stop"; this.btnStop.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText; @@ -114,9 +114,9 @@ namespace DxPlay { // btnPlay // this.btnPlay.Image = global::DxPlay.Properties.Resources.Play; - this.btnPlay.Location = new System.Drawing.Point(3, 4); + this.btnPlay.Location = new System.Drawing.Point(3, 3); this.btnPlay.Name = "btnPlay"; - this.btnPlay.Size = new System.Drawing.Size(61, 25); + this.btnPlay.Size = new System.Drawing.Size(80, 25); this.btnPlay.TabIndex = 1; this.btnPlay.Text = "Play"; this.btnPlay.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText; @@ -125,9 +125,9 @@ namespace DxPlay { // btnPause // this.btnPause.Image = global::DxPlay.Properties.Resources.Pause; - this.btnPause.Location = new System.Drawing.Point(129, 4); + this.btnPause.Location = new System.Drawing.Point(175, 3); this.btnPause.Name = "btnPause"; - this.btnPause.Size = new System.Drawing.Size(61, 25); + this.btnPause.Size = new System.Drawing.Size(80, 25); this.btnPause.TabIndex = 11; this.btnPause.Text = "Pause"; this.btnPause.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText; diff --git a/client/DxPlay/PlayerForm.cs b/client/DxPlay/PlayerForm.cs index 81105327..b26d3bc0 100644 --- a/client/DxPlay/PlayerForm.cs +++ b/client/DxPlay/PlayerForm.cs @@ -32,6 +32,7 @@ namespace DxPlay { public PlayerForm() { InitializeComponent(); + InitializeTexts(); } public PlayerForm(ref BindingList segments) { @@ -48,6 +49,12 @@ namespace DxPlay { deleteSegmentToolStripMenuItem.Text = StringResource.SZEGMENS_TORLESE; menuButtonSegmentActions.Text = StringResource.SZEGMENS_AKCIÓK; + btnPause.Text = StringResource.SZUNET; + btnPlay.Text = StringResource.LEJATSZAS; + btnStop.Text = StringResource.LEALLITAS; + labelStatus.Text = StringResource.NINCS_BEMENET; + label1.Text = StringResource.INDULASI_PONT; + label2.Text = StringResource.IDOTARTAM; } private void cueue() { @@ -91,7 +98,9 @@ namespace DxPlay { if (!trackBarAtUser) trackBar1.Value = m_play.CurrentTC.ZeroBasedFrames; textCurrentTC.Text = m_play.CurrentTC.ToString(); - labelStatus.Text = m_play.State.ToString().ToUpper(); + string labelStatusText = labelStatus.Text; + m_play.stateHunStringValues.TryGetValue(m_play.State, out labelStatusText);//m_play.State.ToString().ToUpper(); + labelStatus.Text = labelStatusText; })); } diff --git a/client/DxPlay/StringResource.Designer.cs b/client/DxPlay/StringResource.Designer.cs index bb6f5c29..b7a9f3dd 100644 --- a/client/DxPlay/StringResource.Designer.cs +++ b/client/DxPlay/StringResource.Designer.cs @@ -87,6 +87,42 @@ namespace DxPlay { } } + /// + /// Looks up a localized string similar to Időtartam. + /// + internal static string IDOTARTAM { + get { + return ResourceManager.GetString("IDOTARTAM", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Indítás. + /// + internal static string INDITAS { + get { + return ResourceManager.GetString("INDITAS", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Indulási pont. + /// + internal static string INDULASI_PONT { + get { + return ResourceManager.GetString("INDULASI_PONT", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Kilépés. + /// + internal static string KILEPES { + get { + return ResourceManager.GetString("KILEPES", resourceCulture); + } + } + /// /// Looks up a localized string similar to Kimenő. /// @@ -105,6 +141,42 @@ namespace DxPlay { } } + /// + /// Looks up a localized string similar to Leállítás. + /// + internal static string LEALLITAS { + get { + return ResourceManager.GetString("LEALLITAS", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Lejátszás. + /// + internal static string LEJATSZAS { + get { + return ResourceManager.GetString("LEJATSZAS", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Megállítva. + /// + internal static string MEGALLITVA { + get { + return ResourceManager.GetString("MEGALLITVA", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to NINCS BEMENET. + /// + internal static string NINCS_BEMENET { + get { + return ResourceManager.GetString("NINCS_BEMENET", resourceCulture); + } + } + /// /// Looks up a localized string similar to Szegmens akciók. /// @@ -141,6 +213,24 @@ namespace DxPlay { } } + /// + /// Looks up a localized string similar to Szunet. + /// + internal static string SZUNET { + get { + return ResourceManager.GetString("SZUNET", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Szüneteltetett. + /// + internal static string SZUNETELTETETT { + get { + return ResourceManager.GetString("SZUNETELTETETT", resourceCulture); + } + } + /// /// Looks up a localized string similar to Választható. /// diff --git a/client/DxPlay/StringResource.resx b/client/DxPlay/StringResource.resx index fac6e8c5..ff82ae3a 100644 --- a/client/DxPlay/StringResource.resx +++ b/client/DxPlay/StringResource.resx @@ -126,12 +126,36 @@ Bemenő + + Időtartam + + + Indítás + + + Indulási pont + + + Kilépés + Kimenő Komment + + Leállítás + + + Lejátszás + + + Megállítva + + + NINCS BEMENET + Szegmens akciók @@ -144,6 +168,12 @@ Szegmens törlése + + Szunet + + + Szüneteltetett + Választható diff --git a/client/Maestro/MaestroForm.cs b/client/Maestro/MaestroForm.cs index 76456b8e..5829c36b 100644 --- a/client/Maestro/MaestroForm.cs +++ b/client/Maestro/MaestroForm.cs @@ -261,13 +261,14 @@ namespace Maestro { }); newMSGColor = color; ActivateTabOnTabControl2(1); + //ObjectExtensions.SafeCall(dataGridMessages, UpdateDataGridMessagesChanged); } private void ActivateTabOnTabControl2(int index) { ObjectExtensions.SafeCall(tabControl2, () => { tabControl2.SelectedIndex = index; }); } - private void UpdateDataChanged() { + private void UpdateDataGridMessagesChanged() { dataGridMessages.DataSource = null; dataGridMessages.DataSource = systemMessageBindingSource; } diff --git a/server/user.jobengine.osgi.commons/src/user/commons/octopus/OctopusDataMiner.java b/server/user.jobengine.osgi.commons/src/user/commons/octopus/OctopusDataMiner.java index 096b470f..c57615e5 100644 --- a/server/user.jobengine.osgi.commons/src/user/commons/octopus/OctopusDataMiner.java +++ b/server/user.jobengine.osgi.commons/src/user/commons/octopus/OctopusDataMiner.java @@ -128,6 +128,29 @@ public class OctopusDataMiner implements Runnable { modifiedStory.append(referenceName, references); } references.add(new BasicDBObject(ID, referenceID).append(POSITION, position)); + BasicDBObject script = (BasicDBObject) modifiedStory.get("script"); + String scriptContent = new String(); + if(script!= null && !script.isEmpty()) { + BasicDBList body = (BasicDBList) script.get("body"); + if(body != null && !body.isEmpty()){ + for(Object actualBody : body) { + BasicDBObject actualDBBody = (BasicDBObject) actualBody; + BasicDBList content = (BasicDBList)actualDBBody.get("content"); + if(content != null && !content.isEmpty()){ + for(Object actualContent : content) { + BasicDBObject actualDBContent = (BasicDBObject) actualContent; + String text = actualDBContent.getString("text"); + if(text != null) + scriptContent += text + "\n"; + } + + } + + } + } + + } + modifiedStory.append("script_content", scriptContent); logger.info(String.format(SAVING_STORY_D, storyID)); collection.save(modifiedStory); }