Exemple #1
0
        protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
        {
            ApplyEditable();

            if (e.Property == ValeurDP)
            {
                if (Intitule == true)
                {
                    xIntitule.Visibility = Visibility.Visible;
                }
                else
                {
                    xIntitule.Visibility = Visibility.Collapsed;
                }

                String Objet         = "";
                String Propriete     = "";
                String TypePropriete = "";

                if (InfosBinding(e.Property, ref Objet, ref Propriete, ref TypePropriete))
                {
                    String pIntitule = DicIntitules.Intitule(Objet, Propriete);
                    xIntitule.Text      = pIntitule + " :";
                    xValeur.ItemsSource = DicIntitules.Enum(TypePropriete);

                    String ToolTip = DicIntitules.Info(Objet, Propriete);
                    if (!String.IsNullOrWhiteSpace(ToolTip))
                    {
                        xBase.ToolTip = ToolTip;
                    }
                }
            }

            base.OnPropertyChanged(e);
        }
Exemple #2
0
        private void ListeObjet_Loaded(object sender, RoutedEventArgs e)
        {
            MajEditable();
            MajSelectedValue();

            xIntitule.Text = DicIntitules.Intitule(Objet, ProprieteValeur) + " :";

            String ToolTip = DicIntitules.Info(Objet, ProprieteValeur);
            if (!String.IsNullOrWhiteSpace(ToolTip))
                xBase.ToolTip = ToolTip;
        }
Exemple #3
0
        private void MajIntituleDerriere()
        {
            String pIntitule = DicIntitules.Intitule(Objet, ProprieteIntituleDerriere);

            if (IntituleDerriere == false)
            {
                pIntitule = pIntitule + " :";
            }

            xIntitule.Text = pIntitule;
        }
Exemple #4
0
        private void Date_Loaded(object sender, RoutedEventArgs e)
        {
            MajEditable();
            MajValeur();

            xIntitule.Text = DicIntitules.Intitule(Objet, ProprieteValeur) + " :";
            String ToolTip = DicIntitules.Info(Objet, ProprieteValeur);

            if (!String.IsNullOrWhiteSpace(ToolTip) && (Info == true))
            {
                xBase.ToolTip = ToolTip;
            }
        }
Exemple #5
0
        private void Case_Loaded(object sender, RoutedEventArgs e)
        {
            MajEditable();
            MajIntituleDerriere();
            MajValeur();

            String pIntitule = DicIntitules.Intitule(Objet, ProprieteValeur);

            if (IntituleDerriere == false)
            {
                pIntitule = pIntitule + " :";
            }

            xIntitule.Text = pIntitule;

            String ToolTip = DicIntitules.Info(Objet, ProprieteValeur);

            if (!String.IsNullOrWhiteSpace(ToolTip))
            {
                xBase.ToolTip = ToolTip;
            }
        }
Exemple #6
0
        protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
        {
            if (e.Property == ValeurDP)
            {
                if (Editable)
                {
                    xValeur.Visibility       = System.Windows.Visibility.Visible;
                    xValeur.Background       = Brushes.White;
                    xValeur.IsHitTestVisible = true;
                }
                else
                {
                    xValeur.Visibility       = System.Windows.Visibility.Visible;
                    xValeur.Background       = Brushes.Transparent;
                    xValeur.IsReadOnly       = true;
                    xValeur.BorderThickness  = new Thickness(0);
                    xValeur.IsHitTestVisible = false;
                }

                if (Orientation == System.Windows.Controls.Orientation.Horizontal)
                {
                    DockPanel.SetDock(xIntitule, Dock.Left);
                }
                else
                {
                    DockPanel.SetDock(xIntitule, Dock.Top);
                    xIntitule.HorizontalAlignment = System.Windows.HorizontalAlignment.Left;
                }

                if (Intitule)
                {
                    xIntitule.Visibility = System.Windows.Visibility.Visible;
                }
                else
                {
                    xIntitule.Visibility = System.Windows.Visibility.Collapsed;
                    xIntitule.Margin     = new Thickness(0);
                    xIntitule.Padding    = new Thickness(0);
                }

                String Objet         = "";
                String Propriete     = "";
                String TypePropriete = "";

                if (InfosBinding(e.Property, ref Objet, ref Propriete, ref TypePropriete))
                {
                    String pIntitule = DicIntitules.Intitule(Objet, Propriete);
                    xIntitule.Text = pIntitule + " :";

                    if (String.IsNullOrWhiteSpace(Valeur.ToString()) && (Editable == false))
                    {
                        xBase.Visibility = System.Windows.Visibility.Collapsed;
                    }

                    String ToolTip = DicIntitules.Info(Objet, Propriete);
                    if (!String.IsNullOrWhiteSpace(ToolTip) && (Info == true))
                    {
                        xBase.ToolTip = ToolTip;
                    }
                }
            }

            base.OnPropertyChanged(e);
        }