I don't know how to apply a patch on a windows computer. Done only once or twice on a…
Show quoted text 22 lines
Right.
Finally, I was able to commit.
Mattias

Mailing lists / lazarus / 2003-08
19 messages · 5 people ·
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
I don't know how to apply a patch on a windows computer. Done only once or twice on a…
Right.
Finally, I was able to commit.
Mattias
Now I can't compile the win32 interface. It gives the following error: The error is:…
Is the patch ok? I get
patching file win32callback.inc
Reversed (or previously applied) patch detected! Assume -R? [n]
I get "connection refused" from cvs.freepascal.org (cvs and ssh). Michael, can you check that?
Mattias
The recent RPC virus? Micha.
Yes. Luckily the servers don't run M$ software.
Michael.
I don't know how to apply a patch on a windows computer. Done only once or twice on a linux computer. Where can I get a patch utility for windows?
If you mean: Can I cut and paste line 438 to line 412? I can and it compiles.
Vincent.
Just a report, no time to look for causes. I updated the source, recompiled everything,…
Another accident on the CVS server. Micha to the rescue with another patch ;). It seems it has concatenated two lines this time. And a minor fix using HandleAllocated instead of Handle 0 which is always true, duh.
BTW: for patching I use the cygwin tools, from cygwin.com.
Example: 'patch < resize.patch' in the win32 interface directory will fix the current bug.
HTH,
Micha.
Index: win32object.inc
===================================================================
RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32object.inc,v
retrieving revision 1.83
diff -u -w -r1.83 win32object.inc
--- win32object.inc 12 Aug 2003 14:02:54 -0000 1.83
+++ win32object.inc 12 Aug 2003 15:38:43 -0000
@@ -645,7 +645,7 @@
end
else if TControl(Sender).FCompStyle = csPage then
begin
- if (Sender As TWinControl).Parent.Handle0 then
+ if (Sender As TWinControl).Parent.HandleAllocated then
begin
Windows.SendMessage((Sender As TWinControl).Parent.Handle, TCM_AdjustRect, 0, LPARAM(@R));
Left := R.Left;
@@ -657,7 +657,8 @@
// if (Windows.GetWindowLong(TWinControl(Sender).Handle, GWL_STYLE) and WS_VSCROLL) 0 then
// R.Right := R.Right + GetSystemMetrics(SM_CXVSCROLL);
// if (Windows.GetWindowLong(TWinControl(Sender).Handle, GWL_STYLE) and WS_HSCROLL) 0 then
-// R.Bottom := R.Bottom + GetSystemMetrics(SM_CYHSCROLL); ResizeChild(Sender, R.Left, R.Top, R.Right , R.Bottom);
+// R.Bottom := R.Bottom + GetSystemMetrics(SM_CYHSCROLL);
+ ResizeChild(Sender, R.Left, R.Top, R.Right , R.Bottom);
end;
end;
End;Attached is a patch to fix top position of controls (especially TComboBox) in TGroupBoxes.
I believe the patches were not applied fully, because cvs diff still generates the attached patch. How come?
Micha.
Index: win32callback.inc
=================================================================== RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32callback.inc,v retrieving revision 1.48
diff -u -w -r1.48 win32callback.inc
--- win32callback.inc 11 Aug 2003 20:18:46 -0000 1.48 +++ win32callback.inc 12 Aug 2003 09:16:43 -0000
@@ -409,6 +409,7 @@
XPos := LoWord(LParam);
YPos := HiWord(LParam);
end;+ Win32PosToLCLPos(OwnerObject, XPos, YPos);
End;
End;
//TODO:LM_MOVEPAGE,LM_MOVETOROW,LM_MOVETOCOLUMNIndex: win32listsl.inc
=================================================================== RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32listsl.inc,v retrieving revision 1.10
diff -u -w -r1.10 win32listsl.inc
--- win32listsl.inc 28 Jul 2003 06:42:42 -0000 1.10 +++ win32listsl.inc 12 Aug 2003 09:16:43 -0000
@@ -205,9 +205,6 @@
------------------------------------------------------------------------------} Procedure TWin32ListStringList.Insert(Index: Integer; Const S: String); Begin
- If (FSender.FCompStyle = csComboBox)
- and (GetCount 0) Then
- FSender.Height := (FSender.Height + (FSender.Height Div GetCount));
If FSorted Then
SendMessage(FWin32List,FFlagAddString, 0, LPARAM(PChar(S)))
Else-----Oorspronkelijk bericht----- Van: Mattias Gaertner Verzonden: dinsdag 12 augustus 2003 16:18 Finally, I was able to commit.
Just a report, no time to look for causes.
I updated the source, recompiled everything, started lazarus, the hello example and other examples and noticed that all form sizes are the same. :-(
Something has gone from almost working to almost not working, is seems. ;-)
Vincent.
Now I can't compile the win32 interface. It gives the following error: The error is:…
The patch was not applied cleanly for some reason. That Win32Pos.. call needs to be removed from the WM_NOTIFY handler and inserted into the WM_MOVE one. Attached is a patch, the patch itself contains the revisions I have used to patch against. callback=1.48, list=1.10, object=1.82.
HTH,
Micha.
Index: win32callback.inc
=================================================================== RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32callback.inc,v retrieving revision 1.48
diff -u -w -r1.48 win32callback.inc
--- win32callback.inc 11 Aug 2003 20:18:46 -0000 1.48 +++ win32callback.inc 12 Aug 2003 09:59:59 -0000
@@ -409,6 +409,7 @@
XPos := LoWord(LParam);
YPos := HiWord(LParam);
end;+ Win32PosToLCLPos(OwnerObject, XPos, YPos);
End;
End;
//TODO:LM_MOVEPAGE,LM_MOVETOROW,LM_MOVETOCOLUMN@@ -434,7 +435,6 @@
idFrom := SendMessage(HWndFrom, TCM_GETCURSEL, 0, 0);
end;
end;- Win32PosToLCLPos(OwnerObject, XPos, YPos);
End;
End;
WM_PAINT:Index: win32listsl.inc
=================================================================== RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32listsl.inc,v retrieving revision 1.10
diff -u -w -r1.10 win32listsl.inc
--- win32listsl.inc 28 Jul 2003 06:42:42 -0000 1.10 +++ win32listsl.inc 12 Aug 2003 09:59:59 -0000
@@ -205,9 +205,6 @@
------------------------------------------------------------------------------} Procedure TWin32ListStringList.Insert(Index: Integer; Const S: String); Begin
- If (FSender.FCompStyle = csComboBox)
- and (GetCount 0) Then
- FSender.Height := (FSender.Height + (FSender.Height Div GetCount));
If FSorted Then
SendMessage(FWin32List,FFlagAddString, 0, LPARAM(PChar(S)))
ElseIndex: win32object.inc
=================================================================== RCS file: /FPC/CVS/projects/lazarus/lcl/interfaces/win32/win32object.inc,v retrieving revision 1.82
diff -u -w -r1.82 win32object.inc
--- win32object.inc 11 Aug 2003 20:18:46 -0000 1.82 +++ win32object.inc 12 Aug 2003 10:00:00 -0000
@@ -653,6 +653,11 @@
end
end;
R := Rect(Left, Top, R.Right - R.Left, R.Bottom - R.Top);+ {Adjust for scrollbar}
+// if (Windows.GetWindowLong(TWinControl(Sender).Handle, GWL_STYLE) and WS_VSCROLL) 0 then +// R.Right := R.Right + GetSystemMetrics(SM_CXVSCROLL); +// if (Windows.GetWindowLong(TWinControl(Sender).Handle, GWL_STYLE) and WS_HSCROLL) 0 then +// R.Bottom := R.Bottom + GetSystemMetrics(SM_CYHSCROLL);
ResizeChild(Sender, R.Left, R.Top, R.Right , R.Bottom);
end;
end;On Tue, 12 Aug 2003 12:03:33 +0200 Is the patch ok? I get patching file win32callback.inc…
both idefix (cvs) and deadlock( ftp.freepascal.org) are having problems.
Deadlock is down totally, and idefix pings, but seems to refuse connections.
Now I can't compile the win32 interface. It gives the following error: The error is:…
I believe so. If you check Vincent's error message, it says line 437. The patch attempts to remove line 437 and add one around 412. Vincent, can you succesfully apply the patch locally?
Mattias, does cvs diff produce any output for you? Iow, is your local copy exactly the same as CVS?
I currently can't ping or reach the cvs server anymore.
Regards,
Micha.
Hi Micha,
Now I can't compile the win32 interface. It gives the following error: The error is:
win32callback.inc(437,39) Error: Identifier not found XPOS win32callback.inc(437,45) Error: Identifier not found YPOS The line involved is:
Win32PosToLCLPos(OwnerObject, XPos, YPos);Can you look into this?
Vincent.
check
Attached is a patch to fix top position of controls (especially TComboBox) in TGroupBoxes.
Applied. Thanks.
Mattias
Hi,
Attached is a patch to fix top position of controls (especially TComboBox) in TGroupBoxes.
Also fixes some AV's because I noticed that sometimes in DestroyComponent the Handle is recreated, ie. CreateWnd is called on the same control. I fixed it by removing 'Lazarus' from the property list so the callback doesn't see it anymore.
Regards,
Micha.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bin00061.bin
Type: application/octet-stream
Size: 1444 bytes
Desc: "combo_top.patch.gz"
Url : http://localhost/pipermail/lazarus/attachments/20030811/30e88f4c/bin00061.bin
Our firewall is under heavy load and refuses most connections. Most of our XP machines…
The recent RPC virus?
Micha.
Now I can't compile the win32 interface. It gives the following error: The error is:…
Yep. That was my last successful action before the server refused.
Mattias
Attached is a patch to fix top position of controls (especially TComboBox) in TGroupBoxes.
Micha Nelissen wroteHi, Attached is a patch to fix top position of controls (especially TComboBox) in TGroupBoxes.
And a patch for the patch: forgot that Sender could nil, so add a check for that one. See attached patch.
Regards,
Micha.
--- win32proc.old.inc 2003-08-11 20:49:01.000000000 +0200
+++ win32proc.inc 2003-08-11 20:47:11.000000000 +0200
@@ -715,6 +715,7 @@
DC: HDC;
Handle: HWND;
Begin
+ if Sender = nil then exit;
If (TControl(Sender).Parent Is TCustomGroupBox) Then
Begin
Handle := TControl(Sender).Parent.Handle;
@@ -731,6 +732,7 @@
DC: HDC;
Handle: HWND;
Begin
+ if Sender = nil then exit;
// check for groupbox client pos
If (TControl(Sender).Parent Is TCustomGroupBox) Then
Beginminor
fix using HandleAllocated instead of Handle 0 which is always true,
duh.
Thanks for the rescue. I patched with cut and paste. ;-) It helped.
Vincent
Just a report, no time to look for causes. I updated the source, recompiled everything,…
This time the patch applied without errors. Only the server is quite slow ..
Mattias
both idefix (cvs) and deadlock( ftp.freepascal.org) are having problems. Deadlock is down…
Our firewall is under heavy load and refuses most connections. Most of our XP machines are under heavy attack and are continuously infected with (yet another) microsoft virus or whatever the attack is using.
One day, all this M$ machines will be banished if it continues like this :/
Michael.