//-------------------------------------------------- public void Init(CParametrageNiveau niveau) { m_niveau = niveau; if (m_niveau == null) { Visible = false; return; } m_lblLibelle.Text = m_niveau.Libelle; //m_lblPrefixe.Text = m_niveau.RelationSysCoor_FormatNum.Prefixes; m_arbreVocabulaire = new CArbreVocabulaire(1, 0, ""); foreach (string strPrefixe in m_niveau.RelationSysCoor_FormatNum.PrefixesPossibles) { m_arbreVocabulaire.StockeMot(strPrefixe, ""); } m_arbreVocabulaire.TouteLaListeSurChaineVide = true; m_txtValeur.Arbre = m_arbreVocabulaire; m_txtValeur.Text = ""; m_lblUnite.Text = ""; if (m_niveau.RelationSysCoor_FormatNum.Unite != null) { m_lblUnite.Text = m_niveau.RelationSysCoor_FormatNum.Unite.Libelle; } string strAide = ""; strAide = m_niveau.PremiereReference + "->" + m_niveau.DerniereReference; m_lblAide.Text = strAide; m_tooltip.SetToolTip(m_lblAide, strAide); SetAideTooltip(); }
//////////////////////////////////////////////////////////////////////////// protected static void OnReceiveNotificationModif(IDonneeNotification donnee) { if (!(donnee is CDonneeNotificationModificationContexteDonnee)) { return; } //Marque tous les éléments comme étant à relire depuis la base de données CDonneeNotificationModificationContexteDonnee donneeModif = (CDonneeNotificationModificationContexteDonnee)donnee; foreach (CDonneeNotificationModificationContexteDonnee.CInfoEnregistrementModifie info in donneeModif.ListeModifications) { if (info.NomTable == CTypeActiviteActeur.c_nomTable) { lock (typeof(CLockerArbres)) { m_arbreVocabulaire = null; } return; } } }
//////////////////////////////////////////////////////////////////////////// protected static void OnReceiveNotificationAjout(IDonneeNotification donnee) { try { if (!(donnee is CDonneeNotificationAjoutEnregistrement)) { return; } //Marque tous les éléments comme étant à relire depuis la base de données CDonneeNotificationAjoutEnregistrement donneeAjout = (CDonneeNotificationAjoutEnregistrement)donnee; if (donneeAjout.NomTable == CTypeActiviteActeur.c_nomTable) { lock (typeof(CLockerArbres)) { m_arbreVocabulaire = null; } } } catch { } }