예제 #1
0
        protected bool HandleNotify(ref Message m)
        {
            if (m.LParam != IntPtr.Zero)
            {
                BrightIdeasSoftware.NativeMethods.NMHDR lParam = (BrightIdeasSoftware.NativeMethods.NMHDR)m.GetLParam(typeof(BrightIdeasSoftware.NativeMethods.NMHDR));
                switch (lParam.code)
                {
                case -522:
                    return(this.ToolTip.HandlePop(ref m));

                case -521:
                    return(this.ToolTip.HandleShow(ref m));

                case -530:
                    return(this.ToolTip.HandleGetDispInfo(ref m));
                }
            }
            return(false);
        }
예제 #2
0
 protected override void WndProc(ref Message m)
 {
     switch (m.Msg)
     {
     case 0x4e:
     case 0x204e:
     {
         BrightIdeasSoftware.NativeMethods.NMHDR nmhdr = (BrightIdeasSoftware.NativeMethods.NMHDR)Marshal.PtrToStructure(m.LParam, typeof(BrightIdeasSoftware.NativeMethods.NMHDR));
         if (nmhdr.code == -327)
         {
             try
             {
                 ((IComponentChangeService)this.GetService(typeof(IComponentChangeService))).OnComponentChanged(base.Component, null, null, null);
             }
             catch (InvalidOperationException)
             {
                 return;
             }
         }
         break;
     }
     }
     base.WndProc(ref m);
 }