> I appreciate your effort Chris, but this patch is too far from good.
> I guess it is our fault that we documented only "major achievements" (like
> speeding up refresh) and didn't mentioned all bugs fixed. Just brief look
> shows a lot of problems that already fixed in Corel's tree.

Son of a bitch....nevermind that patch.  I sent the wrong one, the one I
sent was the same as the main wine branches version. 
Here is the *REAL* patch(s) that I intended to send.  Sorry about that... 

Wow...and now after looking at things I sent Aric the wrong patch to check as
well.

Chris





On Mon, 11 Sep 2000, you wrote:
> 
> This patch is for Codeweavers, wasn't sure if I should put my Codeweavers email
> in the changelog entry as my wpi email is likely to remain the same for years
> to come...
> 
> After rewriting WineHQ's version of the treeview control I ended up with the
> same design that Corel had.  They had put significantly more effort into parts
> other than redrawing, I felt their implementation was much cleaner so I
> ended up going back and merging all of the main branches patches into their
> version as well as fixing and implementing a few things.  Aric Stewart looked
> this over to confirm his patch for TVS_SINGLEEXPAND was properly implemented.
> 
> ChangeLog entry:
> 
> *dlls/comctl32/treeview.c,commctrl.c;include/commctrl.h
> Chris Morgan <[EMAIL PROTECTED]>
> Merged main Wine changes into Corel's treeview control rewritten by Serge
> Ivanov and Andrew Lewycky.  Fixed item focus behavior to match
> Windows.  Fixed item selection when un/expanding items.  Implemented
> WM_SETREDRAW.  Added Corel's COMCTL32_CreateToolTip() helper function to
> commctrl.c.

----------------------------------------
Content-Type: text/x-c; name="commctrl.diff"
Content-Transfer-Encoding: 8bit
Content-Description: 
----------------------------------------

----------------------------------------
Content-Type: application/x-gzip; name="treeview.c.gz"
Content-Transfer-Encoding: base64
Content-Description: 
----------------------------------------


-------------------------------------------------------


treeview.c.gz

Index: include/commctrl.h
===================================================================
RCS file: /home/wine/wine/include/commctrl.h,v
retrieving revision 1.61
diff -u -r1.61 commctrl.h
--- include/commctrl.h	2000/09/06 19:44:49	1.61
+++ include/commctrl.h	2000/09/09 00:10:41
@@ -3674,6 +3674,10 @@
 /* type and functionality of last parameter is still unknown */
 LRESULT WINAPI COMCTL32_SendNotifyEx (HWND, HWND, UINT, LPNMHDR, DWORD);
 
+/* Internal function */
+HWND COMCTL32_CreateToolTip (HWND);
+
+
 #ifdef __cplusplus
 }
 #endif
Index: dlls/comctl32/commctrl.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/commctrl.c,v
retrieving revision 1.29
diff -u -r1.29 commctrl.c
--- dlls/comctl32/commctrl.c	2000/08/09 00:41:17	1.29
+++ dlls/comctl32/commctrl.c	2000/09/09 00:10:44
@@ -1150,3 +1150,45 @@
 {
    COMCTL32_uiLang = uiLang;
 }
+
+
+/***********************************************************************
+ * COMCTL32_CreateToolTip [NOT AN API]
+ *
+ * Creates a tooltip for the control specified in hwnd and does all
+ * necessary setup and notifications.
+ *
+ * PARAMS
+ *     hwndOwner [I] Handle to the window that will own the tool tip.
+ *
+ * RETURNS
+ *     Success: Handle of tool tip window.
+ *     Failure: NULL
+ */
+HWND
+COMCTL32_CreateToolTip(HWND hwndOwner)
+{
+    HWND hwndToolTip;
+
+    hwndToolTip = CreateWindowExA(0, TOOLTIPS_CLASSA, NULL, 0,
+				  CW_USEDEFAULT, CW_USEDEFAULT,
+				  CW_USEDEFAULT, CW_USEDEFAULT, hwndOwner,
+				  0, 0, 0);
+
+    /* Send NM_TOOLTIPSCREATED notification */
+    if (hwndToolTip)
+    {
+	NMTOOLTIPSCREATED nmttc;
+
+	nmttc.hdr.hwndFrom = hwndOwner;
+	nmttc.hdr.idFrom = GetWindowLongA(hwndOwner, GWL_ID);
+	nmttc.hdr.code = NM_TOOLTIPSCREATED;
+	nmttc.hwndToolTips = hwndToolTip;
+
+	SendMessageA(GetParent(hwndOwner), WM_NOTIFY,
+		     (WPARAM)GetWindowLongA(hwndOwner, GWL_ID),
+		     (LPARAM)&nmttc);
+    }
+
+    return hwndToolTip;
+}

Reply via email to