Browse Source

Added myLoadThumb cleanup

master
Igor Zhukov 10 years ago
parent
commit
1b815c7126
  1. 15
      app/js/directives.js
  2. 1
      app/partials/chat_modal.html
  3. 1
      app/partials/dialog.html
  4. 1
      app/partials/head.html
  5. 3
      app/partials/im.html
  6. 1
      app/partials/settings_modal.html

15
app/js/directives.js

@ -1013,13 +1013,14 @@ angular.module('myApp.directives', ['myApp.filters']) @@ -1013,13 +1013,14 @@ angular.module('myApp.directives', ['myApp.filters'])
});
})
var cleanup = angular.noop;
// function () {
// setTimeout(function () {
// $scope.$destroy()
// stopWatching();
// }, 0);
// };
var cleanup = attrs.watch
? angular.noop
: function () {
setTimeout(function () {
$scope.$destroy()
stopWatching();
}, 0);
};
}
})

1
app/partials/chat_modal.html

@ -10,6 +10,7 @@ @@ -10,6 +10,7 @@
<img
class="user_modal_image"
my-load-thumb
watch="true"
thumb="chatFull.thumb"
/>
</div>

1
app/partials/dialog.html

@ -17,6 +17,7 @@ @@ -17,6 +17,7 @@
<img
class="im_dialog_photo"
my-load-thumb
watch="true"
thumb="dialogMessage.peerPhoto"
/>
</div>

1
app/partials/head.html

@ -5,6 +5,7 @@ @@ -5,6 +5,7 @@
<a class="navbar-peer-wrap" ng-click="showPeerInfo()">
<img
my-load-thumb
watch="true"
thumb="historyPeer.photo"
/>
</a>

3
app/partials/im.html

@ -206,6 +206,7 @@ @@ -206,6 +206,7 @@
<img
class="im_panel_peer_photo"
my-load-thumb
watch="true"
thumb="historyPeer.photo"
/>
<i class="icon im_panel_peer_online" ng-show="historyPeer.id > 0 &amp;&amp; historyPeer.data.status._ == 'userStatusOnline'"></i>
@ -214,6 +215,7 @@ @@ -214,6 +215,7 @@
<img
class="im_panel_own_photo"
my-load-thumb
watch="true"
thumb="ownPhoto"
/>
</div>
@ -263,4 +265,3 @@ @@ -263,4 +265,3 @@
</div>
<div id="notify_sound"></div>

1
app/partials/settings_modal.html

@ -10,6 +10,7 @@ @@ -10,6 +10,7 @@
<img
class="user_modal_image"
my-load-thumb
watch="true"
thumb="photo"
/>
</a>

Loading…
Cancel
Save