yaz/commit

disable frame confirm

authorMichiel Hildebrand
Wed Jul 6 17:54:41 2011 +0200
committerMichiel Hildebrand
Wed Jul 6 17:54:41 2011 +0200
commitda6a133817a627398ec7324820bd8f94bed3e0ce
treeba00f2a9c8a8b48a3009a554a90ce941e28c0253
parentd06b6055f5c7dfe00ea08bdfddc33490765fbf20
Diff style: patch stat
diff --git a/applications/yaz_fplayer.pl b/applications/yaz_fplayer.pl
index ed6387b..50d1af2 100644
--- a/applications/yaz_fplayer.pl
+++ b/applications/yaz_fplayer.pl
@@ -198,7 +198,7 @@ html_video_page_yui(Video, Subjects, Locations, Persons, Options) -->
 						 duration:Duration,
 						 playerPath:FilePath,
 						 width:560,
-						 confirm:symbol(true),
+						 confirm:symbol(false),
 						 showRelated:symbol(false),
 						 showTime:symbol(true)
 						})),
diff --git a/applications/yaz_player.pl b/applications/yaz_player.pl
index b8e458a..567ec28 100644
--- a/applications/yaz_player.pl
+++ b/applications/yaz_player.pl
@@ -84,24 +84,24 @@ http_yaz_player(Request) :-
 		    role(Role),
 		    limit(Limit),
 		    offset(Offset)
- 		  ],
+		  ],
 	delete_nonground(Options0, Options),
 	%findall(P, video_process(Video, P, User), Processes0),
 	%findall(U, video_process(Video, Process, U), Users0),
 	%sort(Processes0, Processes),
 	%sort(Users0, Users),
- 	% annotations
- 	video_annotations(Video, Annotations0, Options),
+	% annotations
+	video_annotations(Video, Annotations0, Options),
 	sort_by_arg(Annotations0, 2, Annotations1),
 	list_limit(Annotations1, Limit, Annotations, _),
- 	html_page(Video, Annotations, StartTime, Options).
+	html_page(Video, Annotations, StartTime, Options).
 
 %%	video_process(+Video,	-Process, -User)
 %
 %	Process has used  Video.
 
 video_process(Video, Process, User) :-
-  	rdf(Process, opmv:used, Video),
+	rdf(Process, opmv:used, Video),
 	rdf(Process, rdf:type, pprime:'Game'),
 	rdf_has(Process, opmv:wasControlledBy, User).
 
@@ -225,7 +225,7 @@ html_process_list([Process|T], Selected, VideoPlayer) -->
 	  ;   Class = item,
 	      Link = VideoPlayer+'&process='+Process
 	  )
- 	},
+	},
 	html(li(class(Class),
 		a(href(Link),
 		  [Time]))),
@@ -240,7 +240,7 @@ html_user_list([User|T], Selected, VideoPlayer) -->
 	  ;   Class = item,
 	      Link = VideoPlayer+'&user='+User
 	  )
-  	},
+	},
 	html(li(class(Class),
 		a(href(Link),
 		  [Label]))),
@@ -254,7 +254,7 @@ html_video_page_yui(Video, Annotations, StartTime, Options) -->
 	  video_source(Video, Src, Duration),
 	  option(interval(Interval), Options, 0),
 	  http_location_by_id(serve_video_frame, FrameServer),
-  	  http_absolute_location(js('videoplayer/'), FilePath, []),
+	  http_absolute_location(js('videoplayer/'), FilePath, []),
 	  http_absolute_location(js('videoplayer/videoplayer.js'), Videoplayer, []),
 	  http_absolute_location(js('videoframes/videoframes.js'), VideoFrames, []),
 	  http_absolute_location(js('tagplayer/tagplayer.js'), Tagplayer, []),
@@ -262,9 +262,9 @@ html_video_page_yui(Video, Annotations, StartTime, Options) -->
 	  http_absolute_location(js('valueslider/valueslider.js'), Valueslider, []),
 	  annotation_to_json(Annotations, JSONTags),
 	  list_limit(JSONTags, 50, JSONFrames, _)
-   	},
+	},
 	html_requires(js('videoplayer/swfobject.js')),
