Changeset 137 in Sophya for trunk/SophyaPI


Ignore:
Timestamp:
Aug 18, 1998, 6:42:10 PM (27 years ago)
Author:
ercodmgr
Message:

Modifs mineures Reza 18/08/98

Location:
trunk/SophyaPI/PI
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PI/pifilechox.cc

    r52 r137  
    44#include "pisysdep.h"
    55
     6#include "piapplx.h"
    67#include "pifilechox.h"
    78
     
    4445}
    4546
    46 #define PIFC_SzX  350
    47 #define PIFC_SzY  300
    48 
     47static int PIFC_SzX, PIFC_SzY;
    4948/* --Methode-- */
    5049PIFileChooserX::PIFileChooserX(PIMsgHandler* par, char* nom, PIMessage msg)
     
    5453
    5554mWin = NULL;
    56 mWin = new PIWdgX(NULL, nom, PIFC_SzX, PIFC_SzY, 150, 150);
     55
     56int sx, sy;
     57PIApplicationPrefCompSize(sx, sy);
     58PIFC_SzX = sx*6;  PIFC_SzY = sy*10;
     59mWin = new PIWdgX(NULL, nom, PIFC_SzX, PIFC_SzY, 200, 200);
    5760mWin->CreateXtWdg(nom, topLevelShellWidgetClass, NULL, PIFC_SzX, PIFC_SzY, 200, 200);
    5861
     
    6063mFName[0] = mFName[511] = '\0';
    6164
    62 CreateXtWdg(nom, xmFileSelectionBoxWidgetClass, mWin->XtWdg(), PIFC_SzX, PIFC_SzY, 0, 0);
     65CreateXtWdg(nom, xmFileSelectionBoxWidgetClass, mWin->XtWdg(), sx, sy, 0, 0);
    6366XtAddCallback(XtWdg(), XmNokCallback,
    6467              (XtCallbackProc)filesel_okact, (XtPointer)this);
     
    9699if (acc)
    97100  {
    98   mWin->SetSize( PIFC_SzX, PIFC_SzY+75);
     101  mWin->SetSize( PIFC_SzX, PIFC_SzY*1.25);
    99102  XtManageChild(fnl);  XtManageChild(fnw);
    100103  }
    101104else
    102105  {
    103   mWin->SetSize( PIFC_SzX, PIFC_SzY+50);
     106  mWin->SetSize( PIFC_SzX, PIFC_SzY*1.1);
    104107  XtUnmanageChild(fnl); XtUnmanageChild(fnw);
    105108  }
  • trunk/SophyaPI/PI/pistzwin.cc

    r134 r137  
    33//                             R. Ansari  08/98
    44
     5#include "stdio.h"
    56
    67#include "pistzwin.h"
     
    135136{
    136137if (!child) return;
    137 if (mZWdg[mZc])  delete mZWdg[mZc];
     138// printf("-DBG-PIZoneWindow::ChildAdd(%lx) deleteing Wdg %lx \n", (long)child, (long)mZWdg[mZc]);
    138139int nx = mZc%mZx;
    139140int ny = mZc/mZx;
    140141PIWindow::ChildAdd(child);
    141 mZWdg[mZc] = child;
    142142child->SetBinding(PIBK_free,PIBK_free,PIBK_free, PIBK_free);
    143143int sx = XSize()/mZx;
     
    146146child->SetSize(sx, sy);
    147147child->SetBinding(PIBK_elastic,PIBK_elastic,PIBK_elastic, PIBK_elastic);
     148// printf("--DBG-- PIZoneWindow::ChildAdd() %d , Nx,y=%d %d , S= %d %d \n", mZc, nx, ny, sx, sy);
     149// printf("--DBG-- ... Child Pos= %d %d, Size= %d %d \n", child->XPos(), child->YPos(),child->XSize(),child->YSize()   );
     150if (mZWdg[mZc])  delete mZWdg[mZc];
     151mZWdg[mZc] = child;
    148152mZc = (mZc+1)%(mZx*mZy);
    149153}
     
    174178int ny = mZc/mZx;
    175179px = nx*sx;  py = ny*sy;
     180// printf("--DBG-- PIZoneWindow::NextChildPosSize() %d , P=%d %d , S= %d %d \n", mZc, px,py, sx, sy);
    176181}
Note: See TracChangeset for help on using the changeset viewer.