/[gnustep]/gnustep/usr-apps/gworkspace/GWLib/Browser2.m
ViewVC logotype

Diff of /gnustep/usr-apps/gworkspace/GWLib/Browser2.m

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by esersale, Fri Sep 26 10:25:37 2003 UTC revision 1.4 by esersale, Mon Sep 29 13:20:28 2003 UTC
# Line 82  double myrintf(double a) Line 82  double myrintf(double a)
82    RELEASE (editorFont);    RELEASE (editorFont);
83    TEST_RELEASE (doubleClickSelection);    TEST_RELEASE (doubleClickSelection);
84    TEST_RELEASE (charBuffer);    TEST_RELEASE (charBuffer);
   TEST_RELEASE (waitCursor);  
85    [super dealloc];    [super dealloc];
86  }  }
87    
# Line 90  double myrintf(double a) Line 89  double myrintf(double a)
89                          visibleColumns:(int)vcols                          visibleColumns:(int)vcols
90               styleMask:(int)mask               styleMask:(int)mask
91                                                  delegate:(id)anobject                                                  delegate:(id)anobject
             remoteHost:(NSString *)rhost  
92  {  {
93    self = [super init];    self = [super init];
94                    
# Line 120  double myrintf(double a) Line 118  double myrintf(double a)
118      setPaths = [[BColumn class] instanceMethodForSelector: setPathsSel];      setPaths = [[BColumn class] instanceMethodForSelector: setPathsSel];
119    
120                  gworkspace = (id<GWProtocol>)[gwclass gworkspace];                  gworkspace = (id<GWProtocol>)[gwclass gworkspace];
   
     if (rhost) {  
       isRemote = YES;  
       ASSIGN (remoteHostName, rhost);  
       waitCursor = [[NSCursor alloc] initWithImage: [NSImage imageNamed: @"watch.tiff"]];  
       [waitCursor setHotSpot: NSMakePoint(8, 8)];  
       [NSCursor setHiddenUntilMouseMoves: NO];  
     } else {  
       isRemote = NO;  
       remoteHostName = nil;  
     }  
121                                    
122                  [self setFrame: rect];                  [self setFrame: rect];
123                  visibleColumns = vcols;                  visibleColumns = vcols;
# Line 230  double myrintf(double a) Line 217  double myrintf(double a)
217      canUpdateViews = YES;      canUpdateViews = YES;
218      [self tile];      [self tile];
219                  [self setNeedsDisplay: YES];                  [self setNeedsDisplay: YES];
     if (isRemote) {  
       [[NSCursor arrowCursor] set];  
     }  
220                  return;                  return;
221          }          }
222                    
# Line 333  double myrintf(double a) Line 317  double myrintf(double a)
317        [[self window] makeFirstResponder: matrix];        [[self window] makeFirstResponder: matrix];
318            }            }
319    }    }
     
   if (isRemote) {  
     [[NSCursor arrowCursor] set];  
   }      
320  }  }
321    
322  - (void)loadColumnZero  - (void)loadColumnZero
# Line 356  double myrintf(double a) Line 336  double myrintf(double a)
336    BColumn *bc = [[BColumn alloc] initInBrowser: self    BColumn *bc = [[BColumn alloc] initInBrowser: self
337                                         atIndex: [columns count]                                         atIndex: [columns count]
338                                   cellPrototype: cellPrototype                                   cellPrototype: cellPrototype
339                                       styleMask: style                                       styleMask: style];
                                     remoteHost: remoteHostName];  
340    [columns addObject: bc];    [columns addObject: bc];
341    [self addSubview: bc];    [self addSubview: bc];
342    if (styleMask & GWColumnIconMask) {    if (styleMask & GWColumnIconMask) {
# Line 849  double myrintf(double a) Line 828  double myrintf(double a)
828        NSString *cpath = [col currentPath];        NSString *cpath = [col currentPath];
829        BOOL is_dir = NO;        BOOL is_dir = NO;
830            
831        is_dir = [gworkspace server: remoteHostName        is_dir = [gworkspace existsAndIsDirectoryFileAtPath: cpath];
832                                  existsAndIsDirectoryFileAtPath: cpath];        
833        if (is_dir) {            if (is_dir) {    
834          if (([gworkspace server: remoteHostName isPakageAtPath: cpath] == NO)          if (([gworkspace isPakageAtPath: cpath] == NO)
835                                          || (styleMask & GWViewsPaksgesMask)) {                                          || (styleMask & GWViewsPaksgesMask)) {
836            return cpath;                              return cpath;                  
837          } else if (i > 0) {          } else if (i > 0) {
# Line 1205  double myrintf(double a) Line 1184  double myrintf(double a)
1184      [self clickOnIcon: [col myIcon] ofColumn: col];      [self clickOnIcon: [col myIcon] ofColumn: col];
1185      return;      return;
1186    }    }
   
   if (isRemote) {  
     [waitCursor set];  
   }  
1187                                                                    
1188    if ((pos == visibleColumns) && (index == ([columns count] -1))) {    if ((pos == visibleColumns) && (index == ([columns count] -1))) {
1189      NSTimer *timer;      NSTimer *timer;
# Line 1240  double myrintf(double a) Line 1215  double myrintf(double a)
1215    canUpdateViews = YES;    canUpdateViews = YES;
1216    [self tile];    [self tile];
1217    
   if (isRemote) {  
     [[NSCursor arrowCursor] set];  
   }  
   
1218  #ifndef GNUSTEP  #ifndef GNUSTEP
1219    [[self window] makeFirstResponder: self];    [[self window] makeFirstResponder: self];
1220  #endif  #endif
# Line 1266  double myrintf(double a) Line 1237  double myrintf(double a)
1237      return;      return;
1238    }    }
1239        
   if (isRemote) {  
     [waitCursor set];  
   }  
     
1240    column = [self columnBeforeColumn: col];    column = [self columnBeforeColumn: col];
1241    
1242    if (column) {    if (column) {
# Line 1288  double myrintf(double a) Line 1255  double myrintf(double a)
1255    }    }
1256        
1257    [nameEditor setBackgroundColor: [NSColor whiteColor]];    [nameEditor setBackgroundColor: [NSColor whiteColor]];
   
   if (isRemote) {  
     [[NSCursor arrowCursor] set];  
   }  
1258        
1259    [[self window] makeFirstResponder: self];    [[self window] makeFirstResponder: self];
1260  }  }
# Line 1413  double myrintf(double a) Line 1376  double myrintf(double a)
1376  #define CLEAREDITING \  #define CLEAREDITING \
1377          [self updateNameEditor]; \          [self updateNameEditor]; \
1378    return    return
   
   if (isRemote) {  
     [self updateNameEditor];  
     
     [gworkspace server: remoteHostName  
             renamePath: oldpath    
              toNewName: newpath];  
     return;  
   }  
1379        
1380    isEditingIconName = NO;    isEditingIconName = NO;
1381    [nameEditor setAlignment: NSCenterTextAlignment];    [nameEditor setAlignment: NSCenterTextAlignment];

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26