fix image/sourcecode viewer bug