示例#1
0
        void c_HotSelect(object sender, EventArgs e)
        {
            TriggerParameterControl c = sender as TriggerParameterControl;
            //ToolTip t = mToolTipGroup.GetToolTip(c.Parent.GetHashCode());
            ToolTip t       = mToolTipGroup.GetToolTip(c.GetHashCode());
            string  message = c.GetValue().Type + ": \"" + c.GetVariable().Name + "\"";

            t.UseAnimation = false;
            t.UseFading    = false;
            //t.Show(message, c, -120, 0, 3000);
            t.Show(message, c, 130, 0, 3000);
        }
示例#2
0
 void c_HotSelect(object sender, EventArgs e)
 {
     try
     {
         //return;
         TriggerParameterControl c = sender as TriggerParameterControl;
         //ToolTip t = mToolTipGroup.GetToolTip(c.Parent.GetHashCode());//new ToolTip();
         ToolTip t = mToolTipGroup.GetToolTip(c.GetHashCode());//new ToolTip();
         Point   p = c.PointToScreen(new Point(0, 0));
         p = this.PointToClient(p);
         string message = c.GetValue().Type + ": \"" + c.GetVariable().Name + "\"";
         t.UseAnimation = false;
         t.UseFading    = false;
         t.Show(message, this, 140, p.Y - 2, 3000);
     }
     catch (System.Exception ex)
     {
         MessageBox.Show("Emergency save to crap1.triggerscript");
         System.Xml.Serialization.XmlSerializer s = new System.Xml.Serialization.XmlSerializer(typeof(TriggerRoot), new Type[] { });
         System.IO.Stream st = System.IO.File.Open(System.IO.Path.Combine(CoreGlobals.getWorkPaths().mScriptTriggerDirectory, "crap1.triggerscript"), System.IO.FileMode.Create);
         s.Serialize(st, mParentTriggerNamespace.TriggerData);
         st.Close();
     }
 }