- 	js_yui3([{modules:{'video-player':{fullpath:Videoplayer},
+	js_yui3([{modules:{'video-player':{fullpath:Videoplayer},
 			   'video-frames':{fullpath:VideoFrames},
 			   'tag-player':{fullpath:Tagplayer},
 			   'timeline':{fullpath:Timeline},
@@ -273,28 +273,28 @@ html_video_page_yui(Video, Annotations, StartTime, Options) -->
 		],
 		[node,event,widget,anim,slider,
 		 'json','querystring-stringify-simple',io,
-  		 'video-player','video-frames','tag-player',
+		 'video-player','video-frames','tag-player',
 		 timeline,'value-slider'
- 		],
+		],
 		[ \js_new(videoPlayer,
 			  'Y.mazzle.VideoPlayer'({filepath:FilePath,
- 						  src:Src,
+						  src:Src,
 						  width:560,
 						  height:400,
 						  autoplay:symbol(false),
 						  controls:symbol(true),
- 						  start:StartTime,
+						  start:StartTime,
 						  duration:Duration
 						 })),
 		  \js_new(videoFrames,
 			 'Y.mazzle.VideoFrames'({frameServer:FrameServer,
- 						 frames:JSONFrames,
+						 frames:JSONFrames,
 						 video:Src,
-  						 duration:Duration,
+						 duration:Duration,
 						 playerPath:FilePath,
 						 width:560,
-						 confirm:true
- 						})),
+						 confirm:symbol(true)
+						})),
 
 		  \js_new(tagPlayer,
 			  'Y.mazzle.TagPlayer'({tags:JSONTags,
@@ -316,18 +316,18 @@ html_video_page_yui(Video, Annotations, StartTime, Options) -->
 						  max:60,
 						  value:Interval
 						 })),
-  		  'var oldTime;\n',
+		  'var oldTime;\n',
 		  \js_yui3_decl(params, json(Options)),
 		  \js_yui3_decl(delayID, -1),
 		  \js_fetch_tags,
 		  \js_fetch_tag_frames,
 		  \js_fetch_tag_info,
 		  \js_update_entries(Video),
- 		  \js_call('videoPlayer.render'('#videoplayer')),
+		  \js_call('videoPlayer.render'('#videoplayer')),
 		  \js_call('videoFrames.render'('#videoframes')),
 		  \js_call('tagPlayer.render'('#tagplayer')),
 		  \js_call('timeline.render'('#timeline')),
-   		  \js_yui3_on(videoPlayer, timeChange, \js_video_time_change),
+		  \js_yui3_on(videoPlayer, timeChange, \js_video_time_change),
 		  \js_yui3_on(tagPlayer, itemSelect, \js_tag_select),
 		  \js_yui3_on(intervalSlider, valueUpdate, \js_slider_select),
 		  \js_yui3_delegate('.option', input, click, \js_option_select, []),
@@ -336,11 +336,11 @@ html_video_page_yui(Video, Annotations, StartTime, Options) -->
 		  \js_yui3_on(videoFrames, roleSelect, \js_role_select(Video)),
 		  \js_yui3_on('Y.one("#toggleOptions")', click, \js_toggle_options),
 		  \js_yui3_on('Y.one("#toggleFrames")', click, \js_toggle_frames),
- 		  \js_yui3_on('Y.one("#tagsearch")', keyup,  \js_search),
+		  \js_yui3_on('Y.one("#tagsearch")', keyup,  \js_search),
 		  \js_yui3_on('Y.one("#tagtype")', change, \js_filter),
 		  \js_yui3_on('Y.one("#tagrole")', change, \js_filter),
 		  \js_call(fetchTagInfo(Query))
-   		]).
+		]).
 
 js_toggle_options -->
 	js_function([e],
@@ -419,7 +419,7 @@ js_fetch_tag_frames -->
     Y.io("',Server,'",
 	 { data: data,
 	   on: { success: setFrames }})\n'
- 			  ]).
+			  ]).
 
 js_fetch_tag_info -->
 	{ http_location_by_id(http_yaz_tag_edit, Server)
@@ -483,7 +483,7 @@ js_option_select -->
           value = target.get("checked");
       params[param] = value;
       fetchTags(params);\n'
- 		    ]).
+		    ]).
 
 js_slider_select -->
 	js_function([e],
@@ -499,11 +499,11 @@ js_search -->
 		    \[
 '    var delay = 200,
 	 minQueryLength = 3,
- 	 query = e.currentTarget.get("value");\n',
+	 query = e.currentTarget.get("value");\n',
 '    if(Y.delayID != -1) { clearTimeout(Y.delayID); }
      Y.params.query = (query.length < minQueryLength) ? "" : query;
      Y.delayID = setTimeout(fetchTags, delay);\n'
- 		     ]).
+		     ]).
 
 js_filter -->
 	js_function([e],
@@ -515,7 +515,7 @@ js_filter -->
 		    if(this.get("value")) {conf[filter] = this.get("value")}
 		    fetchTags(conf)
 	}});\n'
