Mercurial > dwindows
comparison dwtest.c @ 2445:a773008c7c5d
iOS: Make sure the plain text UTI is used with filePicker.
Also strip off the "file://" prefixing the file path returned.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Fri, 09 Apr 2021 11:05:51 +0000 |
parents | e08968d21d45 |
children | b9d373d1ccf5 |
comparison
equal
deleted
inserted
replaced
2444:ba24ddb19a43 | 2445:a773008c7c5d |
---|---|
288 update_render(); | 288 update_render(); |
289 } | 289 } |
290 return TRUE; | 290 return TRUE; |
291 } | 291 } |
292 | 292 |
293 void read_file( void ) | 293 void read_file(void) |
294 { | 294 { |
295 int i,len; | 295 int i,len; |
296 fp = fopen(current_file, "r" ); | 296 fp = fopen(current_file, "r" ); |
297 if(fp) | 297 if(fp) |
298 { | 298 { |
299 lp = (char **)calloc( 1000,sizeof(char *)); | 299 lp = (char **)calloc(1000,sizeof(char *)); |
300 /* should test for out of memory */ | 300 /* should test for out of memory */ |
301 max_linewidth=0; | 301 max_linewidth=0; |
302 for(i = 0; i < 1000; i++) | 302 for(i=0; i<1000; i++) |
303 { | 303 { |
304 lp[i] = (char *)calloc(1, 1025); | 304 lp[i] = (char *)calloc(1, 1025); |
305 if (fgets( lp[i], 1024, fp ) == NULL) | 305 if (fgets( lp[i], 1024, fp ) == NULL) |
306 break; | 306 break; |
307 len = (int)strlen( lp[i] ); | 307 len = (int)strlen( lp[i] ); |