From 4b4c516a8edf16e8e9d7119fea7ede47f8a3d5cb Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Tue, 18 Jun 2013 18:08:33 +0200 Subject: [PATCH] Fix #883 Resize img accoring to device orientation --- templates/mobile/common/thumbnail.html.twig | 1 - .../lightbox/jquery.validator.mobile.css | 22 ++++++++++++++++++- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/templates/mobile/common/thumbnail.html.twig b/templates/mobile/common/thumbnail.html.twig index 276e7b61c9..34ba286549 100644 --- a/templates/mobile/common/thumbnail.html.twig +++ b/templates/mobile/common/thumbnail.html.twig @@ -107,7 +107,6 @@ {menu: "false",flashvars: "playerID=2&autostart=yes&noinfo=yes&animation=no&remaining=yes&soundFile={{thumbnail.get_url()}}", movie: "/include/jslibs/audio-player/player.swf", allowFullScreen :"true",wmode: "transparent"}, false); {% else %} diff --git a/www/skins/lightbox/jquery.validator.mobile.css b/www/skins/lightbox/jquery.validator.mobile.css index d492622646..77b4e4a9f1 100644 --- a/www/skins/lightbox/jquery.validator.mobile.css +++ b/www/skins/lightbox/jquery.validator.mobile.css @@ -48,4 +48,24 @@ a.active_choice{ } .valid_choice.disagree{ background-image: url(/skins/icons/delete.png); -} \ No newline at end of file +} + +.thumb_wrapper { + text-align:center; +} + +@media screen and (orientation: landscape) { + + .thumb_wrapper img { + width: 50%; + } + +} + +@media screen and (orientation: portrait) { + + .thumb_wrapper img { + width: 100%; + } + +}