- 		     ]).
+		     ]).
 
 js_update_entries(Video) -->
 	{ http_location_by_id(http_data_update_entries, Server)
@@ -600,8 +600,8 @@ http_data_tags(Request) :-
 			  offset(Offset,
 				 [default(0), number,
 				  description('first result that is returned')])
- 			]),
- 	Options = [process(Process),
+			]),
+	Options = [process(Process),
 		   user(User),
 		   interval(Interval),
 		   confirmed(Confirmed),
@@ -609,13 +609,13 @@ http_data_tags(Request) :-
 		   type(Type),
 		   role(Role)
 		  ],
-  	% annotations
- 	video_annotations(Video, Annotations0, Options),
+	% annotations
+	video_annotations(Video, Annotations0, Options),
 	sort_by_arg(Annotations0, 2, Annotations1),
 	list_offset(Annotations1, Offset, Annotations2),
 	list_limit(Annotations2, Limit, Annotations, _),
 	annotation_to_json(Annotations, JSONTags),
-  	reply_json(json([tags=JSONTags])).
+	reply_json(json([tags=JSONTags])).
 
 
 %%	http_data_related_tags(+Request)
@@ -645,11 +645,11 @@ http_data_related_tags(Request) :-
 			]),
 	Options = [process(Process),
 		   user(User)
- 		  ],
+		  ],
 	rdf(Entry, rdf:value, Tag),
-  	Obj = Time-json([entry=Id, tag=json([uri=Tag, label=Label]), startTime=Time, role=R]),
+	Obj = Time-json([entry=Id, tag=json([uri=Tag, label=Label]), startTime=Time, role=R]),
 	findall(Obj, (video_annotation(Video, Id, uri(Tag,Label), Time, _, Options),
- 		      tag_role(Id, R)
+		      tag_role(Id, R)
 		     ), Entries0),
 
 	keysort(Entries0, Entries1),
@@ -676,13 +676,13 @@ http_data_update_entries(Request) :-
 			       [description('video we are updating entries of')]),
 			  entries(Entries,
 				[zero_or_more, description('entries to update')]),
- 			  value(Value,
+			  value(Value,
 				[optional(true), description('text value')]),
 			  concept(Concept,
 				  [optional(true), description('Link to a concept')]),
 			  role(Role,
 			       [default(false), description('role of the tag')])
-   			]),
+			]),
 	logged_on(User0, anonymous),
 	user_property(User0, url(User)),
 	(   current_user_process(Process),
@@ -699,7 +699,7 @@ http_data_update_entries(Request) :-
 update_entries([], _, _, _, []).
 update_entries([Entry|Es], Value, Concept, Role, [json([entry=Entry, tag=NewTag, role=Role])|Rest]) :-
 	update_value(Entry, Concept, Value, NewTag),
- 	update_role(Entry, Role),
+	update_role(Entry, Role),
 	update_entries(Es, Value, Concept, Role, Rest).
 
 update_value(E, Concept, _Value, Concept) :-
@@ -710,7 +710,7 @@ update_value(E, Concept, _Value, Concept) :-
 update_value(E, _Concept, Value, Tag) :-
 	nonvar(Value),
 	!,
- 	rdf(E, rdf:value, Tag0),
+	rdf(E, rdf:value, Tag0),
 	rdf(Tag0, rdf:type, pprime:'Tag'),
 	(   rdf(Tag0, rdfs:label, literal(Value))
 	->  Tag = Tag0