summaryrefslogtreecommitdiff
path: root/camlibs/sonydscf1
diff options
context:
space:
mode:
authorLutz Mueller <lutz@users.sourceforge.net>2001-10-09 16:25:04 +0000
committerLutz Mueller <lutz@users.sourceforge.net>2001-10-09 16:25:04 +0000
commit555b67ddb6e752dc4f86810e64e987b149dcc32b (patch)
tree2155315a6ba04344f9c3ea3b4b2e3ddde6c67b27 /camlibs/sonydscf1
parentf082f4a9e338531752fcfbd1bd4f0f8c79da705f (diff)
downloadlibgphoto2-555b67ddb6e752dc4f86810e64e987b149dcc32b.tar.gz
2001-10-09 Lutz M�ller <urc8@rz.uni-karlsruhe.de>
* camlibs/agfa/agfa.c: delete_file_func, get_file_func * camlibs/canon/canon.c: Add warning that upload and deletion is broken * camlibs/jd350e/jd350e.c: Tiny update * camlibs/kodak/dc120/dc120.c: folder_list_func, file_list_func, get_file_func, delete_file_func * camlibs/kodak/dc240.c: Add warning that changes have to be made * camlibs/konica/library.c: delete_all_func, delete_file_func * camlibs/minolta/dimagev/dimagev.c: delete_file_func, put_file_func, * camlibs/panasonic/dc1000.c: file_list_func, get_file_func, put_file_func, delete_file_func * camlibs/panasonic/dc1580.c: get_file_func, put_file_func, delete_file_func * camlibs/panasonic/l859.c: delete_file_func, delete_all_func * camlibs/polaroid/pdc320.c: get_file_func, delete_all_func * camlibs/polaroid/pdc640.c: get_file_func, delete_file_func * camlibs/sierra/library.c: * camlibs/sierra/sierra.c: delete_all_func, delete_file_func * camlibs/sonydscf1/sonydscf1.c: delete_file_func * camlibs/sonydscf55/sonydscf55.c: Tiny update * camlibs/stv0680/stv0680.c: Tiny update * frontens/command-line/interface.c: Don't show "" status and 0.0 progress * libgphoto2/camera.c: * include/gphoto2-camera.h: Remove put_file, delete_all and delete - this should all be done using the filesystem. In the future, file_get and the listing functions will also disappear. * include/gphoto2-filesys.h: * libgphoto2/filesys.c: Add deletion and upload. * libgphoto2/jpeg.c: Kill unused variable * tests/test-filesys.c: Update git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@2462 67ed7778-7388-44ab-90cf-0a291f65f57c
Diffstat (limited to 'camlibs/sonydscf1')
-rw-r--r--camlibs/sonydscf1/sonydscf1.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/camlibs/sonydscf1/sonydscf1.c b/camlibs/sonydscf1/sonydscf1.c
index e34be78a3..439ed68d3 100644
--- a/camlibs/sonydscf1/sonydscf1.c
+++ b/camlibs/sonydscf1/sonydscf1.c
@@ -101,17 +101,18 @@ static int get_file_func (CameraFilesystem *fs, const char *folder,
return GP_OK;
}
-static int camera_file_delete (Camera *camera, const char *folder,
- const char *filename)
+static int delete_file_func (CameraFilesystem *fs, const char *folder,
+ const char *filename, void *data)
{
+ Camera *camera = data;
int max, num;
+
num = gp_filesystem_number(camera->fs, "/", filename);
max = gp_filesystem_count(camera->fs,folder) ;
printf("sony dscf1: file delete: %d\n",num);
if(!F1ok())
return (GP_ERROR);
delete_picture(num,max);
- gp_filesystem_delete (camera->fs, folder, filename);
return(GP_OK);
/*return (F1deletepicture(file_number));*/
}
@@ -169,7 +170,6 @@ int camera_init (Camera *camera) {
}
camera->functions->exit = camera_exit;
- camera->functions->file_delete = camera_file_delete;
// camera->functions->capture = camera_capture;
camera->functions->summary = camera_summary;
camera->functions->manual = camera_manual;
@@ -192,7 +192,8 @@ int camera_init (Camera *camera) {
/* Set up the filesystem */
gp_filesystem_set_list_funcs (camera->fs, file_list_func, NULL, camera);
- gp_filesystem_set_file_func (camera->fs, get_file_func, camera);
+ gp_filesystem_set_file_funcs (camera->fs, get_file_func,
+ delete_file_func, camera);
return (GP_OK);
}