Răsfoiți Sursa

+ ResizeApplication pethod for fvision

pierre 23 ani în urmă
părinte
comite
44c8bff736
3 a modificat fișierele cu 39 adăugiri și 2 ștergeri
  1. 10 1
      ide/fpide.pas
  2. 16 1
      ide/fpmwnd.inc
  3. 13 0
      ide/test.pas

+ 10 - 1
ide/fpide.pas

@@ -106,6 +106,7 @@ type
       procedure CodeTemplates;
       procedure BrowserOptions(Browser: PBrowserWindow);
       procedure DesktopOptions;
+      procedure ResizeApplication(x, y : longint);
       procedure Mouse;
       procedure StartUp;
       procedure Colors;
@@ -710,6 +711,10 @@ begin
              cmHelpFiles     : HelpFiles;
              cmAbout         : About;
              cmShowReadme    : ShowReadme;
+{$ifdef FVISION}
+             cmResizeApp     : ResizeApplication(Event.Id, Event.InfoWord);
+             cmQuitApp       : Message(@Self, evCommand, cmQuitApp, nil);
+{$endif FVISION}
            else DontClear:=true;
            end;
            if DontClear=false then ClearEvent(Event);
@@ -1183,6 +1188,7 @@ begin
   InsideDone:=true;
   IsRunning:=false;
   inherited Done;
+  Desktop:=nil;
   RemoveBrowsersCollection;
   DoneHelpSystem;
 end;
@@ -1190,7 +1196,10 @@ end;
 END.
 {
   $Log$
-  Revision 1.12  2002-05-29 22:38:13  pierre
+  Revision 1.13  2002-05-30 15:03:23  pierre
+   + ResizeApplication pethod for fvision
+
+  Revision 1.12  2002/05/29 22:38:13  pierre
    Asciitab now in fvision
 
   Revision 1.11  2002/04/25 13:34:17  pierre

+ 16 - 1
ide/fpmwnd.inc

@@ -25,6 +25,18 @@ begin
   Desktop^.ForEach(@SendClose);
 end;
 
+procedure TIDEApp.ResizeApplication(x, y : longint);
+var
+  OldR, R : TRect;
+begin
+  GetBounds(OldR);
+  R.A.X:=0;
+  R.B.X:=X;
+  R.A.Y:=0;
+  R.B.Y:=Y;
+  ChangeBounds(R);
+  ReDraw;
+end;
 
 type
     PWindowListBox = ^TWindowListBox;
@@ -242,7 +254,10 @@ end;
 
 {
   $Log$
-  Revision 1.1  2001-08-04 11:30:23  peter
+  Revision 1.2  2002-05-30 15:03:24  pierre
+   + ResizeApplication pethod for fvision
+
+  Revision 1.1  2001/08/04 11:30:23  peter
     * ide works now with both compiler versions
 
   Revision 1.1.2.8  2001/03/12 17:34:56  pierre

+ 13 - 0
ide/test.pas

@@ -7,6 +7,7 @@ uses
   dpmiexcp,
 {$endif}
     test1, Test2;
+    
 
 const A =  1234;
       C =  #1#2#3#4;
@@ -45,9 +46,12 @@ type
 
       TClass = class
         constructor Create;
+        name : string;
       end;
 
       TClass2 = class(TClass)
+        constructor Create;
+        X : longint;
       end;
 
       EnumTyp = (enum1,enum2,enum3);
@@ -114,6 +118,13 @@ end;
 
 constructor TClass.Create;
 begin
+  Name:='TClass instance';
+end;
+
+constructor TClass2.Create;
+begin
+  Name:='TClass2 instance';
+  X:=7;
 end;
 
 function Func1(x,z : word; var y : boolean; const r: TRecord): shortint;
@@ -143,8 +154,10 @@ begin
 end;
 
 var i : longint;
+    Length : longint;
 
 BEGIN
+  ClassVar1:=TClass2.create;
   X:=nil;
   for i:=1 to 2000 do
     CharArray[i]:=chr(32+(i mod (255-32)));