CRM-13328, fixes

----------------------------------------
* CRM-13328: Add support for image scaling
  http://issues.civicrm.org/jira/browse/CRM-13328
Merge pull request #1657 from kurund/CRM-13328

CRM-13328, fixes