From f7a7920bce1331c30b9a9505208f7b38434c4c62 Mon Sep 17 00:00:00 2001 From: tzim Date: Tue, 11 Feb 2014 14:53:46 +0000 Subject: [PATCH] * DMX2.SeqMacroUI.cs: * SeqMacroUI.cs: * gui.stetic: Modif sur label macro --- DMX-2.0/SeqMacroUI.cs | 13 ++++++++++--- DMX-2.0/gtk-gui/DMX2.SeqMacroUI.cs | 2 ++ DMX-2.0/gtk-gui/gui.stetic | 2 ++ 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/DMX-2.0/SeqMacroUI.cs b/DMX-2.0/SeqMacroUI.cs index 167f243..b247cb6 100644 --- a/DMX-2.0/SeqMacroUI.cs +++ b/DMX-2.0/SeqMacroUI.cs @@ -299,9 +299,9 @@ namespace DMX2 if (DateTime.Now > nextMaj ) { nextMaj = DateTime.Now.AddMilliseconds(500); StringBuilder str = new StringBuilder (); - bool a = false; + bool a = false; int val; foreach (Circuit c in sequenceur.Circuits) { - if (sequenceur.ValeurCircuit (c) > 0) { + if ((val=sequenceur.ValeurCircuit (c)) > 0) { if (sequenceur.EstActif (c) != a) { if(!a){ str.Append (""); @@ -311,7 +311,7 @@ namespace DMX2 a = false; } } - str.Append (c.ID); str.Append (' '); + str.Append (string.Format("{0}({1}) ",c.ID,val)); } } if (a) { @@ -422,8 +422,15 @@ namespace DMX2 { sequenceur.CommandDirecte(txtCommand.Text ); + } + + + protected void OnHbox2SizeAllocated (object o, SizeAllocatedArgs args) + { + actLabel.SetSizeRequest ( Math.Max(50, args.Allocation.Width - posLabel.Allocation.Width - timeLabel.Allocation.Width - 50),-1); } + } } diff --git a/DMX-2.0/gtk-gui/DMX2.SeqMacroUI.cs b/DMX-2.0/gtk-gui/DMX2.SeqMacroUI.cs index 2f1d71c..c93c8c5 100644 --- a/DMX-2.0/gtk-gui/DMX2.SeqMacroUI.cs +++ b/DMX-2.0/gtk-gui/DMX2.SeqMacroUI.cs @@ -87,6 +87,7 @@ namespace DMX2 this.evBBox.Name = "evBBox"; // Container child evBBox.Gtk.Container+ContainerChild this.hbox2 = new global::Gtk.HBox (); + this.hbox2.WidthRequest = 300; this.hbox2.Name = "hbox2"; this.hbox2.Spacing = 6; // Container child hbox2.Gtk.Box+BoxChild @@ -257,6 +258,7 @@ namespace DMX2 this.mediaPauseAction.Activated += new global::System.EventHandler (this.OnMediaPauseActionActivated); this.btnAjoutLigne.Activated += new global::System.EventHandler (this.OnBtnAjoutLigneActivated); this.btnRetireligne.Activated += new global::System.EventHandler (this.OnRemoveLigneActivated); + this.hbox2.SizeAllocated += new global::Gtk.SizeAllocatedHandler (this.OnHbox2SizeAllocated); this.seqMasterScale.ValueChanged += new global::System.EventHandler (this.OnSeqMasterScaleValueChanged); this.btnCommand.Clicked += new global::System.EventHandler (this.OnBtnCommandClicked); this.effetsListe.CursorChanged += new global::System.EventHandler (this.OnEffetsListeCursorChanged); diff --git a/DMX-2.0/gtk-gui/gui.stetic b/DMX-2.0/gtk-gui/gui.stetic index faf948e..4d78247 100644 --- a/DMX-2.0/gtk-gui/gui.stetic +++ b/DMX-2.0/gtk-gui/gui.stetic @@ -1668,7 +1668,9 @@ au sequenceur + 300 6 +