Skip to content

Commit

Permalink
Fixing the picker to include search results
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulKinlan committed Aug 9, 2012
1 parent 33f0ac2 commit e0cc12d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions server/demos/cloudfilepicker/pages/index.html
Expand Up @@ -32,8 +32,10 @@
pickerBuilder.addViewGroup(
new google.picker.ViewGroup(google.picker.ViewId.PHOTOS).
addView(new google.picker.PhotosView().
setType(google.picker.PhotosView.Type.UPLOADED)));
pickerBuilder.enableFeature(google.picker.Feature.NAV_HIDDEN);
setType(google.picker.PhotosView.Type.UPLOADED)).
addView(new google.picker.ImageSearchView().
setLicense(google.picker.ImageSearchView.License.None))
);
}
else if(window.intent.type.indexOf('video') == 0) {
pickerBuilder.addViewGroup(
Expand Down Expand Up @@ -68,7 +70,7 @@

function pickerCallback(data) {
if (data.action == google.picker.Action.PICKED) {
returnImage(data.docs[0].thumbnails[data.docs[0].thumbnails.length > 4 ? 4 : 3].url);
returnImage(data.docs[0].thumbnails[data.docs[0].thumbnails.length - 1].url);
}
else if(data.action == google.picker.Action.CANCEL) {
// Tell the calling app the user cancelled.
Expand Down

0 comments on commit e0cc12d

Please sign in to comment.