gphoto4ruby 0.2.4 → 0.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/CHANGELOG.rdoc +4 -0
- data/ext/gphoto2camera.c +3 -9
- data/ext/gphoto2camera_event.c +7 -0
- data/ext/gphoto2camera_event.h +3 -0
- metadata +1 -1
data/CHANGELOG.rdoc
CHANGED
data/ext/gphoto2camera.c
CHANGED
@@ -51,13 +51,6 @@ VALUE camera_allocate(VALUE klass) {
|
|
51
51
|
return Data_Wrap_Struct(klass, camera_mark, camera_free, c);
|
52
52
|
}
|
53
53
|
|
54
|
-
void camera_event_mark(GPhoto2CameraEvent *ce) {
|
55
|
-
}
|
56
|
-
|
57
|
-
void camera_event_free(GPhoto2CameraEvent *ce) {
|
58
|
-
free(ce);
|
59
|
-
}
|
60
|
-
|
61
54
|
/*
|
62
55
|
* call-seq:
|
63
56
|
* GPhoto2::Camera.new(port=nil)
|
@@ -959,8 +952,9 @@ VALUE camera_wait(int argc, VALUE *argv, VALUE self) {
|
|
959
952
|
switch (ce->type) {
|
960
953
|
case GP_EVENT_FILE_ADDED:
|
961
954
|
case GP_EVENT_FOLDER_ADDED:
|
962
|
-
|
963
|
-
|
955
|
+
ce->path = (CameraFilePath*)evtData;
|
956
|
+
free(c->path);
|
957
|
+
c->path = ce->path;
|
964
958
|
strcpy(c->virtFolder, c->path->folder);
|
965
959
|
gp_result_check(gp_camera_wait_for_event(c->camera, 100, &fakeType, &fakeData, c->context));
|
966
960
|
break;
|
data/ext/gphoto2camera_event.c
CHANGED
data/ext/gphoto2camera_event.h
CHANGED
@@ -38,6 +38,9 @@ VALUE rb_cGPhoto2CameraEvent;
|
|
38
38
|
#define EVENT_FILE_ADDED rb_str_new2("file added")
|
39
39
|
#define EVENT_FOLDER_ADDED rb_str_new2("folder added")
|
40
40
|
|
41
|
+
void camera_event_mark(GPhoto2CameraEvent *ce);
|
42
|
+
void camera_event_free(GPhoto2CameraEvent *ce);
|
43
|
+
|
41
44
|
VALUE camera_event_type(VALUE self);
|
42
45
|
VALUE camera_event_file(VALUE self);
|
43
46
|
|