lcl: formatting

git-svn-id: trunk@19937 -
This commit is contained in:
paul 2009-05-12 05:59:22 +00:00
parent 3e258b4ef8
commit ae839602c2
4 changed files with 20 additions and 15 deletions

View File

@ -934,14 +934,14 @@ begin
Result := ResBtnCalendar;
end;
procedure TDateEdit.DoButtonClick(Sender:TObject);//or onClick
procedure TDateEdit.DoButtonClick(Sender: TObject);//or onClick
var
PopupOrigin:TPoint;
PopupOrigin: TPoint;
begin
inherited DoButtonClick(Sender);
PopupOrigin:=ControlToScreen(Point(0, Height));
if Trim(Text)=EmptyStr then
PopupOrigin := ControlToScreen(Point(0, Height));
if Trim(Text) = EmptyStr then
ShowCalendarPopup(PopupOrigin, Now, @CalendarPopupReturnDate)
else
ShowCalendarPopup(PopupOrigin, Date, @CalendarPopupReturnDate)

View File

@ -879,15 +879,18 @@ end;
------------------------------------------------------------------------------}
procedure TCustomForm.SetZOrder(Topmost: Boolean);
begin
if Parent=nil then begin
if TopMost and HandleAllocated then begin
if (Screen.GetCurrentModalForm<>nil)
and (Screen.GetCurrentModalForm<>Self) then exit;
if Parent = nil then
begin
if TopMost and HandleAllocated then
begin
if (Screen.GetCurrentModalForm <> nil) and (Screen.GetCurrentModalForm <> Self) then
Exit;
//TODO: call TWSCustomFormClass(Widgetset).SetZORder.
Screen.MoveFormToZFront(Self);
SetForegroundWindow(Handle);
end;
end else
end
else
inherited SetZOrder(Topmost);
end;

View File

@ -3088,11 +3088,13 @@ end;
------------------------------------------------------------------------------}
function TWin32WidgetSet.SetFocus(HWnd: HWND): HWND;
begin
{ if Windows.GetFocus <> HWnd then
{
if Windows.GetFocus <> HWnd then
begin
DebugLn(['TWin32WidgetSet.SetFocus ']);
DebugLn(['TWin32WidgetSet.SetFocus ', ' Wnd = ', WndClassName(HWnd)]);
DumpStack;
end;}
end;
}
Result := Windows.SetFocus(HWnd);
end;

View File

@ -1513,10 +1513,10 @@ begin
end;
procedure DumpStack;
Begin
if assigned(DebugText) then
begin
if Assigned(DebugText) then
Dump_Stack(DebugText^, get_frame);
End;
end;
function GetStackTrace(UseCache: boolean): string;
var