Exemplo n.º 1
0
        void UpdateNeedsAttentionStatus()
        // Assumes changes have been Harvested to the LocAlternative
        {
            if (null == Item)
                return;
            LocAlternate alt = new LocAlternate(
                m_textYourLanguage.Text,
                m_comboShortcutKey.Text,
                m_textToolTip.Text);

            // Do the test
            string sNeedsMessage = alt.NeedsAttention(Item);
            bool bNeedsAttention = !string.IsNullOrEmpty(sNeedsMessage);

            // Update the tree node
            if (null != Tree.SelectedNode && null != Tree.SelectedNode.Tag as LocItem)
                Tree.SelectedNode.ForeColor = (bNeedsAttention ? Color.Red : Color.Navy);

            // Update the message
            m_labelNeedsAttention.Text = sNeedsMessage;
        }